Not all class headers are compiled #1040
Steps to reproduce the issue
I took the demo component to test if all the class headers would work, and set a comment to all of the fields in the class headers area in the admin view like this:
I did this for all the fields and checked if they were built by searching for the comment in the code. I built the component for joomla 4/5
All except maybe import headers would be built. Since i don't know if the import headers are only built on specific occasions.
The following class headers were not built:
- Target Site Admin View Model Header (site.admin.view.model) (and yes i selected admin edit view to be added to the site area as the tooltip asks)
- Target Site Admin View Default Template Header (site.admin.view)
- Target Import Custom Controller Header (import.custom.controller)
- Target Import Custom Model Header (import.custom.model)
- Target Ajax Model Class Header (ajax.model)
System information (as much as possible)
- OS Name & Version: Windows 10
- PHP Version: 8.1
- Joomla Version: 3.10.11
- JCB Version: 3.1.35
- Browser: firefox
I noticed the same on version 3.1.28 where even when i had the headers compiler plugin enabled and added to the compiler settings in jcb it would not add my use statements. I wonder maybe that plugin is broken at the moment?
Can you confirm that the plugins are up-to date and that they are all enabled?
I mean did you install JCB on a blank website with: https://git.vdm.dev/joomla-beta/pkg-component-builder/archive/v3.1.35.zip
This should then have the latest plugins, and they should all be activated... but if you can double check that the plugins in the package match the versions installed and the they are in fact activated in the plugin area, and in the global options of JCB under the compiler tab.
Since I am not seeing the same outcome....
The next thing to check is the files being targeted, since all the header targets you mentioned work perfectly well on my system, in fact if it did not, JCB will not work at all as it uses al these.
It is for that reason that I am wondering what might be the cause, as to what is different on your system from mine. Therefor also confirm that you have the same files in these two folders (Joomla 3 and Joomla 4): https://git.vdm.dev/joomla-beta/com-componentbuilder/src/branch/master/admin/compiler
Then try using PHP 8.0 to see if that makes a difference. Since I know Joomla 3 has known file issue in PHP 8.1, the kind of issue you will only see when you make use of the file and folder classes in the way JCB does.
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?