1234567891011121314151617181920 |
- CREATE TABLE `tb_device_perm_group`(
- `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT 'ID',
- `group_type` INT(1) COMMENT '权限组类型 1 员工;2 访客',
- `group_name` VARCHAR(45) COMMENT '权限组名',
- `remark` VARCHAR(45) COMMENT '备注',
- `create_time` DATETIME DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '添加时间',
- `creator` BIGINT(20) DEFAULT NULL COMMENT '添加人',
- `modify_time` DATETIME DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '修改时间',
- `modify` BIGINT(20) DEFAULT NULL COMMENT '修改人',
- PRIMARY KEY (`ID`)
- )ENGINE=INNODB DEFAULT CHARSET=utf8 COMMENT='设备权限组表';
- CREATE TABLE `tr_perm_group_device` (
- `device_perm_group_id` BIGINT(20) NOT NULL COMMENT '设备组ID',
- `device_id` INT(11) NOT NULL COMMENT '设备部ID',
- KEY `fk_group_id` (`device_perm_group_id`) USING BTREE,
- KEY `fk_device_id` (`device_id`) USING BTREE
- ) ENGINE=INNODB DEFAULT CHARSET=utf8 COMMENT='设备组-设备关系表'
|