MDN Advanced Stock Incompatibility

Extension Name

MDN Advanced Stock Incompatibility

Issue Status

Resolved with modifications.

Problem

Evidence of the conflict of these modules can be demonstrated if you see this error when you try to edit / view the order placed:

Invalid method TBT_Rewards_Model_Sales_Order::IsCompletelyShipped(Array
(
)
)
Trace:
#0 [internal function]: Varien_Object->__call('IsCompletelyShi...', Array)
#1 app/design/adminhtml/default/mdn_theme/template/sales/order/view/tab/Preparation.phtml(64): TBT_Rewards_Model_Sales_Order->IsCompletelyShipped()
#2 app/code/core/Mage/Core/Block/Template.php(212): include('/home/cadeaux/w...')
#3 app/code/core/Mage/Core/Block/Template.php(239): Mage_Core_Block_Template->fetchView('adminhtml/defau...')
#4 app/code/core/Mage/Core/Block/Template.php(253): Mage_Core_Block_Template->renderView()
#5 app/code/core/Mage/Adminhtml/Block/Template.php(81): Mage_Core_Block_Template->_toHtml()
#6 app/code/core/Mage/Core/Block/Abstract.php(753): Mage_Adminhtml_Block_Template->_toHtml()
#7 app/code/core/Mage/Adminhtml/Block/Widget/Tabs.php(289): Mage_Core_Block_Abstract->toHtml()
#8 app/design/adminhtml/default/default/template/widget/tabs.phtml(38): Mage_Adminhtml_Block_Widget_Tabs->getTabContent(Object(MDN_Orderpreparation_Block_Adminhtml_Sales_Order_View_Tab_Preparation))
#9 app/code/core/Mage/Core/Block/Template.php(212): include('/home/cadeaux/w...')
#10 app/code/core/Mage/Core/Block/Template.php(239): Mage_Core_Block_Template->fetchView('adminhtml/defau...')
#11 app/code/core/Mage/Core/Block/Template.php(253): Mage_Core_Block_Template->renderView()
#12 app/code/core/Mage/Adminhtml/Block/Template.php(81): Mage_Core_Block_Template->_toHtml()
#13 app/code/core/Mage/Core/Block/Abstract.php(753): Mage_Adminhtml_Block_Template->_toHtml()
#14 app/code/core/Mage/Core/Block/Text/List.php(43): Mage_Core_Block_Abstract->toHtml()
#15 app/code/core/Mage/Core/Block/Abstract.php(753): Mage_Core_Block_Text_List->_toHtml()
#16 app/code/core/Mage/Core/Block/Abstract.php(520): Mage_Core_Block_Abstract->toHtml()
#17 app/code/core/Mage/Core/Block/Abstract.php(471): Mage_Core_Block_Abstract->_getChildHtml('left', true)
#18 app/design/adminhtml/default/default/template/page.phtml(58): Mage_Core_Block_Abstract->getChildHtml('left')
#19 app/code/core/Mage/Core/Block/Template.php(212): include('/home/cadeaux/w...')
#20 app/code/core/Mage/Core/Block/Template.php(239): Mage_Core_Block_Template->fetchView('adminhtml/defau...')
#21 app/code/core/Mage/Core/Block/Template.php(253): Mage_Core_Block_Template->renderView()
#22 app/code/core/Mage/Adminhtml/Block/Template.php(81): Mage_Core_Block_Template->_toHtml()
#23 app/code/core/Mage/Core/Block/Abstract.php(753): Mage_Adminhtml_Block_Template->_toHtml()
#24 app/code/core/Mage/Core/Model/Layout.php(529): Mage_Core_Block_Abstract->toHtml()
#25 app/code/core/Mage/Core/Controller/Varien/Action.php(389): Mage_Core_Model_Layout->getOutput()
#26 app/code/core/Mage/Adminhtml/controllers/Sales/OrderController.php(119): Mage_Core_Controller_Varien_Action->renderLayout()
#27 app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Adminhtml_Sales_OrderController->viewAction()
#28 app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('view')
#29 app/code/core/Mage/Core/Controller/Varien/Front.php(177): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#30 app/code/core/Mage/Core/Model/App.php(304): Mage_Core_Controller_Varien_Front->dispatch()
#31 app/Mage.php(596): Mage_Core_Model_App->run(Array)
#32 index.php(80): Mage::run('', 'store')
#33 {main}

Resolution

1. Copy app/code/community/TBT/Rewards/Model/Sales/Order.php to app/code/local/TBT/Rewards/Model/Sales/Order.php so that you are not modifying core extension files.

2. Open app/code/local/TBT/Rewards/Model/Sales/Order.php, change line 50:

class TBT_Rewards_Model_Sales_Order extends Mage_Sales_Model_Order
	

to

class TBT_Rewards_Model_Sales_Order extends MDN_AdvancedStock_Model_Sales_Order
	

Please keep in mind that implementing any modifications to your MageRewards core code does void your support agreement because you're adding dependency to the other module.

Still need help? Get Help Get Help