it-yakutia / yii2-rbac
Role Based Access Controll for yii2
Installs: 366
Dependents: 1
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Type:yii2-extension
Requires
- uraankhayayaal/yii2-materializecomponents: ~1.0.0
- yiisoft/yii2: ~2.0.0
README
Role Based Access Controll for yii2
Installation
The preferred way to install this extension is through composer.
Either run
php composer.phar require --prefer-dist it-yakutia/yii2-rbac "*"
or add
"it-yakutia/yii2-rbac": "*"
to the require section of your composer.json
file.
Models use yii2 DbManager class and required to run migration:
php yii migrate --migrationPath=@yii/rbac/migrations
Usage
Once the extension is installed, simply use it in your code by adding url on your navigation bar:
Url::toRoute('/rbac/permission/index'); Url::toRoute('/rbac/role/index'); Url::toRoute('/rbac/user/index');
This controllers are allowed for admin
role