? Pending

User tests: Successful: Unsuccessful:

avatar laoneo
laoneo
19 Oct 2018

Summary of Changes

In #20217 got an MVCFactoryFactoryInterface introduced to create an MVCFactoryInterface for a given application. This can be made simpler by providing the MVCFactoryInterface instances directly by the component.

This implies that creating a model, view or table from the factory needs a prefix. If this is not the case, a deprecated message is triggered and the application name of the current application is used. It simplifies the code and plugins can directly override the service to create the factory, instead of having a factory which creates factories.

The factory can be loaded now through:
$factory = $app->bootComponent('com_content')->getMVCFactory();

If you call the create functions without prefix, a deprecated message is triggered, so instead of
$factory->createModel('Articles');

you should call it with a prefix:
$factory->createModel('Articles', 'Administrator');

Testing Instructions

Browse around in the front end and back end.

Expected result

All is working.

Actual result

All is working.

Documentation Changes Required

Needs to be documented together with the rest of the namespacing and service provider changes.

avatar laoneo laoneo - open - 19 Oct 2018
avatar laoneo laoneo - change - 19 Oct 2018
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 19 Oct 2018
Category Administration com_admin com_associations com_banners com_cache com_categories com_checkin com_config com_contact com_content com_contenthistory com_cpanel com_csp com_fields com_finder com_installer com_joomlaupdate com_languages com_login com_media com_menus com_messages
avatar laoneo laoneo - change - 19 Oct 2018
The description was changed
avatar laoneo laoneo - edited - 19 Oct 2018
avatar laoneo laoneo - change - 19 Oct 2018
Labels Added: ?
avatar laoneo laoneo - change - 19 Oct 2018
The description was changed
avatar laoneo laoneo - edited - 19 Oct 2018
avatar laoneo laoneo - change - 19 Oct 2018
The description was changed
avatar laoneo laoneo - edited - 19 Oct 2018
avatar wilsonge wilsonge - close - 24 Oct 2018
avatar wilsonge wilsonge - merge - 24 Oct 2018
avatar wilsonge wilsonge - change - 24 Oct 2018
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2018-10-24 07:24:53
Closed_By wilsonge
avatar wilsonge
wilsonge - comment - 24 Oct 2018

Thanks!

Add a Comment

Login with GitHub to post a comment