corneltek/kendo

强大的通用访问控制框架

1.0.4 2013-09-14 12:21 UTC

This package is auto-updated.

Last update: 2024-08-29 03:58:08 UTC


README

Build Status

Latest Stable Version Total Downloads Latest Unstable Version License

Monthly Downloads Daily Downloads

安装

{
    "require": { 
        "corneltek/kendo": "*"
    }
}

开发环境搭建

composer install --dev
lazy build-conf db/config/database.yml
lazy schema build src
lazy sql --rebuild --basedata src
phpunit

调试

查询权限

SELECT ar.resource, ac.role, ar.operation, ac.allow FROM access_controls ac LEFT JOIN access_rules ar ON (ac.rule_id = ar.id);
SELECT ar.id as rule_id, ar.rules_class as rule_class, ac.role,
  if(ac.allow,'can', 'can not') as modal_verb, ar.operation, ar.resource 
FROM
  access_controls ac 
LEFT JOIN access_rules ar ON (ac.rule_id = ar.id);