I have tried using visibility settings for users but it does not seem to take the option from “Report Module”.
I have also noted that in /modules/AOR_Reports/vardefs.php, the ‘options’ available for the report module array is defined as ‘aor_moduleList’, but cannot find this list to try updating it to fit my needs.
Please let me know if I am heading in the right direction toward finding a solution for this, as it has been tripping me up for a few days now.
In my case some modules need to be available on menus but just not on reports, would there be a way to modify your code to do so? Such as, is there an opposite to your $report_include_modules ? Thank you for the reply!
Also, I attempted your fix, but a quick repair/rebuild seemed to overwrite the modules.ext.php file in custom/application/Ext/Include; is that intended or does it sound like user error on my part with configuration?
I made it work using your code in /custom/Extension, but it breaks my environment every time, displaying this error (below my code) on a blank page for trying to hide any class:
Thank you again for your reply, at this point I am just looking to hide the two default modules (Email Addresses and Users) from the Report Modules dropdown, but these are the only two that are not able to be disabled from Roles and do not show up in ‘Display Modules and Subpanels’. When I tried using your code in this way:
I have found how to hide those two modules (and really any others) from report modules, it is not upgrade safe but the fix is to make a separate dropdown list that is a duplicate of moduleList, except it has the undesired modules removed (in my case modulesListR), and to change modules/AOR_Reports/AOR_Report.php line 156 from