php管理员权限表,权限表的建立

1,新建三张表think_auth_group,think_auth_group_access,think_auth_rules

CREATE TABLE think_auth_group(

id int(11) not null primary key auto_increment,

title char(100) NOT NULL,

status tinyint(1) DEFAULT NULL,

rules char(80) DEFAULT NULL,

create_time int(11) DEFAULT NULL)

ENGINE=InnoDB DEFAULT CHARSET=utf8;

3d8f8bf2969f0734d3cf3825653cf261.png

CREATE TABLE `think_auth_group_access` (

`uid` smallint(5) unsigned NOT NULL,

`group_id` smallint(5) unsigned NOT NULL,

UNIQUE KEY `uid_group_id` (`uid`,`group_id`),

KEY `uid` (`uid`),

KEY `group_id` (`group_id`)

) ENGINE=INNODB DEFAULT CHARSET=utf8;

c508ea8ad501c95c0260cf4435cf7893.png

CREATE TABLE think_auth_rules(

id int(11) not null primary key auto_increment,

name varchar(100) NOT NULL,

title varchar(100) NOT NULL,

type tinyint(1) DEFAULT NULL,

status tinyint(1) DEFAULT NULL,

condition char(100) DEFAULT NULL,

pid smallint(5) DEFAULT NULL,

sort tinyint(4) DEFAULT NULL,

create_time int(11) DEFAULT NULL)

ENGINE=InnoDB DEFAULT CHARSET=utf8;

1c10c4c08a203f8994c6fdfa44872b0c.png

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值