Dbmanager And No Save()


I am trying to use DbManager.

Followed tutorials without success:

    $auth = Yii::$app->authManager;



but only get this result:

Calling unknown method: yii\rbac\DbManager::save()

Any ideas?


why save()? read it https://github.com/yiisoft/yii2/blob/master/docs/guide/security-authorization.md#building-authorization-data

Thanks for your response.

I was using tutorial from this link http://denzyii.blogspot.com/2014/04/implementing-rbac-in-your-yii2.html which was not working.

The link you provided shows much more detail.

    $admin = $auth->createRole('admin');


I made updates based on your link and its now working.

Many thanks.