Repository navigation
Upgrade CI to 4.1.3 (Old) - #3271
objecttothis wants to merge 177 commits into
Conversation
- Changed PHP version to 7.3 - Changed CodeIgniter to 4.1.3
|
Is this all we need to switch to CI 4? I would have expected more changes than this but I might be wrong. |
- Updated composer.lock file - Updated composer.LICENSES file
- Updated composer.lock file
- Updated composer.lock file to fix incorrect packagist repo
hehe. No, there is a lot more. It's a draft pull request right now. I'm working on the changes now. The good news is that it's mostly syntax and naming changes. The bad news is that it's going to touch just about every file, so yay for refactoring! |
- Renamed application to app - Added writable - Deleted application/core - Capitalised core folder names inside app/ - Renamed third_party to ThirdParty
- Moved application/cache to /writable/cache - Moved application/logs to /writable/logs - Moved application/migrations to app/Database/Migrations/ - Added app/Filters - Added Common.php - Added system folder
|
Indeed what I was expecting |
|
Why are the My_ files removed? |
This is from the upgrade guide "There is no longer a nested application/core folder, as we have a different mechanism for extending framework components (see below)." I haven't gotten to the part where the replacement mechanism is explained. I'm working through it methodically so that I don't miss anything. |
- Moved public/uploads/item_pics to writable/uploads/item_pics - Deleted public/uploads - Added system files
- Removed basepath if check - Added namespacing - Refactored extends CI_model to extends Model
- Replaced $this->load->model('') with CI4 syntax.
- Corrected namespacing on nested models. - Added namespacing for tokens
- Replaced $this->load->view('') with echo view('')
- Added namespacing to controllers. - replaced extends CI_Controller with extends BaseController. - Removed BASEPATH if check.
- Added namespacing to libraries. - replaced $this->load->library() with CI4 variant. - Removed BASEPATH if check.
- Refactored model and library loading. - Refactored helper() loading calls.
- Renamed enum, reports, tokens to PascalCase - Corrected namespace declarations
- Ported changes from CI3 config.php to App.php - Added Boot folder with default file contents. - Added config files not found in CI3. - Ported changes from CI3 autoload.php to Autoload.php - Added BaseController.php controller
|
closes #842 |
- Ported over changes to Constants.php - Renamed constants.php to Constants.php - Ported over changes to Database.php - Renamed database.php to Database.php - Ported over changes to DocTypes.php - Renamed doctypes.php to DocTypes.php - Replaced CI3 email.php with Email.php from CI4 - Replaced foreign_chars.php with ForeignCharacters.php - Renamed hooks to Events - Refactored save_hook.php and renamed to Save_Event.php - converted hooks to events - memcached.php deleted and replaced with Cache.php - Replaced mimes.php with Mimes.php from CI4 - namespaced pagination.php - namespaced smileys.php - Deprecated cookie_secure and used Cookie->secure instead - Ported over default log-file permissions - Ported over Encryption Key location - Ported over exclusion uri to csrf and enabled
|
@objecttothis Here my first contribution. I have updated the composer buildbox and moved it to opensourcepos organization. Also have added the intl and mbstring dependencies to the buildbox. Let's see if it can install CI using composer now. I have temporarily removed some of the unix commands for updating the version in the config files (as they were changes as you said). |
Thanks for doing that. I'd say let's keep both working in the same branch and I can just fetch commits when I work on it. I think when/if people take parts of the refactoring work, they can just do the same. |
- Removed calls to $this-> where not necessary - Added in explicit model creation - correct capitalization of model() - renamed variable so that it did not conflict with model name and matched convention - Replaced get_instance() calls with model instantiation.
- Removed calls to $this-> where not necessary - Added in explicit model creation
- Fixed private field that should be public - Simplified reference in config()
…Igniter_4_upgrade
- Config defaults - Updated Database config defaults
make production default
| public $globals = [ | ||
| 'before' => [ | ||
| // 'honeypot', | ||
| 'honeypot', |

@jekkos created a new PR with new branch. Don't use this one. We need the branch to see what needs to be ported which has been merged into the master since this branch was created.
Here are a list of issues that need to be resolved:
CI4: Replace Database Backup Functionality #3451CI4: Replacing xss_clean() #3345CI4: Problem in Module model #3349CI4: Return of an undefined variable in Token_customer model class #3454CI4: Missing return statement in get_category_name() function of Supplier model #3456CI4: get_info() function in Item model no longer contains location_id parameter #3457CI4: Fix recursiveCopy() and recursiveUnlink() functions in install.php #3458