增加为admin角色分配新菜单的sql
This commit is contained in:
@@ -7,6 +7,8 @@ INSERT INTO sys_menu (`parent_id`, `parent_ids`, `code`, `name`, `sort`, `href`,
|
||||
INSERT INTO sys_menu (`parent_id`, `parent_ids`, `code`, `name`, `sort`, `href`, `target`, `icon`, `is_show`, `permission`, `create_by`, `create_date`, `update_by`, `update_date`, `remarks`, `del_flag`, `menu_bg`, `quick_action`, `is_top`, `function_id`) VALUES (1121, '0,1,86,717,1121,', 'traffic_mirror_address', '流量转发目的地址', 8, '/proxy/fileTrafficMirror/list', '', '', 1, 'proxy:fileTrafficMirror:config', '1', '2019-05-09 16:03:58', '1', '2019-05-09 16:03:58', '', 1, NULL, 0, 0, 515);
|
||||
INSERT INTO sys_menu (`parent_id`, `parent_ids`, `code`, `name`, `sort`, `href`, `target`, `icon`, `is_show`, `permission`, `create_by`, `create_date`, `update_by`, `update_date`, `remarks`, `del_flag`, `menu_bg`, `quick_action`, `is_top`, `function_id`) VALUES (1122, '0,1,150,750,1122,', 'traffic_mirror_address', '流量转发目的地址', 426, '/proxy/fileTrafficMirror/list', '', '', 1, 'proxy:fileTrafficMirror:confirm', '1', '2019-05-09 16:06:17', '1', '2019-05-09 16:06:17', '', 1, NULL, 0, 0, 515);
|
||||
INSERT INTO sys_menu (`parent_id`, `parent_ids`, `code`, `name`, `sort`, `href`, `target`, `icon`, `is_show`, `permission`, `create_by`, `create_date`, `update_by`, `update_date`, `remarks`, `del_flag`, `menu_bg`, `quick_action`, `is_top`, `function_id`) VALUES (1123, '0,1,151,865,1123,', 'traffic_mirror_address', '流量转发目的地址', 39, '/proxy/fileTrafficMirror/list', '', '', 1, 'proxy:fileTrafficMirror:audit', '1', '2019-05-09 16:07:13', '1', '2019-05-09 16:07:13', '', 1, NULL, 0, 0, 515);
|
||||
#打开文件策略模块---->新加了阻断文件访问界面,无需打开此菜单
|
||||
#update sys_menu set is_show=1,del_flag=1 where code='file_strategy';
|
||||
|
||||
INSERT INTO function_service_dict (`function_id`, `protocol_id`, `action`, `action_code`, `service_id`, `service_name`, `service_desc`, `is_valid`, `creator_id`, `create_time`, `editor_id`, `edit_time`, `region_code`, `is_import`, `sort`, `config_do_log`) VALUES (513, 0, 1, 'monit', 643, 'hijack_file_strategy', '', 1, NULL, '0000-00-00 00:00:00', NULL, '0000-00-00 00:00:00', '', 0, 1, '');
|
||||
INSERT INTO function_service_dict (`function_id`, `protocol_id`, `action`, `action_code`, `service_id`, `service_name`, `service_desc`, `is_valid`, `creator_id`, `create_time`, `editor_id`, `edit_time`, `region_code`, `is_import`, `sort`, `config_do_log`) VALUES (514, 0, 1, 'monit', 644, 'file_insert_script', '', 1, NULL, '0000-00-00 00:00:00', NULL, '0000-00-00 00:00:00', '', 0, 1, '');
|
||||
@@ -16,8 +18,7 @@ INSERT INTO function_service_dict (`function_id`, `protocol_id`, `action`, `acti
|
||||
|
||||
ALTER TABLE proxy_file_strategy_cfg ADD cancel_request_id INT(11) NULL COMMENT '取消审核来函';
|
||||
|
||||
|
||||
/*注入脚本文件*/
|
||||
#注入脚本文件
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
CREATE TABLE `pxy_profile_insert_scripts` (
|
||||
@@ -51,7 +52,7 @@ CREATE TABLE `pxy_profile_insert_scripts` (
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
/*内容劫持文件*/
|
||||
#内容劫持文件
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
CREATE TABLE `pxy_profile_hijack_files` (
|
||||
@@ -86,7 +87,7 @@ CREATE TABLE `pxy_profile_hijack_files` (
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
/*流量转发目的地址*/
|
||||
#流量转发目的地址
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
CREATE TABLE `pxy_profile_traffic_mirror` (
|
||||
@@ -118,4 +119,7 @@ CREATE TABLE `pxy_profile_traffic_mirror` (
|
||||
PRIMARY KEY (`cfg_id`) USING BTREE
|
||||
) ENGINE = InnoDB AUTO_INCREMENT = 54 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
#为admin角色分配新的菜单权限
|
||||
insert into sys_privilege (PRIVILEGE_MASTER,PRIVILEGE_MASTER_VALUE,PRIVILEGE_ACCESS,PRIVILEGE_ACCESS_VALUE,PRIVILEGE_OPERATION ) select 'ROLE',r.id,1000,m.id,1 from sys_role r,sys_menu m where r.name='admin' and m.code in ('hijack_file_strategy','file_insert_script','traffic_mirror_address');
|
||||
Reference in New Issue
Block a user