dongtun4268
2017-08-04 11:58 阅读 45
已采纳

找不到Magento源模型属性em_bonus

I see similar issues and work around suggestions but no luck. Following below is my code trace error while I try to open a product/add product from backend in Magento 1.9

Source model "opendealsettings/bonus" not found for attribute "em_bonus"

Trace:
#0 C:\xampp\htdocs\app\code\core\Mage\Eav\Model\Entity\Attribute\Abstract.php(388): Mage::exception('Mage_Eav', 'Source model "o...')
#1 C:\xampp\htdocs\app\code\core\Mage\Adminhtml\Block\Widget\Form.php(201): Mage_Eav_Model_Entity_Attribute_Abstract->getSource()
#2 C:\xampp\htdocs\app\code\core\Mage\Adminhtml\Block\Catalog\Product\Edit\Tab\Attributes.php(70): Mage_Adminhtml_Block_Widget_Form->_setFieldset(Array, Object(Varien_Data_Form_Element_Fieldset), Array)
#3 C:\xampp\htdocs\app\code\core\Mage\Adminhtml\Block\Widget\Form.php(144): Mage_Adminhtml_Block_Catalog_Product_Edit_Tab_Attributes->_prepareForm()
#4 C:\xampp\htdocs\app\code\core\Mage\Core\Block\Abstract.php(922): Mage_Adminhtml_Block_Widget_Form->_beforeToHtml()
#5 C:\xampp\htdocs\app\code\core\Mage\Adminhtml\Block\Catalog\Product\Edit\Tabs.php(79): Mage_Core_Block_Abstract->toHtml()
#6 C:\xampp\htdocs\app\code\core\Mage\Core\Block\Abstract.php(297): Mage_Adminhtml_Block_Catalog_Product_Edit_Tabs->_prepareLayout()
#7 C:\xampp\htdocs\app\code\core\Mage\Core\Model\Layout.php(456): Mage_Core_Block_Abstract->setLayout(Object(Mage_Core_Model_Layout))
#8 C:\xampp\htdocs\app\code\core\Mage\Core\Model\Layout.php(472): Mage_Core_Model_Layout->createBlock('adminhtml/catal...', 'product_tabs')
#9 C:\xampp\htdocs\app\code\core\Mage\Core\Model\Layout.php(239): Mage_Core_Model_Layout->addBlock('adminhtml/catal...', 'product_tabs')
#10 C:\xampp\htdocs\app\code\core\Mage\Core\Model\Layout.php(205): Mage_Core_Model_Layout->_generateBlock(Object(Mage_Core_Model_Layout_Element), Object(Mage_Core_Model_Layout_Element))
#11 C:\xampp\htdocs\app\code\core\Mage\Core\Model\Layout.php(210): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
#12 C:\xampp\htdocs\app\code\core\Mage\Core\Controller\Varien\Action.php(344): Mage_Core_Model_Layout->generateBlocks()
#13 C:\xampp\htdocs\app\code\core\Mage\Core\Controller\Varien\Action.php(269): Mage_Core_Controller_Varien_Action->generateLayoutBlocks()
#14 C:\xampp\htdocs\app\code\core\Mage\Adminhtml\Controller\Action.php(275): Mage_Core_Controller_Varien_Action->loadLayout(Array, true, true)
#15 C:\xampp\htdocs\app\code\core\Mage\Adminhtml\controllers\Catalog\ProductController.php(249): Mage_Adminhtml_Controller_Action->loadLayout(Array)
#16 C:\xampp\htdocs\app\code\core\Mage\Core\Controller\Varien\Action.php(418): Mage_Adminhtml_Catalog_ProductController->editAction()
#17 C:\xampp\htdocs\app\code\core\Mage\Core\Controller\Varien\Router\Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('edit')
#18 C:\xampp\htdocs\app\code\core\Mage\Core\Controller\Varien\Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#19 C:\xampp\htdocs\app\code\core\Mage\Core\Model\App.php(365): Mage_Core_Controller_Varien_Front->dispatch()
#20 C:\xampp\htdocs\app\Mage.php(683): Mage_Core_Model_App->run(Array)
#21 C:\xampp\htdocs\index.php(83): Mage::run('', 'store')
#22 {main}
  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 复制链接分享

1条回答 默认 最新

  • 已采纳
    dqed19166 dqed19166 2017-08-04 15:06

    Seem this attribute was created with an extensions that is no longer in use.

    Try to delete this attribute from "Admin - Catalog - Manage Attributes". If it does not work you can create a script in magentos root with this content:

    require 'app/Mage.php';
    Mage::app('admin');
    
    $setup = Mage::getModel('eav/entity_setup', 'core_setup');
    $setup->startSetup();
    $setup->removeAttribute('catalog_product', 'em_bonus');
    $setup->endSetup();
    
    点赞 评论 复制链接分享

相关推荐