|
|
INSERT INTO `sys_role` (`org_type`, `role_name`, `role_key`, `role_sort`, `data_scope`, `menu_check_strictly`, `dept_check_strictly`, `status`, `del_flag`, `create_by`, `create_time`, `update_by`, `update_time`, `remark`) VALUES ('1', '超级管理员', 'default', 0, 1, 1, 1, '0', 2, '超级管理员', '2023-12-07 17:14:07', '', NULL, '仅仅给超级管理员用,标记为删除状态,通过脚本维护了一条管理员与角色的关联数据,防止首页等依赖于登录用户角色信息的页面查询报错');
|
|
|
INSERT INTO `sys_user_role` (`user_id`, `role_id`, `create_by`, `create_time`, `update_by`, `update_time`) SELECT 1 as `user_id`, id as `role_id`, '超级管理员' as `create_by`, '2023-09-17 19:57:06' as `create_time`, NULL, NULL FROM `sys_role` WHERE `role_name`='超级管理员';
|