johnitvn / yii2-rbac-plus

Database role base access control manager for yii2
49 stars 52 forks source link

Non-static method called statically #18

Open slavicklg opened 8 years ago

slavicklg commented 8 years ago

image

https://github.com/johnitvn/yii2-rbac-plus/blob/master/src/models/Role.php#L64

 public function getPermistions($name)  {
        $authManager = Yii::$app->authManager;
        return $authManager->getPermissionsByRole($name);
    }

https://github.com/johnitvn/yii2-rbac-plus/blob/master/src/views/role/view.php#L5

$permissions = Role::getPermistions($model->name);
slavicklg commented 8 years ago

change to public static function getPermistions($name) {