juliopontes / joomla-override

Plugin to Override Joomla Extensions (Modules and Components)
19 stars 17 forks source link

Error on model override #16

Open mmilidoni opened 10 years ago

mmilidoni commented 10 years ago

Hi, thank you so much for this plugin, it is very very useful!

I have a problem in custom model classes. For example, I put my custom model of virtuemart orders into code folder, and I get this error message:

 PHP Notice:  Use of undefined constant JPATH_VM_ADMINISTRATOR - assumed 'JPATH_VM_ADMINISTRATOR' in /var/www/mywebsite/plugins/system/joomlaoverride/helper/override.php(116) : eval()'d code on line 25

and connected Warning and Fatal errors.

What do you think about?

juliopontes commented 10 years ago

VM need to define this constant to your code works. Please define it before on your override file or require same file that have defined vars from vm.

mmilidoni commented 10 years ago

Ok, thanks. I define this constant on joomlaoverride.php file, because on my custom model don't works.