调用未定义的方法Rights :: getAuthorizer()

时间:2015-08-31 07:51:39

标签: database netbeans yii module rights

收到此错误,Fatal error: Call to undefined method Rights::getAuthorizer() in C:\wamp\www\project\protected\modules\rights\components\RWebUser.php on line 21

1 个答案:

答案 0 :(得分:0)

这是因为这个错误。问题在于编写代码,确保你必须在config.main中编写你的代码

'import' => array(
        'application.models.*',
        'application.components.*',
        'bootstrap.behaviors.*',
        'bootstrap.helpers.*',
        'bootstrap.widgets.*',
//add this code after the above code and thats it, a small stupid mistake may cost you 3 days of hard debugging.
        'application.modules.user.models.*',
        'application.modules.user.components.*',
        'application.modules.rights.*',
        'application.modules.rights.components.*'



    ),