Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Codeigniter 4 upgrade #3858

Open
wants to merge 264 commits into
base: master
Choose a base branch
from
Open

Codeigniter 4 upgrade #3858

wants to merge 264 commits into from

Conversation

objecttothis and others added 30 commits November 1, 2023 00:51
- automatic upgrade of encryption key.
- automatic decryption of CI3 data, then re-encryption in CI4 and update of table.
- Fixing save function in app_config model
…n the creation of the database script that supports migration from phppos
- Added session variable instantiation where needed.
- Added tabular helper to autoload
- removed tabular helper reference where no longer needed.
- Remove esc() references where it was causing display problems.
- Remove excess whitespace on blank line
- Remove unecessary using reference
- Make parameters for dinner table functions nullable
…array_walker since the parameters (even if not used) are validated in PHP 8.
- Added todo to Stock_location.php
- make library function return nullable
- Added missing model instantiation
- Commented out Sale model instantiation in library because it's causing infinite loop
- Changed function name prepending get and post required by CI4 autorouting
* Initial setup in a new environment

The result of running the npm build and editing the .env file

* Revert "Initial setup in a new environment"

This reverts commit 23e06de.

* Language interpolation update

I have edited all the interpolations in the en-US tree. To be consistent in using named parameters and not just positional numbers, I also edited the relevant lines in two controllers (Sales.php and Items.php) to send named variables to the lang() calls. The language string 'Sales.invoice_number_duplicate' contains an interploation for 'invoice_number'. This is sent when used by Controllers/Sales.php, but not sent when used by Views/sales/form.php, which means that string will contain a double space where the invoice number should be. The language string 'Customers.csv_import_partially_failed' contains no interpolations but two parameters are not being sent where it is used by Controllers/Customers.php. The string appears to be a near duplicate of 'Items.csv_import_partially_failed' which contains two interpolations. Either the Customers controller needs to be edited, or the Customers language string needs to be revised to look like the Items string.

---------

Co-authored-by: objecttothis <17935339+objecttothis@users.noreply.github.com>
Added function remove_backup() to security_helper.php. Added a call to this from the two places that call check_encryption where the backup is created. Added more defensive code to Config.php to ensure the encrypter  objectexists before it is called to avoid a crash.
* reworked reports and listing page to handle lang() functions in CI_4

* removed old methods

* update code style

* updated bracket style

---------

Co-authored-by: objecttothis <17935339+objecttothis@users.noreply.github.com>
* CI4: Bugfix string interpolation language files

These are the language files with all placeholders converted to CI4 numbered style eg {0}.

* CI4: Bugfix string interpolation source code files

These are the controllers and views which call lang() with parameters to be interpolated.

* CI4: Bugfix string interpolation shell scripts

These are the Linux bash scripts which use the sed (stream editor) utility to convert earlier forms of placeholders to CI4 numeric type. A number of typographical errors in the original Language files were corrected by these scripts.
Adds 'payment_message' to the app_config table and corrects a typo in Views/login.php where 'Login.form' should have been 'login_form'.
Add a !empty test when dereferencing mailchimp_api_key and mailchimp_list_id from the config array.
- Bump composer.json/lock to codeigniter 4.4.3
- Fix base_url() call without arguments
- Updated files in the project space
- Bump composer.json/lock to kint 5.0.4
- Update composer.json to include missing CI elements
- Corrected composer.json regarding minimum versions
- Updated README.md to reflect CI4 implementation
- Migrated some Routes.php to Routing.php
- Removed deprecated settings from Config/App.php
objecttothis and others added 26 commits April 29, 2024 14:12
- bootstrap-tagsinput-2021 replaced bootstrap-tagsinput because the latter has vulnerabilities.
- Chartist and addons bumped to attempt to resolve issues with graphical reports.
- jspdf and addons bumped due to vulnerabilities.  It's still be broken however.

Signed-off-by: objecttothis <objecttothis@gmail.com>
- Revert jspdf and jspdf-autotable bump due to problems caused in npm run build
- Correct gulpfile for fixed reference.
- Reverted chartist dependency changes since it broke the build.

Signed-off-by: objecttothis <objecttothis@gmail.com>
- Revert jspdf and jspdf-autotable bump due to problems caused in npm run build
- Correct gulpfile for fixed reference.
- Reverted chartist dependency changes since it broke the build.

Signed-off-by: objecttothis <objecttothis@gmail.com>
Updated documentation. Fixed image links, links in changelog, and minor typos.
Fixed a typo in docker-compose.test file
Signed-off-by: objecttothis <objecttothis@gmail.com>
Signed-off-by: objecttothis <objecttothis@gmail.com>
- Added TODO where we need to convert to querybuilder
- Converted to switch statement.
- Removed unnecessary local variable
- Replaced Qualifiers with imports
- Replaced isset() call with null coalescing operator
- Replaced strpos function calls in if statements with str_contains calls
- Removed unnecessary leading \ in use statement
- Replaced deprecated functions
- Updated PHPdocs to match function signature
- Added missing type declarations
- Made class variables private.
- Explicitly declared dynamic properties
- use https:// links instead of http://
- Fixed type error from sending null when editing transactions
- Fixed Search Suggestion function name in Employees, Persons, Suppliers controller
- Fixed function name on Receivings Controller

Signed-off-by: objecttothis <objecttothis@gmail.com>
- Removed completed TODOs
- Added TODOs and comments where needed.

Signed-off-by: objecttothis <objecttothis@gmail.com>
- Updated deprecated BS5 classes
- Throw errors in separate alert boxes and not as an <ul>
- Make error translatable
- Small updates/fixes
Fix controller method names
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CodeIgniter4 Issue relates to the conversion to CodeIgniter 4
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet