mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-16 06:17:56 +08:00
Merge pull request #3983 from sitawit/patch-1
Update a tip and an example
This commit is contained in:
@@ -202,6 +202,9 @@ return [
|
|||||||
|
|
||||||
The `authManager` can now be accessed via `\Yii::$app->authManager`.
|
The `authManager` can now be accessed via `\Yii::$app->authManager`.
|
||||||
|
|
||||||
|
> Tip: By default, [[yii\rbac\PhpManager]] stores RBAC data in the file `@app/data/rbac.php`.
|
||||||
|
Sometime you need to create this file manually.
|
||||||
|
|
||||||
|
|
||||||
### Building Authorization Data
|
### Building Authorization Data
|
||||||
|
|
||||||
@@ -222,6 +225,7 @@ command that will initialize authorization data once via APIs offered by `authMa
|
|||||||
<?php
|
<?php
|
||||||
namespace app\commands;
|
namespace app\commands;
|
||||||
|
|
||||||
|
use Yii;
|
||||||
use yii\console\Controller;
|
use yii\console\Controller;
|
||||||
|
|
||||||
class RbacController extends Controller
|
class RbacController extends Controller
|
||||||
|
|||||||
Reference in New Issue
Block a user