Reputation: 579
In OpenCart 2.0 I am extending a model ModelAccountOrder
with override engine. I've successfully modified the existing method getOrder($order_id)
functionality by overriding it but when I created a new method in my child class then $this->db
is not accessible there and I am getting the following error:
Fatal error: Class 'DB\stdClass' not found in system\library\db\mpdo.php on line 77
My child class receivers_ModelAccountOrder
is in override\receivers\catalog\model\account\order.php
and it is working fine.
Upvotes: 1
Views: 454
Reputation: 9227
This is not related to Override Engine. This is an issue with the drivers shipped with Opencart 2.0 that has since been patched.
Unfortunately, there are MANY bugs in the core code like this. If you insist on developing for 2.0 at this early stage, I recommend keeping a close eye on their issue/revision lists.
Upvotes: 1