diff --git a/hzims-service/hzims-alarm/src/main/resources/db/1.0.0.sql b/hzims-service/hzims-alarm/src/main/resources/db/1.0.0.sql index 5cd79a5..85c309f 100644 --- a/hzims-service/hzims-alarm/src/main/resources/db/1.0.0.sql +++ b/hzims-service/hzims-alarm/src/main/resources/db/1.0.0.sql @@ -266,4 +266,4 @@ CREATE TABLE IF NOT EXISTS `hzims_interruption_alarm` ( `UPDATE_TIME` datetime NULL DEFAULT NULL COMMENT '更新时间', `IS_DELETED` tinyint(4) NOT NULL COMMENT '是否删除', PRIMARY KEY (`ID`) USING BTREE - ) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = DYNAMIC; \ No newline at end of file +) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = DYNAMIC; \ No newline at end of file diff --git a/hzims-service/hzims-middle/src/main/resources/db/2.0.0.sql b/hzims-service/hzims-middle/src/main/resources/db/2.0.0.sql index 85817cf..3510c9b 100644 --- a/hzims-service/hzims-middle/src/main/resources/db/2.0.0.sql +++ b/hzims-service/hzims-middle/src/main/resources/db/2.0.0.sql @@ -1,6 +1,5 @@ -INSERT INTO `process_dict` (`dict_code`, `dict_sort`, `dict_key`, `dict_value`, `dict_label`, `dict_type`, `is_default`, `status`, `create_dept`, `create_time`, `update_time`, `remark`) VALUES (9, 9, 'offlineWorkTicket', 'offlineWorkTicket', '线下工作票', '线下工作票', 'Y', 0, NULL, '2023-12-28 16:35:10', '2023-12-28 16:35:14', '线下工作票流程'); - -INSERT INTO `PROCESS_DICT` (`DICT_CODE`, `DICT_SORT`, `DICT_KEY`, `DICT_VALUE`, `DICT_LABEL`, `DICT_TYPE`, `IS_DEFAULT`, `STATUS`, `CREATE_DEPT`, `CREATE_TIME`, `UPDATE_TIME`, `REMARK`) VALUES (9, 9, 'WORK_TASK', 'WORK_TASK', '工作任务单V4', '工作任务单', 'Y', 0, NULL, '2023-07-25 18:35:01', '2024-01-09 14:48:18', '工作任务单流程'); -INSERT INTO `PROCESS_DICT`(`DICT_CODE`, `DICT_SORT`, `DICT_KEY`, `DICT_VALUE`, `DICT_LABEL`, `DICT_TYPE`, `IS_DEFAULT`, `STATUS`, `CREATE_DEPT`, `CREATE_TIME`, `UPDATE_TIME`, `REMARK`) VALUES (10, 10, 'HAZARD_RISK', 'HAZARD_RISK', '风险排查', '风险排查', 'Y', 0, NULL, '2023-07-25 18:35:01', '2023-09-19 22:35:40', '风险排查流程'); -INSERT INTO `PROCESS_DICT`(`DICT_CODE`, `DICT_SORT`, `DICT_KEY`, `DICT_VALUE`, `DICT_LABEL`, `DICT_TYPE`, `IS_DEFAULT`, `STATUS`, `CREATE_DEPT`, `CREATE_TIME`, `UPDATE_TIME`, `REMARK`) VALUES (11, 11, 'DEALALARM', 'DEALALARM', '告警处理流程', '告警处理流程', 'Y', 0, NULL, '2024-02-19 16:56:10', '2024-02-19 16:56:34', '告警处理流程'); -INSERT INTO `PROCESS_DICT`(`DICT_CODE`, `DICT_SORT`, `DICT_KEY`, `DICT_VALUE`, `DICT_LABEL`, `DICT_TYPE`, `IS_DEFAULT`, `STATUS`, `CREATE_DEPT`, `CREATE_TIME`, `UPDATE_TIME`, `REMARK`) VALUES (12, 12, 'HIDDENDANGERCHECK', 'HIDDENDANGERCHECK', '隐患排查', '隐患排查', 'Y', 0, NULL, '2023-07-25 18:35:01', '2023-07-25 18:35:01', '隐患排查流程'); \ No newline at end of file +INSERT INTO `process_dict` (`dict_code`, `dict_sort`, `dict_key`, `dict_value`, `dict_label`, `dict_type`, `is_default`, `status`, `create_dept`, `create_time`, `update_time`, `remark`) VALUES (10, 10, 'offlineWorkTicket', 'offlineWorkTicket', '线下工作票', '线下工作票', 'Y', 0, NULL, '2023-12-28 16:35:10', '2023-12-28 16:35:14', '线下工作票流程'); +INSERT INTO `PROCESS_DICT`(`DICT_CODE`, `DICT_SORT`, `DICT_KEY`, `DICT_VALUE`, `DICT_LABEL`, `DICT_TYPE`, `IS_DEFAULT`, `STATUS`, `CREATE_DEPT`, `CREATE_TIME`, `UPDATE_TIME`, `REMARK`) VALUES (11, 11, 'HAZARD_RISK', 'HAZARD_RISK', '风险排查', '风险排查', 'Y', 0, NULL, '2023-07-25 18:35:01', '2023-09-19 22:35:40', '风险排查流程'); +INSERT INTO `PROCESS_DICT`(`DICT_CODE`, `DICT_SORT`, `DICT_KEY`, `DICT_VALUE`, `DICT_LABEL`, `DICT_TYPE`, `IS_DEFAULT`, `STATUS`, `CREATE_DEPT`, `CREATE_TIME`, `UPDATE_TIME`, `REMARK`) VALUES (12, 12, 'DEALALARM', 'DEALALARM', '告警处理流程', '告警处理流程', 'Y', 0, NULL, '2024-02-19 16:56:10', '2024-02-19 16:56:34', '告警处理流程'); +INSERT INTO `PROCESS_DICT`(`DICT_CODE`, `DICT_SORT`, `DICT_KEY`, `DICT_VALUE`, `DICT_LABEL`, `DICT_TYPE`, `IS_DEFAULT`, `STATUS`, `CREATE_DEPT`, `CREATE_TIME`, `UPDATE_TIME`, `REMARK`) VALUES (13, 13, 'HIDDENDANGERCHECK', 'HIDDENDANGERCHECK', '隐患排查', '隐患排查', 'Y', 0, NULL, '2023-07-25 18:35:01', '2023-07-25 18:35:01', '隐患排查流程'); +INSERT INTO `PROCESS_DICT` (`DICT_CODE`, `DICT_SORT`, `DICT_KEY`, `DICT_VALUE`, `DICT_LABEL`, `DICT_TYPE`, `IS_DEFAULT`, `STATUS`, `CREATE_DEPT`, `CREATE_TIME`, `UPDATE_TIME`, `REMARK`) VALUES (14, 14, 'WORK_TASK', 'WORK_TASK', '工作任务单V4', '工作任务单', 'Y', 0, NULL, '2023-07-25 18:35:01', '2024-01-09 14:48:18', '工作任务单流程'); diff --git a/hzims-service/inspect/src/main/resources/db/1.0.0.sql b/hzims-service/inspect/src/main/resources/db/1.0.0.sql index 451c14a..45e932a 100644 --- a/hzims-service/inspect/src/main/resources/db/1.0.0.sql +++ b/hzims-service/inspect/src/main/resources/db/1.0.0.sql @@ -1,8 +1,7 @@ -- ---------------------------- -- Table structure for blade_module_version -- ---------------------------- -DROP TABLE IF EXISTS `blade_module_version`; -CREATE TABLE `blade_module_version` ( +CREATE TABLE IF NOT EXISTS `blade_module_version` ( `MODULE_NAME` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL, `VERSION` varchar(8) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL, `HISTORY` varchar(300) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL, @@ -12,8 +11,7 @@ CREATE TABLE `blade_module_version` ( -- ---------------------------- -- Table structure for hz_inspect_temp -- ---------------------------- -DROP TABLE IF EXISTS `hz_inspect_temp`; -CREATE TABLE `hz_inspect_temp` ( +CREATE TABLE IF NOT EXISTS `hz_inspect_temp` ( `id` int(11) NOT NULL, `temp_time` datetime NULL DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE @@ -22,8 +20,7 @@ CREATE TABLE `hz_inspect_temp` ( -- ---------------------------- -- Table structure for hz_offline_task -- ---------------------------- -DROP TABLE IF EXISTS `hz_offline_task`; -CREATE TABLE `hz_offline_task` ( +CREATE TABLE IF NOT EXISTS `hz_offline_task` ( `ID` bigint(20) NOT NULL COMMENT '主键', `TASK_NAME` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '任务名称', `TASK_STATUS` bigint(1) NULL DEFAULT NULL COMMENT '任务状态 0 - 任务开启 1 - 任务处理 2 - 任务完成 ', @@ -43,8 +40,7 @@ CREATE TABLE `hz_offline_task` ( -- ---------------------------- -- Table structure for hz_st_camera_info -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_camera_info`; -CREATE TABLE `hz_st_camera_info` ( +CREATE TABLE IF NOT EXISTS `hz_st_camera_info` ( `ID` bigint(20) NOT NULL COMMENT '主键ID', `TYPE` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '1' COMMENT '摄像头类型cameraType,1视频摄像头,2机器人摄像头,数据字典', `TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '租户ID', @@ -77,8 +73,7 @@ CREATE TABLE `hz_st_camera_info` ( -- ---------------------------- -- Table structure for hz_st_clock -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_clock`; -CREATE TABLE `hz_st_clock` ( +CREATE TABLE IF NOT EXISTS `hz_st_clock` ( `ID` bigint(20) NOT NULL COMMENT '主键ID', `TENANT_ID` varchar(12) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '租户ID', `CLOCK_TYPE_ID` bigint(20) NULL DEFAULT NULL COMMENT '表针类型ID', @@ -99,8 +94,7 @@ CREATE TABLE `hz_st_clock` ( -- ---------------------------- -- Table structure for hz_st_clock_type -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_clock_type`; -CREATE TABLE `hz_st_clock_type` ( +CREATE TABLE IF NOT EXISTS `hz_st_clock_type` ( `ID` bigint(20) NOT NULL COMMENT '主键ID', `TENANT_ID` varchar(12) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '租户ID', `CLOCK_NAME` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '表盘名称', @@ -123,8 +117,7 @@ CREATE TABLE `hz_st_clock_type` ( -- ---------------------------- -- Table structure for hz_st_event_attachment -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_event_attachment`; -CREATE TABLE `hz_st_event_attachment` ( +CREATE TABLE IF NOT EXISTS `hz_st_event_attachment` ( `ID` bigint(64) NOT NULL, `EVENT_ID` bigint(20) NOT NULL COMMENT '事件ID', `FILE_URL` varchar(250) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '文件路径', @@ -142,8 +135,7 @@ CREATE TABLE `hz_st_event_attachment` ( -- ---------------------------- -- Table structure for hz_st_ex_event -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_ex_event`; -CREATE TABLE `hz_st_ex_event` ( +CREATE TABLE IF NOT EXISTS `hz_st_ex_event` ( `ID` bigint(20) NOT NULL COMMENT 'ID', `TASK_ID` bigint(20) NULL DEFAULT NULL COMMENT '任务ID', `OBJECT_ID` bigint(20) NULL DEFAULT NULL COMMENT '对象ID', @@ -175,8 +167,7 @@ CREATE TABLE `hz_st_ex_event` ( -- ---------------------------- -- Table structure for hz_st_ex_event_record -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_ex_event_record`; -CREATE TABLE `hz_st_ex_event_record` ( +CREATE TABLE IF NOT EXISTS `hz_st_ex_event_record` ( `ID` bigint(64) NOT NULL, `EVENT_ID` bigint(20) NOT NULL COMMENT '事件ID', `OBJECT_ID` bigint(20) NOT NULL COMMENT '对象ID', @@ -212,8 +203,7 @@ CREATE TABLE `hz_st_ex_event_record` ( -- ---------------------------- -- Table structure for hz_st_ex_object -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_ex_object`; -CREATE TABLE `hz_st_ex_object` ( +CREATE TABLE IF NOT EXISTS `hz_st_ex_object` ( `ID` bigint(64) NOT NULL, `TASK_ID` bigint(20) NOT NULL COMMENT '任务ID', `OBJECT_ID` bigint(20) NOT NULL COMMENT '对象ID', @@ -238,8 +228,7 @@ CREATE TABLE `hz_st_ex_object` ( -- ---------------------------- -- Table structure for hz_st_ex_object_project -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_ex_object_project`; -CREATE TABLE `hz_st_ex_object_project` ( +CREATE TABLE IF NOT EXISTS `hz_st_ex_object_project` ( `ID` bigint(64) NOT NULL, `TASK_ID` bigint(64) NOT NULL COMMENT '任务ID', `OBJECT_ID` bigint(64) NOT NULL COMMENT '对象ID', @@ -262,8 +251,7 @@ CREATE TABLE `hz_st_ex_object_project` ( -- ---------------------------- -- Table structure for hz_st_ex_object_project_content -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_ex_object_project_content`; -CREATE TABLE `hz_st_ex_object_project_content` ( +CREATE TABLE IF NOT EXISTS `hz_st_ex_object_project_content` ( `ID` bigint(64) NOT NULL, `TASK_ID` bigint(20) NOT NULL COMMENT '任务ID', `OBJECT_ID` bigint(20) NOT NULL COMMENT '对象ID', @@ -299,8 +287,7 @@ CREATE TABLE `hz_st_ex_object_project_content` ( -- ---------------------------- -- Table structure for hz_st_ex_task -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_ex_task`; -CREATE TABLE `hz_st_ex_task` ( +CREATE TABLE IF NOT EXISTS `hz_st_ex_task` ( `ID` bigint(20) NOT NULL COMMENT 'ID', `PLAN_ID` bigint(20) NULL DEFAULT NULL COMMENT '计划ID', `TYPE` char(1) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '计划模式 0 人员 1岗位 2机构 3自由模式 4 自由人模式', @@ -339,8 +326,7 @@ CREATE TABLE `hz_st_ex_task` ( -- ---------------------------- -- Table structure for hz_st_ex_task_user -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_ex_task_user`; -CREATE TABLE `hz_st_ex_task_user` ( +CREATE TABLE IF NOT EXISTS `hz_st_ex_task_user` ( `ID` bigint(64) NOT NULL, `TASK_ID` bigint(20) NOT NULL COMMENT '任务ID', `USER_ID` bigint(20) NOT NULL COMMENT '用户ID', @@ -363,8 +349,7 @@ CREATE TABLE `hz_st_ex_task_user` ( -- ---------------------------- -- Table structure for hz_st_hi_task_gather -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_hi_task_gather`; -CREATE TABLE `hz_st_hi_task_gather` ( +CREATE TABLE IF NOT EXISTS `hz_st_hi_task_gather` ( `USER_ID` bigint(20) NULL DEFAULT NULL COMMENT '用户id', `USER_NAME` varchar(256) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '用户名称', `ROUTE_ID` bigint(20) NULL DEFAULT NULL COMMENT '路径id', @@ -402,8 +387,7 @@ CREATE TABLE `hz_st_hi_task_gather` ( -- ---------------------------- -- Table structure for hz_st_hi_task_result -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_hi_task_result`; -CREATE TABLE `hz_st_hi_task_result` ( +CREATE TABLE IF NOT EXISTS `hz_st_hi_task_result` ( `ID` bigint(20) NOT NULL COMMENT 'ID', `PLAN_ID` bigint(20) NULL DEFAULT NULL COMMENT '计划ID', `BATCH_NUMBER` varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '批次号', @@ -422,8 +406,7 @@ CREATE TABLE `hz_st_hi_task_result` ( -- ---------------------------- -- Table structure for hz_st_offline_record -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_offline_record`; -CREATE TABLE `hz_st_offline_record` ( +CREATE TABLE IF NOT EXISTS `hz_st_offline_record` ( `ID` bigint(20) NOT NULL COMMENT '主键ID', `USER_ID` bigint(20) NOT NULL COMMENT '用户ID', `TERMINAL_CODE` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '终端设备标识imei', @@ -441,8 +424,7 @@ CREATE TABLE `hz_st_offline_record` ( -- ---------------------------- -- Table structure for hz_st_re_content -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_content`; -CREATE TABLE `hz_st_re_content` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_content` ( `ID` bigint(64) NOT NULL COMMENT 'ID', `CODE` varchar(18) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '内容编码:由系统自动生成自动生成', `NAME` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '内容名称', @@ -482,8 +464,7 @@ CREATE TABLE `hz_st_re_content` ( -- ---------------------------- -- Table structure for hz_st_re_content_definition -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_content_definition`; -CREATE TABLE `hz_st_re_content_definition` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_content_definition` ( `ID` bigint(64) NOT NULL COMMENT 'ID', `CODE` varchar(18) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '内容编码:由系统自动生成自动生成', `NAME` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '内容名称', @@ -521,8 +502,7 @@ CREATE TABLE `hz_st_re_content_definition` ( -- ---------------------------- -- Table structure for hz_st_re_object -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_object`; -CREATE TABLE `hz_st_re_object` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_object` ( `ID` bigint(20) NOT NULL, `CODE` varchar(18) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '对象编码', `EM_CODE` varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '设备编码', @@ -551,8 +531,7 @@ CREATE TABLE `hz_st_re_object` ( -- ---------------------------- -- Table structure for hz_st_re_object_danger -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_object_danger`; -CREATE TABLE `hz_st_re_object_danger` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_object_danger` ( `ID` bigint(20) NOT NULL, `OBJECT_ID` bigint(20) NULL DEFAULT NULL COMMENT '巡检对象ID', `DANGER_ID` bigint(20) NULL DEFAULT NULL COMMENT '危险点ID', @@ -572,8 +551,7 @@ CREATE TABLE `hz_st_re_object_danger` ( -- ---------------------------- -- Table structure for hz_st_re_object_template -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_object_template`; -CREATE TABLE `hz_st_re_object_template` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_object_template` ( `ID` bigint(64) NOT NULL, `OBJECT_ID` bigint(20) NULL DEFAULT NULL COMMENT '对象ID', `TEMPLATE_ID` bigint(20) NULL DEFAULT NULL COMMENT '模板ID', @@ -590,8 +568,7 @@ CREATE TABLE `hz_st_re_object_template` ( -- ---------------------------- -- Table structure for hz_st_re_object_user -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_object_user`; -CREATE TABLE `hz_st_re_object_user` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_object_user` ( `ID` bigint(64) NOT NULL, `OBJECT_ID` bigint(64) NOT NULL COMMENT '对象ID', `USER_ID` bigint(64) NOT NULL COMMENT '用户ID', @@ -610,8 +587,7 @@ CREATE TABLE `hz_st_re_object_user` ( -- ---------------------------- -- Table structure for hz_st_re_plan -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_plan`; -CREATE TABLE `hz_st_re_plan` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_plan` ( `ID` bigint(64) NOT NULL COMMENT 'ID', `CODE` varchar(18) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '计划编码', `NAME` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '计划名称', @@ -650,8 +626,7 @@ CREATE TABLE `hz_st_re_plan` ( -- ---------------------------- -- Table structure for hz_st_re_plan_class -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_plan_class`; -CREATE TABLE `hz_st_re_plan_class` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_plan_class` ( `ID` bigint(20) NOT NULL, `PLAN_ID` bigint(20) NOT NULL COMMENT '计划ID', `CLASS_ID` bigint(20) NOT NULL COMMENT '班次ID', @@ -669,8 +644,7 @@ CREATE TABLE `hz_st_re_plan_class` ( -- ---------------------------- -- Table structure for hz_st_re_plan_object_template -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_plan_object_template`; -CREATE TABLE `hz_st_re_plan_object_template` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_plan_object_template` ( `ID` bigint(20) NOT NULL, `PLAN_ID` bigint(20) NOT NULL COMMENT '计划ID', `OBJECT_ID` bigint(20) NOT NULL COMMENT '对象ID', @@ -689,8 +663,7 @@ CREATE TABLE `hz_st_re_plan_object_template` ( -- ---------------------------- -- Table structure for hz_st_re_plan_org -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_plan_org`; -CREATE TABLE `hz_st_re_plan_org` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_plan_org` ( `ID` bigint(64) NOT NULL, `PLAN_ID` bigint(20) NOT NULL COMMENT '计划ID', `ORG_ID` bigint(20) NOT NULL COMMENT '机构ID', @@ -708,8 +681,7 @@ CREATE TABLE `hz_st_re_plan_org` ( -- ---------------------------- -- Table structure for hz_st_re_plan_position -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_plan_position`; -CREATE TABLE `hz_st_re_plan_position` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_plan_position` ( `ID` bigint(64) NOT NULL, `PLAN_ID` bigint(64) NOT NULL COMMENT '计划ID', `POSITION_ID` bigint(64) NOT NULL COMMENT '岗位ID', @@ -727,8 +699,7 @@ CREATE TABLE `hz_st_re_plan_position` ( -- ---------------------------- -- Table structure for hz_st_re_plan_user -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_plan_user`; -CREATE TABLE `hz_st_re_plan_user` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_plan_user` ( `ID` bigint(20) NOT NULL, `PLAN_ID` bigint(20) NOT NULL COMMENT '计划ID', `USER_ID` bigint(20) NOT NULL COMMENT '用户ID', @@ -746,8 +717,7 @@ CREATE TABLE `hz_st_re_plan_user` ( -- ---------------------------- -- Table structure for hz_st_re_project -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_project`; -CREATE TABLE `hz_st_re_project` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_project` ( `ID` bigint(64) NOT NULL COMMENT 'ID', `CODE` varchar(18) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '项目编码', `NAME` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '项目名称', @@ -770,8 +740,7 @@ CREATE TABLE `hz_st_re_project` ( -- ---------------------------- -- Table structure for hz_st_re_project_content -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_project_content`; -CREATE TABLE `hz_st_re_project_content` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_project_content` ( `ID` bigint(64) NOT NULL AUTO_INCREMENT, `PROJECT_ID` bigint(64) NOT NULL COMMENT '目标ID', `CONTENT_ID` bigint(64) NOT NULL COMMENT '内容ID', @@ -789,8 +758,7 @@ CREATE TABLE `hz_st_re_project_content` ( -- ---------------------------- -- Table structure for hz_st_re_route -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_route`; -CREATE TABLE `hz_st_re_route` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_route` ( `ID` bigint(20) NOT NULL, `TENANT_ID` varchar(12) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '租户ID', `ROUTE_NAME` varchar(500) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '路线名称', @@ -810,8 +778,7 @@ CREATE TABLE `hz_st_re_route` ( -- ---------------------------- -- Table structure for hz_st_re_route_gather -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_route_gather`; -CREATE TABLE `hz_st_re_route_gather` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_route_gather` ( `ID` bigint(20) NOT NULL, `TENANT_ID` varchar(12) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '租户ID', `ROUTE_NAME` varchar(500) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '路线名称', @@ -830,8 +797,7 @@ CREATE TABLE `hz_st_re_route_gather` ( -- ---------------------------- -- Table structure for hz_st_re_template -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_template`; -CREATE TABLE `hz_st_re_template` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_template` ( `ID` bigint(64) NOT NULL, `CODE` varchar(18) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '模板代码', `NAME` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '模板名称', @@ -854,8 +820,7 @@ CREATE TABLE `hz_st_re_template` ( -- ---------------------------- -- Table structure for hz_st_re_template_project -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_re_template_project`; -CREATE TABLE `hz_st_re_template_project` ( +CREATE TABLE IF NOT EXISTS `hz_st_re_template_project` ( `ID` bigint(64) NOT NULL, `TEMPLATE_ID` bigint(20) NOT NULL COMMENT '模板ID', `PROJECT_ID` bigint(20) NOT NULL COMMENT '项目ID', @@ -874,8 +839,7 @@ CREATE TABLE `hz_st_re_template_project` ( -- ---------------------------- -- Table structure for hz_st_robot -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_robot`; -CREATE TABLE `hz_st_robot` ( +CREATE TABLE IF NOT EXISTS `hz_st_robot` ( `ID` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `TENANT_ID` varchar(12) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '租户ID', `USER_ID` bigint(20) NULL DEFAULT NULL COMMENT '机器人用户ID', @@ -897,8 +861,7 @@ CREATE TABLE `hz_st_robot` ( -- ---------------------------- -- Table structure for hz_st_robot_task -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_robot_task`; -CREATE TABLE `hz_st_robot_task` ( +CREATE TABLE IF NOT EXISTS `hz_st_robot_task` ( `ID` bigint(20) NOT NULL COMMENT 'ID', `NAME` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '任务名称', `CHECK_TYPE_SON` varchar(256) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '任务类型 : 0图片,1识别,10热成像', @@ -922,8 +885,7 @@ CREATE TABLE `hz_st_robot_task` ( -- ---------------------------- -- Table structure for hz_st_robot_task_identify -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_robot_task_identify`; -CREATE TABLE `hz_st_robot_task_identify` ( +CREATE TABLE IF NOT EXISTS `hz_st_robot_task_identify` ( `ID` bigint(20) NOT NULL COMMENT 'ID', `ROBOT_TASK_ID` bigint(20) NOT NULL COMMENT '机器人任务ID', `IDENTIFY_KEY` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '识别类型:11表针识别,13灯识别,', @@ -943,8 +905,7 @@ CREATE TABLE `hz_st_robot_task_identify` ( -- ---------------------------- -- Table structure for hz_st_task_record -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_task_record`; -CREATE TABLE `hz_st_task_record` ( +CREATE TABLE IF NOT EXISTS `hz_st_task_record` ( `ID` bigint(64) NOT NULL, `TASK_ID` bigint(20) NULL DEFAULT NULL COMMENT '任务ID', `CREATE_TIME` datetime NULL DEFAULT NULL COMMENT '报备时间', @@ -965,8 +926,7 @@ CREATE TABLE `hz_st_task_record` ( -- ---------------------------- -- Table structure for hz_st_user_face_data -- ---------------------------- -DROP TABLE IF EXISTS `hz_st_user_face_data`; -CREATE TABLE `hz_st_user_face_data` ( +CREATE TABLE IF NOT EXISTS `hz_st_user_face_data` ( `ID` bigint(20) NOT NULL COMMENT '主键ID', `TENANT_ID` varchar(12) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '租户ID', `USER_ID` bigint(20) NOT NULL COMMENT '用户ID', @@ -985,7 +945,6 @@ CREATE TABLE `hz_st_user_face_data` ( -- ---------------------------- -- View structure for hz_st_other_object -- ---------------------------- -DROP VIEW IF EXISTS `hz_st_other_object`; CREATE ALGORITHM = UNDEFINED SQL SECURITY DEFINER VIEW `hz_st_other_object` AS select `equipment`.`hzims_em_info`.`TENANT_ID` AS `TENANT_ID`,`equipment`.`hzims_em_info`.`NUMBER` AS `CODE`,`equipment`.`hzims_em_info`.`NAME` AS `NAME`,`equipment`.`hzims_em_info`.`INS_LOCATION` AS `ADDRESS`,`equipment`.`hzims_em_info`.`LGTD` AS `LGTD`,`equipment`.`hzims_em_info`.`LTTD` AS `LTTD`,'hzims_em_info' AS `TABLE_CODE`,'设备' AS `TYPE`,`equipment`.`hzims_em_info`.`CREATE_USER` AS `CREATE_USER`,`equipment`.`hzims_em_info`.`CREATE_DEPT` AS `CREATE_DEPT`,`equipment`.`hzims_em_info`.`ID` AS `REAL_ID` from `equipment`.`hzims_em_info` where (`equipment`.`hzims_em_info`.`IS_DELETED` = 0); -- ---------------------------- @@ -1020,7 +979,6 @@ delimiter ; -- ---------------------------- -- Procedure structure for p_gn_demonstration_data -- ---------------------------- -DROP PROCEDURE IF EXISTS `p_gn_demonstration_data`; delimiter ;; CREATE PROCEDURE `p_gn_demonstration_data`(in initDate VARCHAR(20),in showDate VARCHAR(20)) COMMENT '广宁演示数据脚本' @@ -1051,7 +1009,6 @@ delimiter ; -- ---------------------------- -- Procedure structure for p_gn_demonstration_task -- ---------------------------- -DROP PROCEDURE IF EXISTS `p_gn_demonstration_task`; delimiter ;; CREATE PROCEDURE `p_gn_demonstration_task`(in oldPlanId BIGINT(20),in newPlanId BIGINT(20),in initDate VARCHAR(20),in showDate VARCHAR(20)) COMMENT '广宁制造巡检任务数据脚本'