DELIMITER ??
DROP PROCEDURE IF EXISTS schema_change ??
CREATE PROCEDURE schema_change()
BEGIN


    -- 培训任务表增加主持人名称字段
    IF NOT EXISTS(SELECT *
                  FROM information_schema.columns
                  WHERE table_schema = DATABASE()
                    AND table_name = 'core_edu_training_task'
                    AND column_name = 'host_name') THEN
        alter table core_edu_training_task
            add host_name varchar(125) null comment '主持人名称' after host_id;
        update core_edu_training_task t inner join sys_user u on u.id=t.host_id set t.host_name=u.name;
    END IF;

    -- 演练任务表增加主持人名称字段
    IF NOT EXISTS(SELECT *
                  FROM information_schema.columns
                  WHERE table_schema = DATABASE()
                    AND table_name = 'core_drill_task'
                    AND column_name = 'host_name') THEN
        alter table core_drill_task
            add host_name varchar(125) null comment '指挥人名称' after host_id;
        update core_drill_task t inner join sys_user u on u.id=t.host_id set t.host_name=u.name;
    END IF;

    -- 角色表增加字段 特殊角色,值为1时仅管理员可见
    IF NOT EXISTS(SELECT *
                  FROM information_schema.columns
                  WHERE table_schema = DATABASE()
                    AND table_name = 'sys_role'
                    AND column_name = 'special') THEN
        alter table sys_role
            add special int  default 0 comment '特殊角色,值为1时仅管理员可见' after remark;
    END IF;


-- core_resumption_rule_item 表添加排序字段
    IF NOT EXISTS(SELECT *
                  FROM information_schema.columns
                  WHERE table_schema = DATABASE()
                    AND table_name = 'core_resumption_rule_item'
                    AND column_name = 'sort') THEN
        ALTER TABLE `core_resumption_rule_item`
            ADD COLUMN `sort` int DEFAULT NULL COMMENT '排序号' AFTER `update_by`;
    END IF;

-- core_resumption_rule_point 表添加排序字段
    IF NOT EXISTS(SELECT *
                  FROM information_schema.columns
                  WHERE table_schema = DATABASE()
                    AND table_name = 'core_resumption_rule_point'
                    AND column_name = 'sort') THEN
        ALTER TABLE `core_resumption_rule_point`
            ADD COLUMN `sort` int DEFAULT NULL COMMENT '排序号' AFTER `update_by`;
    END IF;

   IF NOT EXISTS(SELECT *
                  FROM information_schema.columns
                  WHERE table_schema = DATABASE()
                    AND table_name = 'sys_org'
                    AND column_name = 'yewd_level') THEN
    ALTER TABLE `sys_org`
        ADD COLUMN `yewd_level` int NULL COMMENT '营业网点层级（一级支行，二级支行）' AFTER `breviary`;
    END IF;

    -- core_safetycheck_rule_item 表添加排序字段
    IF NOT EXISTS(SELECT *
      FROM information_schema.columns
      WHERE table_schema = DATABASE()
        AND table_name = 'core_safetycheck_rule_item'
        AND column_name = 'sort') THEN
    ALTER TABLE `core_safetycheck_rule_item`
        ADD COLUMN `sort` int DEFAULT NULL COMMENT '排序号' AFTER `update_by`;
    END IF;

    -- core_safetycheck_rule_point 表添加排序字段
    IF NOT EXISTS(SELECT *
      FROM information_schema.columns
      WHERE table_schema = DATABASE()
        AND table_name = 'core_safetycheck_rule_point'
        AND column_name = 'sort') THEN
    ALTER TABLE `core_safetycheck_rule_point`
        ADD COLUMN `sort` int DEFAULT NULL COMMENT '排序号' AFTER `update_by`;
    END IF;

    -- 培训任务表增加地点字段
    IF NOT EXISTS(SELECT *
                  FROM information_schema.columns
                  WHERE table_schema = DATABASE()
                    AND table_name = 'core_edu_training_task'
                    AND column_name = 'site') THEN
        alter table core_edu_training_task
            add site varchar(225) null comment '地点' after status;
    END IF;




END ??
DELIMITER ;
CALL schema_change();

update sys_menu set menu_name='演练情况表' where menu_name = '演练统计排名' and platform_type = '0';
update sys_menu set menu_name='培训情况表' where menu_name = '培训统计报表' and platform_type = '0';

-- App新增监控调阅情况表
delete from sys_menu where id='1795636152338771970';
INSERT INTO sys_menu (id, menu_name, parent_id, order_num, path, component, query, is_frame, is_cache, menu_type, visible, status, perms, platform_type, icon, image_path, create_by, create_time, update_by, update_time, remark) VALUES (1795636152338771970, '监控调阅情况表', 1726900357129232386, 100, '/monitorStatistics', null, null, 1, 0, 'C', '0', '0', '', '0', 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAAAXNSR0IArs4c6QAADPtJREFUeF7tnV1y2zgQhKWTbVKbIyXP8T5vjpRUvCfThi7JRduSiJ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TrBJQ5+3LS1OvV0oI07YJ9272a9vdL++QX6hRvUdeZhCt3o5mBhgGbBCGR/fyoAz8D3zEjMhpRbADAAAAAElFTkSuQmCC', null, '超级管理员', '2024-05-29 10:00:17', '超级管理员', '2024-05-29 10:01:04', '');
delete from sys_role_menu where menu_id=1795636152338771970;
insert into sys_role_menu select  id,1795636152338771970 from sys_role where org_type in (1,2,3);

-- App新增履职情况表
delete from sys_menu where id=1795728843273695233;
INSERT INTO sys_menu (id, menu_name, parent_id, order_num, path, component, query, is_frame, is_cache, menu_type, visible, status, perms, platform_type, icon, image_path, create_by, create_time, update_by, update_time, remark) VALUES (1795728843273695233, '履职情况表', 1726900357129232386, 200, '/resumptionStatistics', null, null, 1, 0, 'C', '0', '0', null, '0', 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAAAXNSR0IArs4c6QAACpdJREFUeF7tnQtu4zoSReW9ZB+dBl7W1cm6EqCTfWQveq34E38imyzeIsvkaWCAwQxZUp3iESlKVjYT/yAAgVUCG9hAAALrBBCE0QGBKwQQhOEBAQRhDEDARoAZxMaNXoMQQJBBCk2aNgIIYuNGr0EIIMgghSZNGwEEsXGj1yAEEGSQQpOmjQCC2LjRaxACCDJIoUnTRgBBbNzoNQgBBBmk0KRpI4AgNm70GoQAggxSaNK0EUAQGzd6DUIAQQYpNGnaCCCIjRu9BiGAIIMUmjRtBBDExk3a6+F1fpymafnPNG2mX4fg8/Sx/++fT5tn6UEJlkQAQZIw6Rt9SbGZ/hzESDvE+zRPH8iSBkvRCkEUFDNiGMW4PMI8vSBKBnhjUwQxgsvtJhPj/MCIkluKrPYIkoXL1ngnx19b74ReSJIAydYEQWzckns9vM7Pu3uN5D7Ghu+f/21+G/vSbYUAgjgOjYpy7LNAEnE9EUQMdB/OfVm1ft5IIqwpgghhHod6eJtnp9C3w3JPcptRYgsESQSV06zB0ury9Obp9+fT5j3nvGl7SQBBHEZF09njOx+WWoLaIogA4snSqt6u1e0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CSlIdUkc5GgiiVMeVSVxysEqSVhBqklSoSBVllvOV90KObxP21o0eWJ+dzNIlW1T50F1duPutdyqNrAcJQlzz3EuSugZxG2AVZg11q5I0kHWII+vHbrlzWvNdnw1ubtcYv2UVOEAC1GQrxy2T6H+GAq35PDR6vXvk3urO88hhf3dzCDnyRwNsl9XfkuyXc8GXNv+MNDuNo/kWszTy5J3tPuMa6LcrSBXljCP91SAlVmSHFIu7xXadCdIBWYcYiACCDJQsUk1nwCC5DOjx0AEEGSgYpNqPgEEyWdGj4EIIMhAxSbVfAIIks+MHgMRQJCBik2q+QQQJJ8ZPQYigCADFZtU8wkgSD4zegxEAEEGKjap5hNwF2T3+4H8M6MHBAwE1C+quglS+LsNAxq6QGBHQPhDMrkgu29CLT8ECvf3PhhAgxEQiKIXJOLn8wcbF6R7RKDwuwNSQVhWMTQDEij6IASCBKwopyQlEEgQllfSyhJMQ6DkU6zaGQRBNBUlipRAHEEi/PkCKVqCdUAg0BKr5ZfZO6gkKTgQKNzqlS6xlvTYyXIoMiFtBArlWA4qFwRJbLWkl5iAQA43Qfapnn1xT0yAcBD4gcA8ffx7i+Nd9U6WywxC4SDQCwEE6aWS5OFCAEFcsBK0FwII0kslycOFAIK4YCVoLwQQpJdKkocLAQRxwUrQXgggSC+VJA8XAgjigpWgvRBAkF4qSR4uBBDEBStBeyGAIL1UkjxcCCCIC1aC9kIAQXqpJHm4EEAQF6wE7YUAgvRSSfJwIYAgLlgJ2gsBBOmlkuThQgBBXLAStBcCCNJLJcnDhQCCuGAlaC8EEKSXSpKHCwEEccFK0F4IIEgvlSQPFwL/AyGM+CNwuhVnAAAAAElFTkSuQmCC', null, '超级管理员', '2024-05-29 16:08:37', '', null, '');
delete from sys_role_menu where menu_id=1795728843273695233;
insert into sys_role_menu select  id,1795728843273695233 from sys_role where org_type in (1,2,3);

-- App新增行社全面检查情况表
delete from sys_menu where id=1797808947080466434;
INSERT INTO sys_menu (id, menu_name, parent_id, order_num, path, component, query, is_frame, is_cache, menu_type, visible, status, perms, platform_type, icon, image_path, create_by, create_time, update_by, update_time, remark) VALUES (1797808947080466434, '行社检查情况表', 1726900357129232386, 300, '/safeCheckStatistics', null, null, 1, 0, 'C', '0', '0', null, '0', 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAYAAACtWK6eAAAAAXNSR0IArs4c6QAAFHRJREFUeF7tnV2S5TQShe2aiGH6DWYDsJOuXgawGG4vBmYZFDuBDQBvwETQntG911Uul+08J5WSUrL6ZYIpWT+p/HQyJfl6HPq/boFugV0LjN023QLdAvsW6IB07+gWOLBAB6S7R7dAB6T7QLeAzgJdQXR2S/LUH5fPH0PF7y6/PyVpoFdKW6ADQpsMf2B2+GF4eByH6f3qySsM5L8rONMw/vTy3KenDhRpRaJ4B4Qw1lbRHQg0zh/ZkwDO9KHDEm3GVxV0QEh7zkCMw/jd/dEiMGx1WwLkr++/unz27c8XcsinLt4BEabfMxDrrv/r8tvufAY4hnG6QT2NH8P/dFhk9jsgOzYKYNxVwo1CCNP59K/Lbx/2yrwCZFmow3Jo1g7IwjwVQvHc+2kYP767/LobPv33hy9/nIbhGPYOyxtYTg9IzVC8EgIhQf/rhy8nOaBYlOiwXI1xWkAKgPHmbOP1dm2Yjk/3Mg+bK/1iq/jN34/yjz/+89XjwzT9SAGyCsPOmq+cDpA/Lv++3B0tVW6xOKu4OXyqrdfbBkKA6fgsZDf/YImZxo9nA+U0gNzBmLdmWdfYK3+HYbruCqUCIbazUP7BNHIiUJoHJAEYT9PgG4gtXw8qMo7TezFR76C8skCzgBiC8awSXhWC8elQ1hyWhhWlOUAMk++rUrQCxdH5iJmyNAhKM4AYgXEKKA4PE697m/cTd1aaQvnGIGkCEINw6tRgrDm47np1UOo/B4lVjXD6LG2RahbRVp6JBqUBNalWQWJUQ7qW0YqDW44j6iylYlCqAyRGNUqDsXx3ZHbejRep3vj11ol7qc0DNSiVQlIVIHc4NFcmDm+6Wq60oa75hPvoaohFmyWBPwso1QCiDKmyJ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MSqSXAaLyvUHJqtJ+4equ3O5zQE55//3T4bnVMZ9jqmCae8h1Rv58YCs0x1aCS8tgnJZMroZvRzMbkOqaoGJHReu2p1UKKZuFYQYf8qQqrqAYkJueZnS+YnNm6av5aYW9A127uaHGTLJbQy30HBAYu0cZWqsbRO1YBYqEkPvbZhiQQjyc1rHGu7kk0AYgnKbXfo14udieupKSK/WA6yetVoTkGWA4pd+Zbh1xlgMYIimKopMGY/aEpBUoAyh2CezlNiNcn6qkzNSbhky2YBsQq71gYMzlCbstyACDeSrzcSwr/rfxv8a1I1mg6x9ibdKvSqAZiEQMzDbx6M5kOs3KAs2ntaXw1JddVlBmFxs9hSHd6YsOVQas9fmg+xCoKy1fTzParXEC2LhrtWt4uOL6vYFG4Jr/9ZhUlipHVGME6rIGtvCKFX+P8afWNQdP6DAqcJo46MdFoF2TJKzHWKGE909GyHYjUZHZAN71xsg7b4Hvp6xNneNnS0EMBd6YAIprI+M4BnJm3BpD/WkLbreWvvgJD2rhSY+86an5fHSLMXK94BiTT9nOTfE30P76S/egU31RZzpNmqebwDkmiqlq/XLl6ptdqaLf4eeiKzuau2A1J4Sl4O+7Y70hWg7AR1QMrav7fu3AIdEOcT1LtX1gIdkLL27607t0AHxPkE9e6VtUAHpKz9e+vOLfA/h5bBqlc6lpgAAAAASUVORK5CYII=', null, '景远超', '2024-06-04 09:53:23', '', null, '');
delete from sys_role_menu where menu_id=1797808947080466434;
insert into sys_role_menu select  id,1797808947080466434 from sys_role where org_type in (1,2,3);

-- App新增网点自查情况表
delete from sys_menu where id=1797883556555395073;
INSERT INTO sys_menu (id, menu_name, parent_id, order_num, path, component, query, is_frame, is_cache, menu_type, visible, status, perms, platform_type, icon, image_path, create_by, create_time, update_by, update_time, remark) VALUES (1797883556555395073, '网点自查情况表', 1726900357129232386, 400, '/safeCheckSelfStatistics', null, null, 1, 0, 'C', '0', '0', '', '0', 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAANQAAADICAYAAACQys/4AAAAA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zYYSympUicslNrfIQ2daw5DLibDWEUFZnYo8bD7n6WTEaTaruhRpx48GbVCNtWHQrlNVSZoTkYLbKPSXFH1R3+EdCbA8qDPMYdiWU1azU+sZDXmrY3UFy7E+nP7fvRiirM+oIS7w14azY9ihVF0Kx8bCmxPbPraTq7YTVtFBWS7zegrxdJ74MTmXYrFBWZ8welyGpyZBaDvbnSTUnlNWsNOrGQ6pE78tZxqHlk1pTQlmdGXu64yFXkNx6VjFpVapmhGLjITfl7etZSdXitax7oayWFi0Gy16NbUewEqul2cq1UARoW4LXqD16zFwLZfE4rJZ/alFDkNxjqi/RG7mzwrVQMZhaZzw2HnLVyK+nFTuWfPkx+LDm5rNdI2c3ZWwumtu6ymjtROh+hlqyIkcqNh5cOHXsRO5s1doSvRmhxGc6ZiU/Nr32RCxVgzFsRqjUsxyzkjuP/upQklgNyhQH2pRQa1K1tt72n/p2PbwkVctxbE6oGOIPr6caPaPZpaz/ls99ad/addMp6SaFOr2eYonnX5y1Hv5vtmr8xNikUDFAR6kO4ebl6+5hLWB87p/AUaoQQuvx/A8YdFpZrBJIOQAAAABJRU5ErkJggg==', null, '超级管理员', '2024-06-04 14:49:52', '景远超', '2024-06-04 15:00:04', '');
delete from sys_role_menu where menu_id=1797883556555395073;
insert into sys_role_menu select  id,1797883556555395073 from sys_role where org_type in (1,2,3);

-- 新增短信发送记录查询功能
delete from sys_menu where id=1798589671832403970;
INSERT INTO sys_menu (id, menu_name, parent_id, order_num, path, component, query, is_frame, is_cache, menu_type, visible, status, perms, platform_type, icon, image_path, create_by, create_time, update_by, update_time, remark) VALUES (1798589671832403970, '短信发送记录', 2, 300, '/smsSendLog', 'system/smsSendLog', null, 1, 0, 'C', '0', '0', '', '1', 'list', null, '超级管理员', '2024-06-06 13:35:46', '超级管理员', '2024-06-06 13:39:30', '');
delete from sys_role_menu where menu_id=1798589671832403970;
insert into sys_role_menu select  id,1798589671832403970 from sys_role where org_type in (1,2,3,4);

-- 新增 营业网点层级字典
DELETE FROM `sys_dict_type` WHERE `dict_type` ='sys_org_yewd_level';
INSERT INTO `sys_dict_type` (`dict_name`, `dict_type`, `status`, `create_by`, `create_time`, `update_by`, `update_time`, `remark`) VALUES ('营业网点层级', 'sys_org_yewd_level', '0', '超级管理员', '2024-05-30 15:59:25', '', NULL, NULL);

DELETE FROM `sys_dict_data` WHERE `dict_type` ='sys_org_yewd_level';
INSERT INTO `sys_dict_data` (`dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `status`, `create_by`, `create_time`, `update_by`, `update_time`, `remark`) VALUES (1, '一级支行', '1', 'sys_org_yewd_level', NULL, 'default', 'N', '0', '超级管理员', '2024-05-30 15:59:45', '', NULL, NULL);
INSERT INTO `sys_dict_data` (`dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `status`, `create_by`, `create_time`, `update_by`, `update_time`, `remark`) VALUES (2, '二级支行', '2', 'sys_org_yewd_level', NULL, 'default', 'N', '0', '超级管理员', '2024-05-30 15:59:55', '', NULL, NULL);

delete from sys_dict_type where dict_type='sms_notify_type';
delete from sys_dict_data where dict_type='sms_notify_type';
INSERT INTO sys_dict_type (dict_name, dict_type, status, create_by, create_time, update_by, update_time, remark) VALUES ('短信提醒类型', 'sms_notify_type', '0', '超级管理员', '2024-06-06 14:15:13', '', null, null);
INSERT INTO sys_dict_data (dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, update_by, update_time, remark) VALUES (10100, '临期提醒', '10100', 'sms_notify_type', null, 'default', 'N', '0', '超级管理员', '2024-06-06 14:15:50', '', null, null);
INSERT INTO sys_dict_data (dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, update_by, update_time, remark) VALUES (10200, '逾期提醒', '10200', 'sms_notify_type', null, 'default', 'N', '0', '超级管理员', '2024-06-06 14:16:03', '', null, null);
INSERT INTO sys_dict_data (dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, update_by, update_time, remark) VALUES (4184, '水浸告警', '4184', 'sms_notify_type', null, 'default', 'N', '0', '超级管理员', '2024-06-06 14:17:15', '', null, null);
INSERT INTO sys_dict_data (dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, update_by, update_time, remark) VALUES (4183, '温湿度告警', '4183', 'sms_notify_type', null, 'default', 'N', '0', '超级管理员', '2024-06-06 14:17:42', '', null, null);
INSERT INTO sys_dict_data (dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, update_by, update_time, remark) VALUES (4182, '烟感告警', '4182', 'sms_notify_type', null, 'default', 'N', '0', '超级管理员', '2024-06-06 14:18:09', '', null, null);
INSERT INTO sys_dict_data (dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, update_by, update_time, remark) VALUES (4181, '红外告警', '4181', 'sms_notify_type', null, 'default', 'N', '0', '超级管理员', '2024-06-06 14:18:28', '', null, null);
INSERT INTO sys_dict_data (dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, update_by, update_time, remark) VALUES (41885, '燃气告警', '41885', 'sms_notify_type', null, 'default', 'N', '0', '超级管理员', '2024-06-06 14:18:53', '', null, null);
INSERT INTO sys_dict_data (dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, update_by, update_time, remark) VALUES (41881, '盗情告警', '41881', 'sms_notify_type', null, 'default', 'N', '0', '超级管理员', '2024-06-06 14:19:44', '', null, null);
INSERT INTO sys_dict_data (dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, update_by, update_time, remark) VALUES (4188, '门磁告警', '4188', 'sms_notify_type', null, 'default', 'N', '0', '超级管理员', '2024-06-06 14:20:53', '', null, null);




-- core_resumption_rule_item 刷排序号
UPDATE core_resumption_rule_item
SET sort = (
    SELECT
        newSort
    FROM
        ( SELECT id, rule_id, `name`, ROW_NUMBER () OVER ( PARTITION BY rule_id ORDER BY `name` ) AS newSort FROM core_resumption_rule_item WHERE deleted = 0 ) AS SortData
    WHERE
            SortData.id = core_resumption_rule_item.id
);

-- core_resumption_rule_point 刷排序号
UPDATE core_resumption_rule_point
SET sort = (
    SELECT
        newSort
    FROM
        ( SELECT id, item_id, `name`, ROW_NUMBER () OVER ( PARTITION BY item_id ORDER BY `name` ) AS newSort FROM core_resumption_rule_point WHERE deleted = 0 ) AS SortData
    WHERE
            SortData.id = core_resumption_rule_point.id
);

-- core_safetycheck_rule_item 刷排序号
UPDATE core_safetycheck_rule_item
SET sort = (
    SELECT
        newSort
    FROM
        ( SELECT id, rule_id, `name`, ROW_NUMBER () OVER ( PARTITION BY rule_id ORDER BY `name` ) AS newSort FROM core_safetycheck_rule_item WHERE deleted = 0 ) AS SortData
    WHERE
            SortData.id = core_safetycheck_rule_item.id
);

-- core_safetycheck_rule_point 刷排序号
UPDATE core_safetycheck_rule_point
SET sort = (
    SELECT
        newSort
    FROM
        ( SELECT id, item_id, `name`, ROW_NUMBER () OVER ( PARTITION BY item_id ORDER BY `name` ) AS newSort FROM core_safetycheck_rule_point WHERE deleted = 0 ) AS SortData
    WHERE
            SortData.id = core_safetycheck_rule_point.id
);

-- 刷表的创建时间和修改时间
update core_resumption_rule SET create_time = NOW() where create_time IS NULL;
update core_resumption_rule SET update_time = create_time where update_time IS NULL;

update core_resumption_plan SET create_time = NOW() where create_time IS NULL;
update core_resumption_plan SET update_time = create_time where update_time IS NULL;

update core_safetycheck_rule SET create_time = NOW() where create_time IS NULL;
update core_safetycheck_rule SET update_time = create_time where update_time IS NULL;

update core_safecheck_plan SET create_time = NOW() where create_time IS NULL;
update core_safecheck_plan SET update_time = create_time where update_time IS NULL;

update core_monitoring_retrieval_plan SET create_time = NOW() where create_time IS NULL;
update core_monitoring_retrieval_plan SET update_time = create_time where update_time IS NULL;

update core_edu_training_plan SET create_time = NOW() where create_time IS NULL;
update core_edu_training_plan SET update_time = create_time where update_time IS NULL;

update core_drill_plan SET create_time = NOW() where create_time IS NULL;
update core_drill_plan SET update_time = create_time where update_time IS NULL;

-- core_safety_task 刷检查开始时间和结束时间
update core_safety_task set start_time = submit_time,end_time = submit_time where submit_by is not null;

-- 短信发送记录表
drop table if exists sms_send_record;
create table sms_send_record
(
    id                 bigint       not null comment '主键'
        primary key,
    type               varchar(32)  not null comment '提醒类型,见字典',
    type_text          varchar(64)  null comment '提醒类型名称',
    time               datetime     not null comment '发送时间',
    tran_type          int          not null comment '交易类型',
    org_id             bigint       not null comment '接收机构id',
    org_name           varchar(125) not null comment '接收机构名称',
    user_id            bigint       not null comment '短信接收人id',
    user_name          varchar(125) not null comment '接受人名称',
    user_phone         varchar(125) not null comment '接收人联系方式',
    content_data       varchar(225) not null comment '短信内容',
    result             varchar(225) null comment '发送结果',
    result_description varchar(125) null comment '发送结果描述',
    req_detail        varchar(5000) null comment '短信发送请求详情',
    resp_detail        varchar(1000) null comment '短信发送返回详情'
)
    comment '短信发送记录';

create index idx_orgId
    on sms_send_record (org_id);

update core_safety_task set start_time = submit_time,end_time = submit_time where submit_by is not null;

-- 新增没有办事处的地区系统配置
DELETE FROM `sys_config` WHERE `config_key` ='NO_BSC_AREA';
INSERT INTO `sys_config` (`config_name`, `config_key`, `config_value`, `config_type`, `create_by`, `create_time`, `update_by`, `update_time`, `remark`) VALUES ('演练地区评优推优由省联社直接管理的地区', 'NO_BSC_AREA', '4358025846521957,1739556950966714370', 'Y', '超级管理员', '2024-05-31 10:25:25', '', NULL, NULL);

-- 修改菜单名称
UPDATE sys_menu set menu_name ='视频监测' WHERE menu_name = '智能运维';
-- 修改菜单名称: "来访"全局替换成"出入"
UPDATE sys_menu SET menu_name = REPLACE(menu_name, '来访', '出入') where menu_name like '%来访%';
-- 修改字典名称: "来访"全局替换成"出入"
update sys_dict_data set dict_label='出入管理登记簿' where dict_type='register_book_type' and dict_label='来访管理登记簿' limit 1;