User tests: Successful: Unsuccessful:
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');
Browse around in the front end and back end.
All is working.
All is working.
Needs to be documented together with the rest of the namespacing and service provider changes.
Status | New | ⇒ | Pending |
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 |
Labels |
Added:
?
|
Status | Pending | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2018-10-24 07:24:53 |
Closed_By | ⇒ | wilsonge |
Thanks!