我在我的应用程序中使用了 dektrium/yii2-user。在vendor/dektriumgetID()
的User.php中有一个名为的方法,该方法可以被登录用户访问并返回。Yii::$app->user->getID()
id
但是,还有另一种名为的方法getProfile()
,其功能是返回当前登录用户的完整配置文件详细信息。但是,这种方法会给出 500-internal server error。
exception 'yii\base\UnknownMethodException' with message 'Calling unknown method: yii\web\User::getProfile()' in ... ...
我用谷歌搜索了这个问题,但一无所获......帮帮我吧伙计们..