rbac
青春已被放纵了
研究自己喜欢的东西!
展开
-
yii2框架中写的原生的rbac权限
rbac权限原创 2016-12-14 11:34:41 · 474 阅读 · 0 评论 -
laravel 框架中手写rbac
<?php /** * Created by PhpStorm. * User: 青春已被放纵了 * Date: 2017/1/6 * Time: 16:30 */ namespace App\Http\Controllers; use Route; use Symfony\Component\HttpFoundation\Session\Session; use DB; clas原创 2017-01-07 08:45:08 · 28108 阅读 · 2 评论 -
rbac权限2
rbac权限原创 2016-12-14 11:46:36 · 402 阅读 · 0 评论 -
yii2自带rbac
控制器 <?php /** * Created by PhpStorm. * User: 青春已被放纵了 * Date: 2017/1/13 * Time: 14:12 */ namespace backend\controllers; use yii\web\Controller; use backend\models\Rbac; use Yii; use Db; c原创 2017-01-16 15:53:21 · 628 阅读 · 0 评论 -
rbac角色赋权
二维数组 $res = User::roleSelect(); $arr = User::userRoleSelect($admin_id); 循环遍历成一维数组 foreach ($res as $key => $value) { $re[$key] = $value['rule_name']; } foreach ($arr as $key => $value) {原创 2017-03-01 09:28:11 · 409 阅读 · 0 评论