This PR contains improvement + clean up to model classes to support both namespace and none namespace components in Joomla 4 (backward compatible change). Below are the list of changes/improvements:
Change to Model class
Change getName() method to support detect model name from both namespace class name and none namespace class name
Change getTable() method to allow creating namespace table object
Change to Form Model class
Allow getting xml form and forms field from resources directory
Note that I want to get rid of using JPATH_COMPONENT, detect folder dynamic from model class name
Change to List Model class
Simplify the code of getFilterForm() method
Allow getting xml form and forms field from resources directory
Note that I want to get rid of using JPATH_COMPONENT, detect folder dynamic from model class name
Change to Admin Model class
Use getColumnAlias for check_out field instead of using hardcoded name (make it consistent with other places in our code base)
Testing Instructions
Install Joomla 4.0
Apply patch
Try to navigate to different pages (maybe try to add. edit, delete, publish articles), make sure it is still working as before
I also tested with the namespace com_content component in this PR #14370 and it worked well. Hard for end user to test it for now, thought
I made change to this PR to get component namespace from manifest cache (same with in the #14511)
Since we haven't had a decision about where to load xml forms and form fields yet, I use the folder resources to make it easy to check it with namespace com_content PR.
Please help review this PR when you have some time
I made change to this PR to get component namespace from manifest cache (same with in the #14511)
Since we haven't had a decision about where to load xml forms and form fields yet, I use the folder resources to make it easy to check it with namespace com_content PR.
Please help review this PR when you have some time