こんにちは、管理ページに移動すると、次のエラーが表示され続けます
PHP 致命的なエラー: 66 行目の app/code/core/Mage/Adminhtml/Block/Widget/Grid/Container.php の非オブジェクトに対するメンバー関数 setSaveParametersInSession() の呼び出し
これが私のコントローラーです:
class LTS_Categorymove_Adminhtml_BlacklistController extends Mage_Adminhtml_Controller_Action{
public function indexAction(){
$this->loadLayout();
var_dump(Mage::getSingleton('core/layout')->getUpdate()->getHandles());
$this->renderLayout();
}
}
これが私のメインブロックです:
class LTS_Categorymove_Block_Adminhtml_Main extends Mage_Adminhtml_Block_Widget_Grid_Container{
protected $_addButtonLabel = 'Add New Example';
public function __construct(){
//error_log('fgboo');
$this->_controller = 'adminhtml_main';
$this->_blockGroup = 'categorymove';
$this->_headerText = 'Blacklist';
$this->_addButtonLabel = 'Button Here';
parent::__construct();
}
protected function _prepareLayout(){
$this->setChild( 'grid',
$this->getLayout()->createBlock( $this->_blockGroup.'/' . $this->_controller . '_grid',
$this->_controller . '.grid')->setSaveParametersInSession(true) );
return parent::_prepareLayout();
}
}
今私が問題をグーグルで調べたとき、誰もがそれは間違った_controller宣言であると言い続けていますが、周りを読んでいると、私がいるブロック名を使用する必要があると言われています。どんな助けでも素晴らしいでしょうありがとう