hazicms/auth
Composer 安装命令:
composer require hazicms/auth
包简介
Basic authentication with CRUD for users,roles and permissions.
README 文档
README
AuthBasicMiddleware has the next permissions:
- All user with role 'admin', has all permissions.
- index action: none permission.appear only our resources. all if in 'admin' role.
- create action: need to be 'create.MODEL' permission.
- edit action: need to be 'edit.MODEL' permission and be creator of this resource.
- delete action: need to be 'delete.MODEL' permission and be creator of this resource.
Steps to Get Started
-
Add this package to your composer.json:
"require": { "hazicms/auth": "dev-master" } -
Run composer update
composer update -
Add the ServiceProviders to the providers array in
config/app.php.'HaziCms\Auth\AuthServiceProvider' -
Publish config files for generators, modules and images:
php artisan vendor:publish --provider="HaziCms\Generator\Generator\GeneratorServiceProvider" -
Add those lines to
app\Http\Kernel.phpfile:protected $routeMiddleware = [ 'hazicms.basic' => 'HaziCms\Http\Middleware\AuthBasicMiddleware', ]; -
Add middleware to controller's __construct() method:
$this->middleware('hazicms.basic'); -
You are ready! :-)
Credits
This module is created by Aitor Ibañez.
Bugs & Forks are welcomed :)
统计信息
- 总下载量: 19
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: GPL-3.0
- 更新时间: 2015-05-17