Browse Source

update: sql脚本文件更新

zhongwei
liwen 7 months ago
parent
commit
f18cd82966
  1. 55
      hzims-service/assets/src/main/resources/db/1.0.0.sql
  2. 137
      hzims-service/equipment/src/main/resources/db/1.0.0.sql
  3. 7
      hzims-service/equipment/src/main/resources/db/2.0.0.sql
  4. 269
      hzims-service/hzims-alarm/src/main/resources/db/1.0.0.sql
  5. 250
      hzims-service/hzims-alarm/src/main/resources/db/1.0.0.sql.1
  6. 46
      hzims-service/hzims-alarm/src/main/resources/db/2.0.0.sql.1
  7. 12
      hzims-service/hzims-basic/src/main/resources/db/1.0.0.sql
  8. 25
      hzims-service/hzims-middle/src/main/resources/db/1.0.0.sql
  9. 2
      hzims-service/hzims-middle/src/main/resources/db/2.0.0.sql
  10. 1
      hzims-service/hzims-middle/src/main/resources/db/2.0.0.sql.1
  11. 69
      hzims-service/message/src/main/resources/db/1.0.0.sql
  12. 0
      hzims-service/message/src/main/resources/db/2.0.0.sql
  13. 42
      hzims-service/operational/src/main/resources/db/4.0.0 .sql.1
  14. 49
      hzims-service/operational/src/main/resources/db/5.0.0.sql
  15. 88
      hzims-service/safeproduct/src/main/resources/db/2.0.0.sql
  16. 4
      hzims-service/safeproduct/src/main/resources/db/3.0.0.sql.1
  17. 38
      hzims-service/ticket/src/main/resources/db/3.0.0.sql
  18. 30
      hzims-service/ticket/src/main/resources/db/3.0.0.sql.1

55
hzims-service/assets/src/main/resources/db/1.0.0.sql

@ -1,6 +1,4 @@
CREATE TABLE IF NOT EXISTS `BLADE_MODULE_VERSION` (
DROP TABLE IF EXISTS `BLADE_MODULE_VERSION`;
CREATE TABLE `BLADE_MODULE_VERSION` (
`MODULE_NAME` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL, `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, `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, `HISTORY` VARCHAR(300) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL,
@ -10,8 +8,7 @@ CREATE TABLE `BLADE_MODULE_VERSION` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_OPER_ACCESS_BASE_MATERIAL -- TABLE STRUCTURE FOR HZIMS_OPER_ACCESS_BASE_MATERIAL
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_OPER_ACCESS_BASE_MATERIAL`; CREATE TABLE IF NOT EXISTS `HZIMS_OPER_ACCESS_BASE_MATERIAL` (
CREATE TABLE `HZIMS_OPER_ACCESS_BASE_MATERIAL` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`NAME` VARCHAR(200) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '名称', `NAME` VARCHAR(200) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '名称',
`TYPE_CODE` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '类型', `TYPE_CODE` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '类型',
@ -32,8 +29,7 @@ CREATE TABLE `HZIMS_OPER_ACCESS_BASE_MATERIAL` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_ALLOCATION -- TABLE STRUCTURE FOR WT_SP_ALLOCATION
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_ALLOCATION`; CREATE TABLE IF NOT EXISTS `WT_SP_ALLOCATION` (
CREATE TABLE `WT_SP_ALLOCATION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -54,8 +50,7 @@ CREATE TABLE `WT_SP_ALLOCATION` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_BASIC -- TABLE STRUCTURE FOR WT_SP_BASIC
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_BASIC`; CREATE TABLE IF NOT EXISTS `WT_SP_BASIC` (
CREATE TABLE `WT_SP_BASIC` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -85,8 +80,7 @@ CREATE TABLE `WT_SP_BASIC` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_MANAGEMENT -- TABLE STRUCTURE FOR WT_SP_MANAGEMENT
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_MANAGEMENT`; CREATE TABLE IF NOT EXISTS `WT_SP_MANAGEMENT` (
CREATE TABLE `WT_SP_MANAGEMENT` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -110,8 +104,7 @@ CREATE TABLE `WT_SP_MANAGEMENT` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_PROVIDER -- TABLE STRUCTURE FOR WT_SP_PROVIDER
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_PROVIDER`; CREATE TABLE IF NOT EXISTS `WT_SP_PROVIDER` (
CREATE TABLE `WT_SP_PROVIDER` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -141,8 +134,7 @@ CREATE TABLE `WT_SP_PROVIDER` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_RECEIVE -- TABLE STRUCTURE FOR WT_SP_RECEIVE
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_RECEIVE`; CREATE TABLE IF NOT EXISTS `WT_SP_RECEIVE` (
CREATE TABLE `WT_SP_RECEIVE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -163,8 +155,7 @@ CREATE TABLE `WT_SP_RECEIVE` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_RECEIVES -- TABLE STRUCTURE FOR WT_SP_RECEIVES
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_RECEIVES`; CREATE TABLE IF NOT EXISTS `WT_SP_RECEIVES` (
CREATE TABLE `WT_SP_RECEIVES` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -186,8 +177,7 @@ CREATE TABLE `WT_SP_RECEIVES` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_RECORD -- TABLE STRUCTURE FOR WT_SP_RECORD
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_RECORD`; CREATE TABLE IF NOT EXISTS `WT_SP_RECORD` (
CREATE TABLE `WT_SP_RECORD` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`BUSINESS_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '业务表ID', `BUSINESS_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '业务表ID',
`AMOUNT` INT(11) NULL DEFAULT NULL COMMENT '数量AMOUNT', `AMOUNT` INT(11) NULL DEFAULT NULL COMMENT '数量AMOUNT',
@ -209,8 +199,7 @@ CREATE TABLE `WT_SP_RECORD` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_REVERT -- TABLE STRUCTURE FOR WT_SP_REVERT
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_REVERT`; CREATE TABLE IF NOT EXISTS `WT_SP_REVERT` (
CREATE TABLE `WT_SP_REVERT` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -234,8 +223,7 @@ CREATE TABLE `WT_SP_REVERT` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_TICKET_RELATION -- TABLE STRUCTURE FOR WT_SP_TICKET_RELATION
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_TICKET_RELATION`; CREATE TABLE IF NOT EXISTS `WT_SP_TICKET_RELATION` (
CREATE TABLE `WT_SP_TICKET_RELATION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`ORDER_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '出库单ID', `ORDER_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '出库单ID',
`AMOUNT` INT(11) NULL DEFAULT NULL COMMENT '数量', `AMOUNT` INT(11) NULL DEFAULT NULL COMMENT '数量',
@ -256,8 +244,7 @@ CREATE TABLE `WT_SP_TICKET_RELATION` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_TOOL_BASIC -- TABLE STRUCTURE FOR WT_SP_TOOL_BASIC
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_TOOL_BASIC`; CREATE TABLE IF NOT EXISTS `WT_SP_TOOL_BASIC` (
CREATE TABLE `WT_SP_TOOL_BASIC` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -279,8 +266,7 @@ CREATE TABLE `WT_SP_TOOL_BASIC` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_TOTAL -- TABLE STRUCTURE FOR WT_SP_TOTAL
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_TOTAL`; CREATE TABLE IF NOT EXISTS `WT_SP_TOTAL` (
CREATE TABLE `WT_SP_TOTAL` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -305,8 +291,7 @@ CREATE TABLE `WT_SP_TOTAL` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_TYPE_DICTIONARIES -- TABLE STRUCTURE FOR WT_SP_TYPE_DICTIONARIES
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_TYPE_DICTIONARIES`; CREATE TABLE IF NOT EXISTS `WT_SP_TYPE_DICTIONARIES` (
CREATE TABLE `WT_SP_TYPE_DICTIONARIES` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -325,8 +310,7 @@ CREATE TABLE `WT_SP_TYPE_DICTIONARIES` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_WAREHOUSE -- TABLE STRUCTURE FOR WT_SP_WAREHOUSE
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_WAREHOUSE`; CREATE TABLE IF NOT EXISTS `WT_SP_WAREHOUSE` (
CREATE TABLE `WT_SP_WAREHOUSE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -353,8 +337,7 @@ CREATE TABLE `WT_SP_WAREHOUSE` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_WAREHOUSE_IN -- TABLE STRUCTURE FOR WT_SP_WAREHOUSE_IN
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_WAREHOUSE_IN`; CREATE TABLE IF NOT EXISTS `WT_SP_WAREHOUSE_IN` (
CREATE TABLE `WT_SP_WAREHOUSE_IN` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -376,8 +359,7 @@ CREATE TABLE `WT_SP_WAREHOUSE_IN` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_WAREHOUSE_IN_RECORD -- TABLE STRUCTURE FOR WT_SP_WAREHOUSE_IN_RECORD
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_WAREHOUSE_IN_RECORD`; CREATE TABLE IF NOT EXISTS `WT_SP_WAREHOUSE_IN_RECORD` (
CREATE TABLE `WT_SP_WAREHOUSE_IN_RECORD` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',
@ -402,8 +384,7 @@ CREATE TABLE `WT_SP_WAREHOUSE_IN_RECORD` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR WT_SP_WAREHOUSE_OUT -- TABLE STRUCTURE FOR WT_SP_WAREHOUSE_OUT
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `WT_SP_WAREHOUSE_OUT`; CREATE TABLE IF NOT EXISTS `WT_SP_WAREHOUSE_OUT` (
CREATE TABLE `WT_SP_WAREHOUSE_OUT` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '部门ID',

137
hzims-service/equipment/src/main/resources/db/1.0.0.sql

@ -1,8 +1,7 @@
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR BLADE_MODULE_VERSION -- TABLE STRUCTURE FOR BLADE_MODULE_VERSION
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `BLADE_MODULE_VERSION`; CREATE TABLE IF NOT EXISTS `BLADE_MODULE_VERSION` (
CREATE TABLE `BLADE_MODULE_VERSION` (
`MODULE_NAME` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL, `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, `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, `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_IMS_PLAN_GENERATION -- TABLE STRUCTURE FOR HZ_IMS_PLAN_GENERATION
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZ_IMS_PLAN_GENERATION`; CREATE TABLE IF NOT EXISTS `HZ_IMS_PLAN_GENERATION` (
CREATE TABLE `HZ_IMS_PLAN_GENERATION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TENANT_ID` VARCHAR(30) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(30) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`STATION_ID` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '站点ID', `STATION_ID` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '站点ID',
@ -34,8 +32,7 @@ CREATE TABLE `HZ_IMS_PLAN_GENERATION` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_ASSOCIATION -- TABLE STRUCTURE FOR HZIMS_EM_ASSOCIATION
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_ASSOCIATION`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_ASSOCIATION` (
CREATE TABLE `HZIMS_EM_ASSOCIATION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`EM_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备ID', `EM_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备ID',
`FDP_EM_ID` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT 'FDP设备ID', `FDP_EM_ID` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT 'FDP设备ID',
@ -54,8 +51,7 @@ CREATE TABLE `HZIMS_EM_ASSOCIATION` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_ASSOCIATION_DETAIL -- TABLE STRUCTURE FOR HZIMS_EM_ASSOCIATION_DETAIL
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_ASSOCIATION_DETAIL`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_ASSOCIATION_DETAIL` (
CREATE TABLE `HZIMS_EM_ASSOCIATION_DETAIL` (
`PID` BIGINT(20) NOT NULL COMMENT '父ID', `PID` BIGINT(20) NOT NULL COMMENT '父ID',
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`EM_POINT_ID` BIGINT(20) NOT NULL COMMENT '设备点ID', `EM_POINT_ID` BIGINT(20) NOT NULL COMMENT '设备点ID',
@ -77,8 +73,7 @@ CREATE TABLE `HZIMS_EM_ASSOCIATION_DETAIL` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_ATTACH -- TABLE STRUCTURE FOR HZIMS_EM_ATTACH
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_ATTACH`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_ATTACH` (
CREATE TABLE `HZIMS_EM_ATTACH` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`EM_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备ID', `EM_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备ID',
@ -98,8 +93,7 @@ CREATE TABLE `HZIMS_EM_ATTACH` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_DEFINITION -- TABLE STRUCTURE FOR HZIMS_EM_DEFINITION
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_DEFINITION`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_DEFINITION` (
CREATE TABLE `HZIMS_EM_DEFINITION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`STATION_TYPE` VARCHAR(2) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '站点类型', `STATION_TYPE` VARCHAR(2) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '站点类型',
`TYPE` VARCHAR(2) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '类型', `TYPE` VARCHAR(2) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '类型',
@ -120,8 +114,7 @@ CREATE TABLE `HZIMS_EM_DEFINITION` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_INFO -- TABLE STRUCTURE FOR HZIMS_EM_INFO
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_INFO`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_INFO` (
CREATE TABLE `HZIMS_EM_INFO` (
`GPID` BIGINT(20) NOT NULL DEFAULT 0 COMMENT '父ID', `GPID` BIGINT(20) NOT NULL DEFAULT 0 COMMENT '父ID',
`REF_OREANIZATION` BIGINT(20) NULL DEFAULT NULL COMMENT '所属组织', `REF_OREANIZATION` BIGINT(20) NULL DEFAULT NULL COMMENT '所属组织',
`REF_MODEL_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '所属母版', `REF_MODEL_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '所属母版',
@ -175,8 +168,7 @@ CREATE TABLE `HZIMS_EM_INFO` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_LINKMAN -- TABLE STRUCTURE FOR HZIMS_EM_LINKMAN
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_LINKMAN`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_LINKMAN` (
CREATE TABLE `HZIMS_EM_LINKMAN` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`SOURCE_ID` CHAR(10) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '源ID', `SOURCE_ID` CHAR(10) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '源ID',
`NAME` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '名称', `NAME` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '名称',
@ -196,8 +188,7 @@ CREATE TABLE `HZIMS_EM_LINKMAN` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_MANUFACUTURER -- TABLE STRUCTURE FOR HZIMS_EM_MANUFACUTURER
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_MANUFACUTURER`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_MANUFACUTURER` (
CREATE TABLE `HZIMS_EM_MANUFACUTURER` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`NAME` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '名称', `NAME` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '名称',
`STAGE` BIGINT(20) NULL DEFAULT NULL COMMENT '等级', `STAGE` BIGINT(20) NULL DEFAULT NULL COMMENT '等级',
@ -218,8 +209,7 @@ CREATE TABLE `HZIMS_EM_MANUFACUTURER` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_MODEL -- TABLE STRUCTURE FOR HZIMS_EM_MODEL
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_MODEL`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_MODEL` (
CREATE TABLE `HZIMS_EM_MODEL` (
`GPID` BIGINT(20) NULL DEFAULT NULL COMMENT '父ID', `GPID` BIGINT(20) NULL DEFAULT NULL COMMENT '父ID',
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`MODEL_NAME` VARCHAR(200) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '母版名称(默认为设备模型名)', `MODEL_NAME` VARCHAR(200) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '母版名称(默认为设备模型名)',
@ -261,8 +251,7 @@ CREATE TABLE `HZIMS_EM_MODEL` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_MODEL_PARAM -- TABLE STRUCTURE FOR HZIMS_EM_MODEL_PARAM
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_MODEL_PARAM`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_MODEL_PARAM` (
CREATE TABLE `HZIMS_EM_MODEL_PARAM` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`MODEL_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备ID', `MODEL_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备ID',
`PARAM_NAME` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '参数名称', `PARAM_NAME` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '参数名称',
@ -284,8 +273,7 @@ CREATE TABLE `HZIMS_EM_MODEL_PARAM` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_OREANIZATION -- TABLE STRUCTURE FOR HZIMS_EM_OREANIZATION
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_OREANIZATION`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_OREANIZATION` (
CREATE TABLE `HZIMS_EM_OREANIZATION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`PID` BIGINT(20) NULL DEFAULT 0 COMMENT '父组织', `PID` BIGINT(20) NULL DEFAULT 0 COMMENT '父组织',
`NAME` VARCHAR(20) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '名称', `NAME` VARCHAR(20) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '名称',
@ -307,8 +295,7 @@ CREATE TABLE `HZIMS_EM_OREANIZATION` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_PARAM -- TABLE STRUCTURE FOR HZIMS_EM_PARAM
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_PARAM`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_PARAM` (
CREATE TABLE `HZIMS_EM_PARAM` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`INFO_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备ID', `INFO_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备ID',
`PARAM_NAME` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '参数名称', `PARAM_NAME` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '参数名称',
@ -331,8 +318,7 @@ CREATE TABLE `HZIMS_EM_PARAM` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_REAL_ID_ERROR -- TABLE STRUCTURE FOR HZIMS_EM_REAL_ID_ERROR
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_REAL_ID_ERROR`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_REAL_ID_ERROR` (
CREATE TABLE `HZIMS_EM_REAL_ID_ERROR` (
`ID` BIGINT(30) NOT NULL COMMENT '主键', `ID` BIGINT(30) NOT NULL COMMENT '主键',
`INSTANCE_ID` BIGINT(30) NULL DEFAULT NULL COMMENT '实例ID', `INSTANCE_ID` BIGINT(30) NULL DEFAULT NULL COMMENT '实例ID',
`INSTANCE_PRO_ID` BIGINT(30) NULL DEFAULT NULL COMMENT '实例属性ID', `INSTANCE_PRO_ID` BIGINT(30) NULL DEFAULT NULL COMMENT '实例属性ID',
@ -354,8 +340,7 @@ CREATE TABLE `HZIMS_EM_REAL_ID_ERROR` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_TREE -- TABLE STRUCTURE FOR HZIMS_EM_TREE
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_TREE`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_TREE` (
CREATE TABLE `HZIMS_EM_TREE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`DEFINITION_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备定义ID', `DEFINITION_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备定义ID',
`PID` BIGINT(20) NULL DEFAULT 0 COMMENT '父ID', `PID` BIGINT(20) NULL DEFAULT 0 COMMENT '父ID',
@ -383,8 +368,7 @@ CREATE TABLE `HZIMS_EM_TREE` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_TREE_BASIC -- TABLE STRUCTURE FOR HZIMS_EM_TREE_BASIC
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_TREE_BASIC`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_TREE_BASIC` (
CREATE TABLE `HZIMS_EM_TREE_BASIC` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`TREE_ID` BIGINT(20) NOT NULL DEFAULT 0 COMMENT '设备树ID', `TREE_ID` BIGINT(20) NOT NULL DEFAULT 0 COMMENT '设备树ID',
`BASIC_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '物资ID', `BASIC_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '物资ID',
@ -402,8 +386,7 @@ CREATE TABLE `HZIMS_EM_TREE_BASIC` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_TREE_INSPECT -- TABLE STRUCTURE FOR HZIMS_EM_TREE_INSPECT
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_TREE_INSPECT`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_TREE_INSPECT` (
CREATE TABLE `HZIMS_EM_TREE_INSPECT` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TREE_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备树ID', `TREE_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备树ID',
`CONTENT_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '巡检内容编号', `CONTENT_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '巡检内容编号',
@ -426,8 +409,7 @@ CREATE TABLE `HZIMS_EM_TREE_INSPECT` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_EM_TREE_PARAM -- TABLE STRUCTURE FOR HZIMS_EM_TREE_PARAM
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_EM_TREE_PARAM`; CREATE TABLE IF NOT EXISTS `HZIMS_EM_TREE_PARAM` (
CREATE TABLE `HZIMS_EM_TREE_PARAM` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`TREE_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备树ID', `TREE_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '设备树ID',
`PARAM_NAME` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '参数标识', `PARAM_NAME` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '参数标识',
@ -449,8 +431,7 @@ CREATE TABLE `HZIMS_EM_TREE_PARAM` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_FDP_DEVICE -- TABLE STRUCTURE FOR HZIMS_FDP_DEVICE
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_FDP_DEVICE`; CREATE TABLE IF NOT EXISTS `HZIMS_FDP_DEVICE` (
CREATE TABLE `HZIMS_FDP_DEVICE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`FDP_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '设备ID', `FDP_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '设备ID',
`FATHER_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '智能诊断-父ID', `FATHER_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '智能诊断-父ID',
@ -472,8 +453,7 @@ CREATE TABLE `HZIMS_FDP_DEVICE` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_FDP_FAULT -- TABLE STRUCTURE FOR HZIMS_FDP_FAULT
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_FDP_FAULT`; CREATE TABLE IF NOT EXISTS `HZIMS_FDP_FAULT` (
CREATE TABLE `HZIMS_FDP_FAULT` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`FDP_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT 'FDP故障ID', `FDP_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT 'FDP故障ID',
`FDP_PARTITION` BIGINT(20) NULL DEFAULT NULL COMMENT '分区号', `FDP_PARTITION` BIGINT(20) NULL DEFAULT NULL COMMENT '分区号',
@ -503,8 +483,7 @@ CREATE TABLE `HZIMS_FDP_FAULT` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_FDP_FAULT0908 -- TABLE STRUCTURE FOR HZIMS_FDP_FAULT0908
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_FDP_FAULT0908`; CREATE TABLE IF NOT EXISTS `HZIMS_FDP_FAULT0908` (
CREATE TABLE `HZIMS_FDP_FAULT0908` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`FDP_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT 'FDP故障ID', `FDP_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT 'FDP故障ID',
`FDP_PARTITION` BIGINT(20) NULL DEFAULT NULL COMMENT '分区号', `FDP_PARTITION` BIGINT(20) NULL DEFAULT NULL COMMENT '分区号',
@ -534,8 +513,7 @@ CREATE TABLE `HZIMS_FDP_FAULT0908` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_FDP_FAULT_INFO -- TABLE STRUCTURE FOR HZIMS_FDP_FAULT_INFO
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_FDP_FAULT_INFO`; CREATE TABLE IF NOT EXISTS `HZIMS_FDP_FAULT_INFO` (
CREATE TABLE `HZIMS_FDP_FAULT_INFO` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TASK_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '任务ID', `TASK_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '任务ID',
`FAULT_ID` VARCHAR(200) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '故障ID', `FAULT_ID` VARCHAR(200) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '故障ID',
@ -554,8 +532,7 @@ CREATE TABLE `HZIMS_FDP_FAULT_INFO` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_FDP_MONITOR -- TABLE STRUCTURE FOR HZIMS_FDP_MONITOR
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_FDP_MONITOR`; CREATE TABLE IF NOT EXISTS `HZIMS_FDP_MONITOR` (
CREATE TABLE `HZIMS_FDP_MONITOR` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`FDP_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '监测点ID', `FDP_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '监测点ID',
`FDP_PARTITION` BIGINT(20) NULL DEFAULT NULL COMMENT '分区号', `FDP_PARTITION` BIGINT(20) NULL DEFAULT NULL COMMENT '分区号',
@ -590,8 +567,7 @@ CREATE TABLE `HZIMS_FDP_MONITOR` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_FDP_TASK -- TABLE STRUCTURE FOR HZIMS_FDP_TASK
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_FDP_TASK`; CREATE TABLE IF NOT EXISTS `HZIMS_FDP_TASK` (
CREATE TABLE `HZIMS_FDP_TASK` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TYPE` VARCHAR(4) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '1:手动创建;2:自动创建', `TYPE` VARCHAR(4) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '1:手动创建;2:自动创建',
`NAME` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '任务名称', `NAME` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '任务名称',
@ -623,8 +599,7 @@ CREATE TABLE `HZIMS_FDP_TASK` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_PARAM_BACKUPS -- TABLE STRUCTURE FOR HZIMS_PARAM_BACKUPS
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_PARAM_BACKUPS`; CREATE TABLE IF NOT EXISTS `HZIMS_PARAM_BACKUPS` (
CREATE TABLE `HZIMS_PARAM_BACKUPS` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`NAME` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL, `NAME` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL,
`STATION_CODE` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL, `STATION_CODE` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL,
@ -645,8 +620,7 @@ CREATE TABLE `HZIMS_PARAM_BACKUPS` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_PARAM_BACKUPS_DETAIL -- TABLE STRUCTURE FOR HZIMS_PARAM_BACKUPS_DETAIL
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_PARAM_BACKUPS_DETAIL`; CREATE TABLE IF NOT EXISTS `HZIMS_PARAM_BACKUPS_DETAIL` (
CREATE TABLE `HZIMS_PARAM_BACKUPS_DETAIL` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`BACKUPS_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '备份主表ID', `BACKUPS_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '备份主表ID',
`NAME` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '参数名称', `NAME` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '参数名称',
@ -674,8 +648,7 @@ CREATE TABLE `HZIMS_PARAM_BACKUPS_DETAIL` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_WORKSHOP_EQUIPMENT -- TABLE STRUCTURE FOR HZIMS_WORKSHOP_EQUIPMENT
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_WORKSHOP_EQUIPMENT`; CREATE TABLE IF NOT EXISTS `HZIMS_WORKSHOP_EQUIPMENT` (
CREATE TABLE `HZIMS_WORKSHOP_EQUIPMENT` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`WORKSHOP_ID` BIGINT(20) NOT NULL COMMENT '厂房ID', `WORKSHOP_ID` BIGINT(20) NOT NULL COMMENT '厂房ID',
`WORKSHOP_NAME` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '厂房名称', `WORKSHOP_NAME` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '厂房名称',
@ -695,8 +668,7 @@ CREATE TABLE `HZIMS_WORKSHOP_EQUIPMENT` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_WORKSHOP_INFO -- TABLE STRUCTURE FOR HZIMS_WORKSHOP_INFO
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_WORKSHOP_INFO`; CREATE TABLE IF NOT EXISTS `HZIMS_WORKSHOP_INFO` (
CREATE TABLE `HZIMS_WORKSHOP_INFO` (
`GPID` BIGINT(20) NOT NULL DEFAULT 0 COMMENT '父ID', `GPID` BIGINT(20) NOT NULL DEFAULT 0 COMMENT '父ID',
`REF_OREANIZATION` BIGINT(20) NULL DEFAULT NULL COMMENT '所属组织', `REF_OREANIZATION` BIGINT(20) NULL DEFAULT NULL COMMENT '所属组织',
`REF_MODEL_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '所属母版', `REF_MODEL_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '所属母版',
@ -768,55 +740,4 @@ BEGIN
END END
;; ;;
DELIMITER ; DELIMITER ;
alter table hzims_em_param add COLUMN NAME VARCHAR(100) comment '参数名称';
-- HZ100C参数下发 设备表添加参数最后下发时间字段
alter table `hzims_em_info` add column `LAST_DISTRIBUTE_TIME` DATETIME DEFAULT NULL COMMENT '最后下发时间';
-- HZ100C参数下发 设备表添加字段机组类别
alter table `hzims_em_info` add column `SET_CATEGORY` VARCHAR(2) DEFAULT NULL COMMENT '机组类别';
CREATE TABLE `hzims_param_backups` (
`ID` bigint(20) NOT NULL,
`NAME` varchar(255) DEFAULT NULL,
`STATION_CODE` varchar(64) DEFAULT NULL,
`EM_CODE` varchar(64) DEFAULT NULL,
`DELAY` tinyint(1) DEFAULT NULL,
`MACHINE_CODE` varchar(255) DEFAULT NULL,
`TENANT_ID` varchar(12) DEFAULT NULL COMMENT '租户ID',
`CREATE_TIME` datetime NOT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NOT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT '0' COMMENT '是否删除',
`STATUS` tinyint(4) DEFAULT NULL COMMENT '状态 ',
`CREATE_DEPT` bigint(20) DEFAULT NULL COMMENT '创建部门',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC;
CREATE TABLE `hzims_param_backups_detail` (
`ID` bigint(20) NOT NULL,
`BACKUPS_ID` bigint(20) DEFAULT NULL COMMENT '备份主表ID',
`NAME` varchar(255) DEFAULT NULL COMMENT '参数名称',
`SIGNAGE` varchar(128) DEFAULT NULL COMMENT '标识',
`FAC_DEVICE_ID` varchar(64) DEFAULT NULL COMMENT '关联设备',
`FAC_DEVICE_FUNC_ID` varchar(64) DEFAULT NULL COMMENT 'hz3000关联id',
`PARAMETER_TAG` varchar(128) DEFAULT NULL COMMENT '参数标识',
`PARAMETER_NAME` varchar(255) DEFAULT NULL COMMENT '参数名称',
`VALUE` varchar(16) DEFAULT NULL COMMENT '',
`MAX_VALUE` varchar(16) DEFAULT NULL COMMENT '最大值',
`MIN_VALUE` varchar(16) DEFAULT NULL COMMENT '最小值',
`TENANT_ID` varchar(12) DEFAULT NULL COMMENT '租户ID',
`CREATE_TIME` datetime NOT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NOT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT '0' COMMENT '是否删除',
`STATUS` tinyint(4) DEFAULT NULL COMMENT '状态 ',
`CREATE_DEPT` bigint(20) DEFAULT NULL COMMENT '创建部门',
PRIMARY KEY (`ID`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
alter table `HZIMS_PARAM_BACKUPS_DETAIL` add COLUMN `KEEP_FIGURES` INT(11) COMMENT '小数点位数';
alter table `HZIMS_PARAM_BACKUPS_DETAIL` add COLUMN `DESCS` VARCHAR(255) COMMENT '描述';

7
hzims-service/equipment/src/main/resources/db/2.0.0.sql.1 → hzims-service/equipment/src/main/resources/db/2.0.0.sql

@ -1,5 +1,5 @@
-- 设备视频绑定关系表 -- 设备视频绑定关系表
CREATE TABLE `hzims_em_video_banding` ( CREATE TABLE IF NOT EXISTS `hzims_em_video_banding` (
`ID` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`EM_CODE` varchar(50) NOT NULL COMMENT '设备编号', `EM_CODE` varchar(50) NOT NULL COMMENT '设备编号',
`EM_NAME` varchar(80) NOT NULL COMMENT '设备名称', `EM_NAME` varchar(80) NOT NULL COMMENT '设备名称',
@ -29,10 +29,7 @@ alter table `HZIMS_PARAM_BACKUPS` add column `em_name` varchar(100) COMMENT '设
update HZIMS_PARAM_BACKUPS pb,HZIMS_EM_INFO ei set pb.EM_NAME = ei.`NAME` WHERE pb.EM_CODE = ei.NUMBER; update HZIMS_PARAM_BACKUPS pb,HZIMS_EM_INFO ei set pb.EM_NAME = ei.`NAME` WHERE pb.EM_CODE = ei.NUMBER;
update bladex.blade_dict set dict_key = '2' where id = 1675699613977288706; update bladex.blade_dict set dict_key = '2' where id = 1675699613977288706;
update equipment.hzims_em_definition set type = '2' where type = '0'; update hzims_em_definition set type = '2' where type = '0';
update bladex.blade_dict set dict_key = '2' where id = 1675699613977288706;
update equipment.hzims_em_definition set type = '2' where type = '0';
-- 修改故障诊断任务表的字符集 -- 修改故障诊断任务表的字符集
ALTER TABLE hzims_fdp_task CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci; ALTER TABLE hzims_fdp_task CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;

269
hzims-service/hzims-alarm/src/main/resources/db/1.0.0.sql

@ -0,0 +1,269 @@
CREATE TABLE IF NOT EXISTS `blade_module_version` (
`MODULE_NAME` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
`VERSION` varchar(8) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
`HISTORY` varchar(300) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL,
PRIMARY KEY (`MODULE_NAME`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic;
-- ----------------------------
-- Table structure for hzims_alarm
-- ----------------------------
CREATE TABLE IF NOT EXISTS `hzims_alarm` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`STATION_ID` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '站点编码',
`STATION_NAME` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '站点名称',
`DEVICE_CODE` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '设备编码',
`DEVICE_NAME` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '设备名称',
`ALARM_ID` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警ID',
`ALARM_SOURCE` tinyint(4) NULL DEFAULT NULL COMMENT '告警类型 :0- HZ3000告警 1 -等级告警 2 -条件告警 3-FDP智能预警',
`ALARM_TYPE` tinyint(4) NULL DEFAULT NULL COMMENT '告警子类',
`ALARM_SIGNAGE` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警属性标识',
`ALARM_CONTEXT` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警内容',
`ALARM_STATUS` tinyint(4) NULL DEFAULT NULL COMMENT '告警状态',
`ALARM_LEVEL` tinyint(4) NULL DEFAULT NULL COMMENT '告警等级',
`ALARM_VALUE` varchar(2048) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警动作数值',
`ALARM_COUNT` tinyint(10) NULL DEFAULT NULL COMMENT '告警数量',
`ALARM_TIME` datetime NULL DEFAULT NULL COMMENT '告警时间',
`DIAG_REASON` varchar(2048) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '初步分析原因',
`DIAG_SOLUTION` varchar(2048) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '建议处置方式',
`REAL_ID` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '监测点',
`IS_RIGHT_TABULATION` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控右侧列表展示 : 0-展示 1-不展示',
`IS_SHOW_ALERT` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控弹窗展示 : 0-展示 1-不展示',
`IS_SMALL_BELL` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控铃铛展示 : 0-展示 1-不展示',
`IS_MASK` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控遮罩展示 : 0-展示 1-不展示',
`IS_BROADCAST` tinyint(4) NULL DEFAULT NULL COMMENT '是否语音播报 : 0-播报 1-不播报',
`IS_PLATFORM_MESSAGE` tinyint(4) NULL DEFAULT NULL COMMENT '是否进行平台消息推送 : 0-推送 1-不推送',
`IS_SHORT_MESSAGE` tinyint(4) NULL DEFAULT NULL COMMENT '是否短信推送 :0-推送 1-不推送',
`IS_WX_MESSAGE` tinyint(4) NULL DEFAULT NULL COMMENT '是否微信公众号消息推送 :0-推送 1-不推送',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '租户ID',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` datetime NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` tinyint(4) NULL DEFAULT NULL COMMENT '状态',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Table structure for hzims_alarm_config
-- ----------------------------
CREATE TABLE IF NOT EXISTS `hzims_alarm_config` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`STATION_ID` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '站点编码',
`STATION_NAME` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '站点名称',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '租户ID',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` datetime NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` tinyint(4) NULL DEFAULT NULL COMMENT '状态(0 待值班 1 值班中 2 已完成)',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Table structure for hzims_alarm_config_detail
-- ----------------------------
CREATE TABLE IF NOT EXISTS `hzims_alarm_config_detail` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`STRATEGY_ID` bigint(20) NULL DEFAULT NULL COMMENT '告警配置ID',
`ALARM_TYPE` bigint(4) NULL DEFAULT NULL COMMENT '告警类型',
`ALARM_CHILED_TYPE` bigint(4) NULL DEFAULT NULL COMMENT '告警子类',
`ALARM_CONTEXT` varchar(2048) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警内容',
`ALARM_POINT` varchar(2048) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警监测点',
`IS_RIGHT_TABULATION` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控右侧列表展示 : 0-展示 1-不展示',
`IS_SHOW_ALERT` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控弹窗展示 : 0-展示 1-不展示',
`IS_SMALL_BELL` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控铃铛展示 : 0-展示 1-不展示',
`IS_MASK` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控遮罩展示 : 0-展示 1-不展示',
`IS_BROADCAST` tinyint(4) NULL DEFAULT NULL COMMENT '是否语音播报 : 0-播报 1-不播报',
`IS_PLATFORM_MESSAGE` tinyint(4) NULL DEFAULT NULL COMMENT '是否进行平台消息推送 : 0-推送 1-不推送',
`IS_SHORT_MESSAGE` tinyint(4) NULL DEFAULT NULL COMMENT '是否短信推送 :0-推送 1-不推送',
`IS_WX_MESSAGE` tinyint(4) NULL DEFAULT NULL COMMENT '是否微信公众号消息推送 :0-推送 1-不推送',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '租户ID',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` datetime NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` tinyint(4) NULL DEFAULT NULL COMMENT '状态(0 待值班 1 值班中 2 已完成)',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Table structure for hzims_alarm_defaul_config
-- ----------------------------
CREATE TABLE IF NOT EXISTS `hzims_alarm_defaul_config` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`SOURCE` bigint(4) NULL DEFAULT NULL COMMENT '告警来源',
`ALARM_CHILED_TYPE` bigint(4) NULL DEFAULT NULL COMMENT '告警子类',
`IS_RIGHT_TABULATION` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控右侧列表展示 : 0-展示 1-不展示',
`IS_SHOW_ALERT` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控弹窗展示 : 0-展示 1-不展示',
`IS_SMALL_BELL` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控铃铛展示 : 0-展示 1-不展示',
`IS_MASK` tinyint(4) NULL DEFAULT NULL COMMENT '是否集中监控遮罩展示 : 0-展示 1-不展示',
`IS_BROADCAST` tinyint(4) NULL DEFAULT NULL COMMENT '是否语音播报 : 0-播报 1-不播报',
`IS_PLATFORM_MESSAGE` tinyint(4) NULL DEFAULT NULL COMMENT '是否进行平台消息推送 : 0-推送 1-不推送',
`IS_SHORT_MESSAGE` tinyint(4) NULL DEFAULT NULL COMMENT '是否短信推送 :0-推送 1-不推送',
`IS_WX_MESSAGE` tinyint(4) NULL DEFAULT NULL COMMENT '是否微信公众号消息推送 :0-推送 1-不推送',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '租户ID',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` datetime NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` tinyint(4) NULL DEFAULT NULL COMMENT '状态',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Table structure for hzims_alarm_handle
-- ----------------------------
CREATE TABLE IF NOT EXISTS `hzims_alarm_handle` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`ALARM_ID` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警主键ID',
`STATION_CODE` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '站点编号',
`ALARM_TYPE` smallint(6) NULL DEFAULT NULL COMMENT '告警类型',
`ALARM_TIME` datetime NULL DEFAULT NULL COMMENT '告警时间',
`ALARM_CONTENT` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警内容',
`TYPE` tinyint(1) NULL DEFAULT NULL COMMENT '类型:0-系统告警 1-智能告警',
`HANDLE_WAY` smallint(6) NULL DEFAULT NULL COMMENT '处理方式',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_TIME` datetime NOT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NOT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL COMMENT '是否删除',
`STATUS` tinyint(4) NOT NULL DEFAULT 0 COMMENT '状态',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建部门',
`HANDLE_USER` bigint(20) NULL DEFAULT NULL COMMENT '通知处理人',
`PHENOMENON_ID` bigint(20) NULL DEFAULT NULL COMMENT '现象ID',
`ACCESS_ID` bigint(20) NULL DEFAULT NULL COMMENT '检修ID',
`DELAY_TIME` datetime NULL DEFAULT NULL COMMENT '延后时间',
`DELAY_CAUSE` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '延后原因',
`FALSE_ALARM_DESC` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '误报描述',
`FILE_PATH` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '附件路径',
`CREATE_USER_NAME` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建用户姓名',
`CREATE_DEPT_NAME` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建机构名称',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Table structure for hzims_alarm_handle_flow
-- ----------------------------
CREATE TABLE IF NOT EXISTS `hzims_alarm_handle_flow` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`ALARM_ID` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警主键ID',
`STATION_CODE` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '站点编号',
`ALARM_TYPE` smallint(6) NULL DEFAULT NULL COMMENT '告警类型',
`ALARM_TIME` datetime NULL DEFAULT NULL COMMENT '告警时间',
`ALARM_CONTENT` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警内容',
`TYPE` tinyint(1) NULL DEFAULT NULL COMMENT '类型:0-系统告警 1-智能告警',
`HANDLE_WAY` smallint(6) NULL DEFAULT NULL COMMENT '告警状态 1L,2L,3L,4L,5L 误报 、延后、缺陷 、检修、处理',
`HANDLE_USER` bigint(20) NULL DEFAULT NULL COMMENT '通知处理人',
`PHENOMENON_ID` bigint(20) NULL DEFAULT NULL COMMENT '现象ID',
`ACCESS_ID` bigint(20) NULL DEFAULT NULL COMMENT '检修ID',
`DELAY_TIME` datetime NULL DEFAULT NULL COMMENT '延后时间',
`DELAY_CAUSE` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '延后原因',
`FALSE_ALARM_DESC` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '误报描述',
`FILE_PATH` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '附件路径',
`DEAL_TYPE` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '处理方式',
`DEAL_RESULT` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '处理结果',
`DEAL_DESC` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '处理描述',
`DEAL_PATH` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '处理附件',
`CHECK_FLAG` tinyint(4) NULL DEFAULT NULL COMMENT '审批结果 0,不通过;1为通过',
`CHECK_DESC` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '审批说明',
`CURRENT_OPERATOR` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '当前处理环节',
`CURRENT_LINK_HANDLER` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '当前环节处理人',
`PROCESS_INSTANCE_ID` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '流程实例',
`CREATE_USER_NAME` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建用户姓名',
`HANDLE_USER_NAME` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '处理人姓名',
`APPROVAL_USER` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '审批人',
`APPROVAL_USER_NAME` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '审批人姓名',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_TIME` datetime NOT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NOT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` tinyint(4) NOT NULL DEFAULT 0 COMMENT '状态',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建部门',
`CREATE_DEPT_NAME` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建机构名称',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Table structure for hzims_alarm_history
-- ----------------------------
CREATE TABLE IF NOT EXISTS `hzims_alarm_history` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`STATION_ID` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '站点编码',
`STATION_NAME` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '站点名称',
`DEVICE_CODE` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '设备编码',
`DEVICE_NAME` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '设备名称',
`ALARM_ID` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警ID',
`ALARM_SOURCE` tinyint(4) NULL DEFAULT NULL COMMENT '告警类型 :0- HZ3000告警 1 -等级告警 2 -条件告警 3-FDP智能预警',
`ALARM_TYPE` tinyint(4) NULL DEFAULT NULL COMMENT '告警子类',
`ALARM_SIGNAGE` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警属性标识',
`ALARM_CONTEXT` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警内容',
`ALARM_STATUS` tinyint(4) NULL DEFAULT NULL COMMENT '告警状态',
`ALARM_LEVEL` tinyint(4) NULL DEFAULT NULL COMMENT '告警等级',
`ALARM_VALUE` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警动作数值',
`ALARM_COUNT` tinyint(10) NULL DEFAULT NULL COMMENT '告警数量',
`ALARM_TIME` datetime NULL DEFAULT NULL COMMENT '告警时间',
`REAL_ID` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '监测点',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '租户ID',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` datetime NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` tinyint(4) NULL DEFAULT NULL COMMENT '状态(0 待值班 1 值班中 2 已完成)',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Table structure for hzims_business_early
-- ----------------------------
CREATE TABLE IF NOT EXISTS `hzims_business_early` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`TASK_ID` bigint(20) NULL DEFAULT NULL COMMENT '任务ID',
`BUSINESS_TYPE` tinyint(1) NULL DEFAULT NULL COMMENT '业务类型 :0 - 固定资产 1 - 日常维护 2 - 安全工器- 具 3 - 巡检 4 - 检修 5 - 缺陷 6 - 值班',
`CONTENT` varchar(1024) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '预警内容',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '租户ID',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` datetime NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` tinyint(4) NULL DEFAULT NULL COMMENT '状态',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Table structure for hzims_interruption_alarm
-- ----------------------------
CREATE TABLE IF NOT EXISTS `hzims_interruption_alarm` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`STATION_ID` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '站点ID',
`STATION_NAME` varchar(168) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '站点名称',
`ALARM_ID` bigint(20) NULL DEFAULT NULL COMMENT '告警编号',
`REAL_ID` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警点位',
`ALARM_TIME` datetime NULL DEFAULT NULL COMMENT '告警时间',
`TYPE` varchar(16) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警类型 13-连接中断 14-数据异常',
`SOE_EXPLAIN` varchar(500) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警原因',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '租户ID',
`STATUS` bigint(1) NULL DEFAULT NULL COMMENT '状态',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建单位',
`CREATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '创建人',
`CREATE_TIME` datetime NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '修改人',
`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;

250
hzims-service/hzims-alarm/src/main/resources/db/1.0.0.sql.1

@ -1,250 +0,0 @@
DROP TABLE IF EXISTS `BLADE_MODULE_VERSION`;
CREATE TABLE `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,
PRIMARY KEY (`MODULE_NAME`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_ALARM
-- ----------------------------
DROP TABLE IF EXISTS `HZIMS_ALARM`;
CREATE TABLE `HZIMS_ALARM` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`STATION_ID` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '站点编码',
`STATION_NAME` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '站点名称',
`DEVICE_CODE` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '设备编码',
`DEVICE_NAME` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '设备名称',
`ALARM_ID` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警ID',
`ALARM_SOURCE` TINYINT(4) NULL DEFAULT NULL COMMENT '告警类型 :0- HZ3000告警 1 -等级告警 2 -条件告警 3-FDP智能预警',
`ALARM_TYPE` TINYINT(4) NULL DEFAULT NULL COMMENT '告警子类',
`ALARM_SIGNAGE` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警属性标识',
`ALARM_CONTEXT` VARCHAR(1024) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警内容',
`ALARM_STATUS` TINYINT(4) NULL DEFAULT NULL COMMENT '告警状态',
`ALARM_LEVEL` TINYINT(4) NULL DEFAULT NULL COMMENT '告警等级',
`ALARM_VALUE` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警动作数值',
`ALARM_COUNT` TINYINT(10) NULL DEFAULT NULL COMMENT '告警数量',
`ALARM_TIME` DATETIME NULL DEFAULT NULL COMMENT '告警时间',
`DIAG_REASON` VARCHAR(2048) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '初步分析原因',
`DIAG_SOLUTION` VARCHAR(2048) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '建议处置方式',
`REAL_ID` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '监测点',
`IS_RIGHT_TABULATION` TINYINT(4) NULL DEFAULT NULL COMMENT '是否集中监控右侧列表展示 : 0-展示 1-不展示',
`IS_SHOW_ALERT` TINYINT(4) NULL DEFAULT NULL COMMENT '是否集中监控弹窗展示 : 0-展示 1-不展示',
`IS_SMALL_BELL` TINYINT(4) NULL DEFAULT NULL COMMENT '是否集中监控铃铛展示 : 0-展示 1-不展示',
`IS_MASK` TINYINT(4) NULL DEFAULT NULL COMMENT '是否集中监控遮罩展示 : 0-展示 1-不展示',
`IS_BROADCAST` TINYINT(4) NULL DEFAULT NULL COMMENT '是否语音播报 : 0-播报 1-不播报',
`IS_PLATFORM_MESSAGE` TINYINT(4) NULL DEFAULT NULL COMMENT '是否进行平台消息推送 : 0-推送 1-不推送',
`IS_SHORT_MESSAGE` TINYINT(4) NULL DEFAULT NULL COMMENT '是否短信推送 :0-推送 1-不推送',
`IS_WX_MESSAGE` TINYINT(4) NULL DEFAULT NULL COMMENT '是否微信公众号消息推送 :0-推送 1-不推送',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` TINYINT(4) NULL DEFAULT NULL COMMENT '状态',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_ALARM_CONFIG
-- ----------------------------
DROP TABLE IF EXISTS `HZIMS_ALARM_CONFIG`;
CREATE TABLE `HZIMS_ALARM_CONFIG` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`STATION_ID` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '站点编码',
`STATION_NAME` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '站点名称',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` TINYINT(4) NULL DEFAULT NULL COMMENT '状态(0 待值班 1 值班中 2 已完成)',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_ALARM_CONFIG_DETAIL
-- ----------------------------
DROP TABLE IF EXISTS `HZIMS_ALARM_CONFIG_DETAIL`;
CREATE TABLE `HZIMS_ALARM_CONFIG_DETAIL` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`STRATEGY_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '告警配置ID',
`ALARM_TYPE` BIGINT(4) NULL DEFAULT NULL COMMENT '告警类型',
`ALARM_CHILED_TYPE` BIGINT(4) NULL DEFAULT NULL COMMENT '告警子类',
`ALARM_CONTEXT` VARCHAR(2048) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警内容',
`ALARM_POINT` VARCHAR(2048) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警监测点',
`IS_RIGHT_TABULATION` TINYINT(4) NULL DEFAULT NULL COMMENT '是否集中监控右侧列表展示 : 0-展示 1-不展示',
`IS_SHOW_ALERT` TINYINT(4) NULL DEFAULT NULL COMMENT '是否集中监控弹窗展示 : 0-展示 1-不展示',
`IS_SMALL_BELL` TINYINT(4) NULL DEFAULT NULL COMMENT '是否集中监控铃铛展示 : 0-展示 1-不展示',
`IS_MASK` TINYINT(4) NULL DEFAULT NULL COMMENT '是否集中监控遮罩展示 : 0-展示 1-不展示',
`IS_BROADCAST` TINYINT(4) NULL DEFAULT NULL COMMENT '是否语音播报 : 0-播报 1-不播报',
`IS_PLATFORM_MESSAGE` TINYINT(4) NULL DEFAULT NULL COMMENT '是否进行平台消息推送 : 0-推送 1-不推送',
`IS_SHORT_MESSAGE` TINYINT(4) NULL DEFAULT NULL COMMENT '是否短信推送 :0-推送 1-不推送',
`IS_WX_MESSAGE` TINYINT(4) NULL DEFAULT NULL COMMENT '是否微信公众号消息推送 :0-推送 1-不推送',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` TINYINT(4) NULL DEFAULT NULL COMMENT '状态(0 待值班 1 值班中 2 已完成)',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_ALARM_HANDLE
-- ----------------------------
DROP TABLE IF EXISTS `HZIMS_ALARM_HANDLE`;
CREATE TABLE `HZIMS_ALARM_HANDLE` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`ALARM_ID` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警主键ID',
`STATION_CODE` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '站点编号',
`ALARM_TYPE` smallint(6) NULL DEFAULT NULL COMMENT '告警类型',
`ALARM_TIME` datetime(0) NULL DEFAULT NULL COMMENT '告警时间',
`ALARM_CONTENT` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警内容',
`TYPE` tinyint(1) NULL DEFAULT NULL COMMENT '类型:0-系统告警 1-智能告警',
`HANDLE_WAY` smallint(6) NULL DEFAULT NULL COMMENT '处理方式',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_TIME` datetime(0) NOT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime(0) NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NOT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL COMMENT '是否删除',
`STATUS` tinyint(4) NOT NULL DEFAULT 0 COMMENT '状态',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建部门',
`HANDLE_USER` bigint(20) NULL DEFAULT NULL COMMENT '通知处理人',
`PHENOMENON_ID` bigint(20) NULL DEFAULT NULL COMMENT '现象ID',
`ACCESS_ID` bigint(20) NULL DEFAULT NULL COMMENT '检修ID',
`DELAY_TIME` datetime(0) NULL DEFAULT NULL COMMENT '延后时间',
`DELAY_CAUSE` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '延后原因',
`FALSE_ALARM_DESC` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '误报描述',
`FILE_PATH` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '附件路径',
`CREATE_USER_NAME` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建用户姓名',
`CREATE_DEPT_NAME` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建机构名称',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_ALARM_HISTORY
-- ----------------------------
DROP TABLE IF EXISTS `HZIMS_ALARM_HISTORY`;
CREATE TABLE `HZIMS_ALARM_HISTORY` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`STATION_ID` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '站点编码',
`STATION_NAME` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '站点名称',
`DEVICE_CODE` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '设备编码',
`DEVICE_NAME` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '设备名称',
`ALARM_ID` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警ID',
`ALARM_SOURCE` TINYINT(4) NULL DEFAULT NULL COMMENT '告警类型 :0- HZ3000告警 1 -等级告警 2 -条件告警 3-FDP智能预警',
`ALARM_TYPE` TINYINT(4) NULL DEFAULT NULL COMMENT '告警子类',
`ALARM_SIGNAGE` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警属性标识',
`ALARM_CONTEXT` VARCHAR(1024) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警内容',
`ALARM_STATUS` TINYINT(4) NULL DEFAULT NULL COMMENT '告警状态',
`ALARM_LEVEL` TINYINT(4) NULL DEFAULT NULL COMMENT '告警等级',
`ALARM_VALUE` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警动作数值',
`ALARM_COUNT` TINYINT(10) NULL DEFAULT NULL COMMENT '告警数量',
`ALARM_TIME` DATETIME NULL DEFAULT NULL COMMENT '告警时间',
`REAL_ID` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '监测点',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` TINYINT(4) NULL DEFAULT NULL COMMENT '状态(0 待值班 1 值班中 2 已完成)',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_BUSINESS_EARLY
-- ----------------------------
DROP TABLE IF EXISTS `HZIMS_BUSINESS_EARLY`;
CREATE TABLE `HZIMS_BUSINESS_EARLY` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TASK_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '任务ID',
`BUSINESS_TYPE` TINYINT(1) NULL DEFAULT NULL COMMENT '业务类型 :0 - 固定资产 1 - 日常维护 2 - 安全工器- 具 3 - 巡检 4 - 检修 5 - 缺陷 6 - 值班',
`CONTENT` VARCHAR(1024) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '预警内容',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '租户ID',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` TINYINT(4) NULL DEFAULT NULL COMMENT '状态',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8MB4 COLLATE = UTF8MB4_GENERAL_CI ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_INTERRUPTION_ALARM
-- ----------------------------
DROP TABLE IF EXISTS `HZIMS_INTERRUPTION_ALARM`;
CREATE TABLE `HZIMS_INTERRUPTION_ALARM` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`STATION_ID` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '站点ID',
`STATION_NAME` VARCHAR(168) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '站点名称',
`ALARM_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '告警编号',
`REAL_ID` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警点位',
`ALARM_TIME` DATETIME NULL DEFAULT NULL COMMENT '告警时间',
`TYPE` VARCHAR(16) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警类型 13-连接中断 14-数据异常',
`SOE_EXPLAIN` VARCHAR(500) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '告警原因',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`STATUS` BIGINT(1) NULL DEFAULT NULL COMMENT '状态',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '创建单位',
`CREATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '创建人',
`CREATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '创建时间',
`UPDATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '修改人',
`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;
DROP TABLE IF EXISTS `hzims_alarm_handle_flow`;
CREATE TABLE `hzims_alarm_handle_flow` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`ALARM_ID` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警主键ID',
`STATION_CODE` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '站点编号',
`ALARM_TYPE` smallint(6) NULL DEFAULT NULL COMMENT '告警类型',
`ALARM_TIME` datetime(0) NULL DEFAULT NULL COMMENT '告警时间',
`ALARM_CONTENT` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '告警内容',
`TYPE` tinyint(1) NULL DEFAULT NULL COMMENT '类型:0-系统告警 1-智能告警',
`HANDLE_WAY` smallint(6) NULL DEFAULT NULL COMMENT '告警状态 1L,2L,3L,4L,5L 误报 、延后、缺陷 、检修、处理',
`HANDLE_USER` bigint(20) NULL DEFAULT NULL COMMENT '通知处理人',
`PHENOMENON_ID` bigint(20) NULL DEFAULT NULL COMMENT '现象ID',
`ACCESS_ID` bigint(20) NULL DEFAULT NULL COMMENT '检修ID',
`DELAY_TIME` datetime(0) NULL DEFAULT NULL COMMENT '延后时间',
`DELAY_CAUSE` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '延后原因',
`FALSE_ALARM_DESC` varchar(1024) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '误报描述',
`FILE_PATH` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '附件路径',
`DEAL_TYPE` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '处理方式',
`DEAL_RESULT` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '处理结果',
`DEAL_DESC` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '处理描述',
`DEAL_PATH` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '处理附件',
`CHECK_FLAG` tinyint(4) NULL DEFAULT NULL COMMENT '审批结果 0,不通过;1为通过',
`CHECK_DESC` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '审批说明',
`CURRENT_OPERATOR` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '当前处理环节',
`CURRENT_LINK_HANDLER` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '当前环节处理人',
`PROCESS_INSTANCE_ID` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '流程实例',
`CREATE_USER_NAME` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建用户姓名',
`HANDLE_USER_NAME` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '处理人姓名',
`APPROVAL_USER` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '审批人',
`APPROVAL_USER_NAME` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '审批人姓名',
`TENANT_ID` varchar(12) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '租户ID',
`CREATE_TIME` datetime(0) NOT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime(0) NULL DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) NOT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) NULL DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`STATUS` tinyint(4) NOT NULL DEFAULT 0 COMMENT '状态',
`CREATE_DEPT` bigint(20) NULL DEFAULT NULL COMMENT '创建部门',
`CREATE_DEPT_NAME` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建机构名称',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC;

46
hzims-service/hzims-alarm/src/main/resources/db/2.0.0.sql.1

@ -1,46 +0,0 @@
DROP TABLE IF EXISTS `BLADE_MODULE_VERSION`;
CREATE TABLE `hzims_alarm_defaul_config` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`SOURCE` bigint(4) DEFAULT NULL COMMENT '告警来源',
`ALARM_CHILED_TYPE` bigint(4) DEFAULT NULL COMMENT '告警子类',
`IS_RIGHT_TABULATION` tinyint(4) DEFAULT NULL COMMENT '是否集中监控右侧列表展示 : 0-展示 1-不展示',
`IS_SHOW_ALERT` tinyint(4) DEFAULT NULL COMMENT '是否集中监控弹窗展示 : 0-展示 1-不展示',
`IS_SMALL_BELL` tinyint(4) DEFAULT NULL COMMENT '是否集中监控铃铛展示 : 0-展示 1-不展示',
`IS_MASK` tinyint(4) DEFAULT NULL COMMENT '是否集中监控遮罩展示 : 0-展示 1-不展示',
`IS_BROADCAST` tinyint(4) DEFAULT NULL COMMENT '是否语音播报 : 0-播报 1-不播报',
`IS_PLATFORM_MESSAGE` tinyint(4) DEFAULT NULL COMMENT '是否进行平台消息推送 : 0-推送 1-不推送',
`IS_SHORT_MESSAGE` tinyint(4) DEFAULT NULL COMMENT '是否短信推送 :0-推送 1-不推送',
`IS_WX_MESSAGE` tinyint(4) DEFAULT NULL COMMENT '是否微信公众号消息推送 :0-推送 1-不推送',
`TENANT_ID` varchar(12) NOT NULL COMMENT '租户ID',
`CREATE_DEPT` bigint(20) DEFAULT NULL COMMENT '创建部门ID',
`CREATE_TIME` datetime DEFAULT NULL COMMENT '创建时间',
`UPDATE_TIME` datetime DEFAULT NULL COMMENT '更新时间',
`CREATE_USER` bigint(20) DEFAULT NULL COMMENT '创建人',
`UPDATE_USER` bigint(20) DEFAULT NULL COMMENT '更新人',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT '0' COMMENT '是否删除',
`STATUS` tinyint(4) DEFAULT NULL COMMENT '状态',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC;
DROP TABLE IF EXISTS `hzims_run_month_report`;
CREATE TABLE `hzims_run_month_report` (
`ID` bigint(20) NOT NULL COMMENT '主键ID',
`STATION_CODE` varchar(64) DEFAULT NULL COMMENT '站点编码',
`STATION_NAME` varchar(255) DEFAULT NULL COMMENT '站点名称',
`MONTH` varchar(255) DEFAULT NULL COMMENT '月份 : "yyyy-MM"',
`RUN_DATA` text COMMENT '运行数据',
`ALARM_DATA` text COMMENT '告警数据',
`CURVE_DATA` text COMMENT '曲线数据',
`ANALYSIS_DATA` text COMMENT '分析数据',
`RUN_PROPOSE` text COMMENT '运行建议',
`TENANT_ID` varchar(12) DEFAULT NULL COMMENT '租户ID',
`STATUS` tinyint(4) DEFAULT NULL COMMENT '业务状态',
`CREATE_DEPT` bigint(20) DEFAULT NULL COMMENT '创建单位',
`IS_DELETED` tinyint(4) NOT NULL DEFAULT '0',
`CREATE_USER` bigint(20) DEFAULT NULL COMMENT '创建人',
`CREATE_TIME` datetime DEFAULT NULL COMMENT '创建时间',
`UPDATE_USER` bigint(20) DEFAULT NULL COMMENT '修改人',
`UPDATE_TIME` datetime DEFAULT NULL COMMENT '修改时间',
PRIMARY KEY (`ID`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

12
hzims-service/hzims-basic/src/main/resources/db/1.0.0.sql

@ -1,5 +1,4 @@
DROP TABLE IF EXISTS `BLADE_MODULE_VERSION`; CREATE TABLE IF NOT EXISTS `BLADE_MODULE_VERSION` (
CREATE TABLE `BLADE_MODULE_VERSION` (
`MODULE_NAME` VARCHAR(64) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NOT NULL, `MODULE_NAME` VARCHAR(64) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NOT NULL,
`VERSION` VARCHAR(8) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NOT NULL, `VERSION` VARCHAR(8) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NOT NULL,
`HISTORY` VARCHAR(300) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL, `HISTORY` VARCHAR(300) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL,
@ -9,8 +8,7 @@ CREATE TABLE `BLADE_MODULE_VERSION` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_CERTIFICATET -- TABLE STRUCTURE FOR HZIMS_CERTIFICATET
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_CERTIFICATET`; CREATE TABLE IF NOT EXISTS `HZIMS_CERTIFICATET` (
CREATE TABLE `HZIMS_CERTIFICATET` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`PERSON_ID` BIGINT(20) NOT NULL COMMENT '用户管理表ID', `PERSON_ID` BIGINT(20) NOT NULL COMMENT '用户管理表ID',
`TYPE` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '证件类型', `TYPE` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '证件类型',
@ -31,8 +29,7 @@ CREATE TABLE `HZIMS_CERTIFICATET` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_CERTIFICATET_NOTICE -- TABLE STRUCTURE FOR HZIMS_CERTIFICATET_NOTICE
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_CERTIFICATET_NOTICE`; CREATE TABLE IF NOT EXISTS `HZIMS_CERTIFICATET_NOTICE` (
CREATE TABLE `HZIMS_CERTIFICATET_NOTICE` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT, `ID` BIGINT(20) NOT NULL AUTO_INCREMENT,
`SEND_TYPE` TINYINT(4) NULL DEFAULT NULL COMMENT '通知类型 1=短信 2=系统通知', `SEND_TYPE` TINYINT(4) NULL DEFAULT NULL COMMENT '通知类型 1=短信 2=系统通知',
`SAFE_TIME` INT(11) NOT NULL COMMENT '提前几天通知', `SAFE_TIME` INT(11) NOT NULL COMMENT '提前几天通知',
@ -51,8 +48,7 @@ CREATE TABLE `HZIMS_CERTIFICATET_NOTICE` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_PERSON_MANAGEMET -- TABLE STRUCTURE FOR HZIMS_PERSON_MANAGEMET
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_PERSON_MANAGEMET`; CREATE TABLE IF NOT EXISTS `HZIMS_PERSON_MANAGEMET` (
CREATE TABLE `HZIMS_PERSON_MANAGEMET` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`USER_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '用户ID', `USER_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '用户ID',
`NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '用户姓名', `NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '用户姓名',

25
hzims-service/hzims-middle/src/main/resources/db/1.0.0.sql

@ -1,9 +1,7 @@
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR BLADE_MODULE_VERSION -- TABLE STRUCTURE FOR BLADE_MODULE_VERSION
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `BLADE_MODULE_VERSION`; CREATE TABLE IF NOT EXISTS `BLADE_MODULE_VERSION` (
CREATE TABLE `BLADE_MODULE_VERSION` (
`MODULE_NAME` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL, `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, `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, `HISTORY` VARCHAR(300) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL,
@ -13,8 +11,7 @@ CREATE TABLE `BLADE_MODULE_VERSION` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_PROCESS_TYPE -- TABLE STRUCTURE FOR HZIMS_PROCESS_TYPE
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_PROCESS_TYPE`; CREATE TABLE IF NOT EXISTS `HZIMS_PROCESS_TYPE` (
CREATE TABLE `HZIMS_PROCESS_TYPE` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT, `ID` BIGINT(20) NOT NULL AUTO_INCREMENT,
`SEQUENCE` INT(11) NOT NULL COMMENT '序号', `SEQUENCE` INT(11) NOT NULL COMMENT '序号',
`DEPLOYMENT_ID` VARCHAR(160) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '当前环节流程KEY', `DEPLOYMENT_ID` VARCHAR(160) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '当前环节流程KEY',
@ -29,8 +26,7 @@ CREATE TABLE `HZIMS_PROCESS_TYPE` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_STATISTICS -- TABLE STRUCTURE FOR HZIMS_STATISTICS
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_STATISTICS`; CREATE TABLE IF NOT EXISTS `HZIMS_STATISTICS` (
CREATE TABLE `HZIMS_STATISTICS` (
`ID` BIGINT(20) NOT NULL COMMENT '编号', `ID` BIGINT(20) NOT NULL COMMENT '编号',
`MODULE_NAME` VARCHAR(150) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '功能模块', `MODULE_NAME` VARCHAR(150) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '功能模块',
`MODULE_NAME_NUM` INT(11) NULL DEFAULT 0 COMMENT '功能模块统计', `MODULE_NAME_NUM` INT(11) NULL DEFAULT 0 COMMENT '功能模块统计',
@ -44,8 +40,7 @@ CREATE TABLE `HZIMS_STATISTICS` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_SYS_LOG -- TABLE STRUCTURE FOR HZIMS_SYS_LOG
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_SYS_LOG`; CREATE TABLE IF NOT EXISTS `HZIMS_SYS_LOG` (
CREATE TABLE `HZIMS_SYS_LOG` (
`ID` BIGINT(20) NOT NULL COMMENT '操作日志编号', `ID` BIGINT(20) NOT NULL COMMENT '操作日志编号',
`TENANT_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`SERVER_IP` VARCHAR(60) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '服务器IP', `SERVER_IP` VARCHAR(60) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '服务器IP',
@ -83,8 +78,7 @@ CREATE TABLE `HZIMS_SYS_LOG` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_WORKFLOW_OPERATION_LOG -- TABLE STRUCTURE FOR HZIMS_WORKFLOW_OPERATION_LOG
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_WORKFLOW_OPERATION_LOG`; CREATE TABLE IF NOT EXISTS `HZIMS_WORKFLOW_OPERATION_LOG` (
CREATE TABLE `HZIMS_WORKFLOW_OPERATION_LOG` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT, `ID` BIGINT(20) NOT NULL AUTO_INCREMENT,
`TAKE_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '当前任务ID', `TAKE_ID` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '当前任务ID',
`TAKE_NAME` VARCHAR(150) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '当前任务名称', `TAKE_NAME` VARCHAR(150) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '当前任务名称',
@ -104,8 +98,7 @@ CREATE TABLE `HZIMS_WORKFLOW_OPERATION_LOG` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR LOG_OPTIONS_MODULE_NAME -- TABLE STRUCTURE FOR LOG_OPTIONS_MODULE_NAME
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `LOG_OPTIONS_MODULE_NAME`; CREATE TABLE IF NOT EXISTS `LOG_OPTIONS_MODULE_NAME` (
CREATE TABLE `LOG_OPTIONS_MODULE_NAME` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT, `ID` BIGINT(20) NOT NULL AUTO_INCREMENT,
`MODULE_NAME` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '功能模块', `MODULE_NAME` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '功能模块',
`SORT` INT(11) NULL DEFAULT NULL COMMENT '排序', `SORT` INT(11) NULL DEFAULT NULL COMMENT '排序',
@ -118,8 +111,7 @@ CREATE TABLE `LOG_OPTIONS_MODULE_NAME` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR PROCESS_DICT -- TABLE STRUCTURE FOR PROCESS_DICT
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `PROCESS_DICT`; CREATE TABLE IF NOT EXISTS `PROCESS_DICT` (
CREATE TABLE `PROCESS_DICT` (
`DICT_CODE` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '票据编码', `DICT_CODE` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '票据编码',
`DICT_SORT` INT(4) NULL DEFAULT 0 COMMENT '票据排序', `DICT_SORT` INT(4) NULL DEFAULT 0 COMMENT '票据排序',
`DICT_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT '' COMMENT '票据字典码', `DICT_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT '' COMMENT '票据字典码',
@ -152,7 +144,8 @@ INSERT INTO `PROCESS_DICT` (`DICT_CODE`, `DICT_SORT`, `DICT_KEY`, `DICT_VALUE`,
alter table hzims_workflow_operation_log add is_operation_log tinyint(1) comment '1 正常日志 0 错误日志'; alter table hzims_workflow_operation_log add is_operation_log tinyint(1) comment '1 正常日志 0 错误日志';
alter table hzims_statistics add sort int comment '排序'; alter table hzims_statistics add sort int comment '排序';
create table log_options_module_name
create table IF NOT EXISTS log_options_module_name
( (
id bigint primary key auto_increment, id bigint primary key auto_increment,
module_name varchar(50) null comment '功能模块', module_name varchar(50) null comment '功能模块',

2
hzims-service/hzims-middle/src/main/resources/db/4.0.0.sql.1 → hzims-service/hzims-middle/src/main/resources/db/2.0.0.sql

@ -1,3 +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 (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 (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 (11, 11, 'DEALALARM', 'DEALALARM', '告警处理流程', '告警处理流程', 'Y', 0, NULL, '2024-02-19 16:56:10', '2024-02-19 16:56:34', '告警处理流程');

1
hzims-service/hzims-middle/src/main/resources/db/2.0.0.sql.1

@ -1 +0,0 @@
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', '线下工作票流程');

69
hzims-service/message/src/main/resources/db/1.0.0.sql

@ -1,8 +1,7 @@
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR BLADE_MODULE_VERSION -- TABLE STRUCTURE FOR BLADE_MODULE_VERSION
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `BLADE_MODULE_VERSION`; CREATE TABLE IF NOT EXISTS `BLADE_MODULE_VERSION` (
CREATE TABLE `BLADE_MODULE_VERSION` (
`MODULE_NAME` VARCHAR(64) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL, `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, `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, `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_MSG_PUSH_RECORD -- TABLE STRUCTURE FOR HZ_MSG_PUSH_RECORD
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZ_MSG_PUSH_RECORD`; CREATE TABLE IF NOT EXISTS `HZ_MSG_PUSH_RECORD` (
CREATE TABLE `HZ_MSG_PUSH_RECORD` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '业务模块', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '业务模块',
`BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '业务关键字', `BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '业务关键字',
@ -41,8 +39,7 @@ CREATE TABLE `HZ_MSG_PUSH_RECORD` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZ_MSG_PUSH_RECORD_COPY1 -- TABLE STRUCTURE FOR HZ_MSG_PUSH_RECORD_COPY1
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZ_MSG_PUSH_RECORD_COPY1`; CREATE TABLE IF NOT EXISTS `HZ_MSG_PUSH_RECORD_COPY1` (
CREATE TABLE `HZ_MSG_PUSH_RECORD_COPY1` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`TAGS` VARCHAR(200) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL DEFAULT '' COMMENT '标签集合,多个标签用逗号隔开', `TAGS` VARCHAR(200) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL DEFAULT '' COMMENT '标签集合,多个标签用逗号隔开',
`IS_ALL` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否推送所有 0=否 1=是', `IS_ALL` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否推送所有 0=否 1=是',
@ -66,8 +63,7 @@ CREATE TABLE `HZ_MSG_PUSH_RECORD_COPY1` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZ_MSG_SMS_RECORD -- TABLE STRUCTURE FOR HZ_MSG_SMS_RECORD
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZ_MSG_SMS_RECORD`; CREATE TABLE IF NOT EXISTS `HZ_MSG_SMS_RECORD` (
CREATE TABLE `HZ_MSG_SMS_RECORD` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '业务模块', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '业务模块',
`BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '业务关键字', `BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '业务关键字',
@ -96,8 +92,7 @@ CREATE TABLE `HZ_MSG_SMS_RECORD` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZ_MSG_SMS_RECORD_COPY1 -- TABLE STRUCTURE FOR HZ_MSG_SMS_RECORD_COPY1
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZ_MSG_SMS_RECORD_COPY1`; CREATE TABLE IF NOT EXISTS `HZ_MSG_SMS_RECORD_COPY1` (
CREATE TABLE `HZ_MSG_SMS_RECORD_COPY1` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`SMS_CODE` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '平台资源模块提供的CODE', `SMS_CODE` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '平台资源模块提供的CODE',
`PHONES` VARCHAR(200) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '手机号码', `PHONES` VARCHAR(200) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '手机号码',
@ -118,13 +113,12 @@ CREATE TABLE `HZ_MSG_SMS_RECORD_COPY1` (
INDEX `IDX_PHONE`(`PHONES`) USING BTREE INDEX `IDX_PHONE`(`PHONES`) USING BTREE
) ENGINE = INNODB AUTO_INCREMENT = 1471810757107675139 CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI COMMENT = '短信推送日志' ROW_FORMAT = DYNAMIC; ) ENGINE = INNODB AUTO_INCREMENT = 1471810757107675139 CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI COMMENT = '短信推送日志' ROW_FORMAT = DYNAMIC;
ALTER TABLE `hzims_message`.`hzims_app_log` MODIFY COLUMN `TYPE` tinyint(4) NULL DEFAULT NULL COMMENT '消息类型' AFTER `BUSINESS_CLASSIFY`; ALTER TABLE `hzims_app_log` MODIFY COLUMN `TYPE` tinyint(4) NULL DEFAULT NULL COMMENT '消息类型' AFTER `BUSINESS_CLASSIFY`;
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZ_MSG_WS_RECORD_COPY1 -- TABLE STRUCTURE FOR HZ_MSG_WS_RECORD_COPY1
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZ_MSG_WS_RECORD_COPY1`; CREATE TABLE IF NOT EXISTS `HZ_MSG_WS_RECORD_COPY1` (
CREATE TABLE `HZ_MSG_WS_RECORD_COPY1` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`USER_ID` BIGINT(20) NOT NULL COMMENT '推送目标账户ID', `USER_ID` BIGINT(20) NOT NULL COMMENT '推送目标账户ID',
`CLASSIFY` VARCHAR(30) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类', `CLASSIFY` VARCHAR(30) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类',
@ -147,8 +141,7 @@ CREATE TABLE `HZ_MSG_WS_RECORD_COPY1` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZ_MSG_WS_RECORD_HISTORY -- TABLE STRUCTURE FOR HZ_MSG_WS_RECORD_HISTORY
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZ_MSG_WS_RECORD_HISTORY`; CREATE TABLE IF NOT EXISTS `HZ_MSG_WS_RECORD_HISTORY` (
CREATE TABLE `HZ_MSG_WS_RECORD_HISTORY` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`USER_ID` BIGINT(20) NOT NULL COMMENT '推送目标账户ID', `USER_ID` BIGINT(20) NOT NULL COMMENT '推送目标账户ID',
`CLASSIFY` VARCHAR(30) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类', `CLASSIFY` VARCHAR(30) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类',
@ -171,8 +164,7 @@ CREATE TABLE `HZ_MSG_WS_RECORD_HISTORY` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_APP_LOG -- TABLE STRUCTURE FOR HZIMS_APP_LOG
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_APP_LOG`; CREATE TABLE IF NOT EXISTS `HZIMS_APP_LOG` (
CREATE TABLE `HZIMS_APP_LOG` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字',
`BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT', `BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT',
@ -200,8 +192,7 @@ CREATE TABLE `HZIMS_APP_LOG` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_MAIL_CONFIG -- TABLE STRUCTURE FOR HZIMS_MAIL_CONFIG
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_MAIL_CONFIG`; CREATE TABLE IF NOT EXISTS `HZIMS_MAIL_CONFIG` (
CREATE TABLE `HZIMS_MAIL_CONFIG` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字',
`BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT', `BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT',
@ -230,8 +221,7 @@ CREATE TABLE `HZIMS_MAIL_CONFIG` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_MAIL_LOG -- TABLE STRUCTURE FOR HZIMS_MAIL_LOG
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_MAIL_LOG`; CREATE TABLE IF NOT EXISTS `HZIMS_MAIL_LOG` (
CREATE TABLE `HZIMS_MAIL_LOG` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字',
`BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT', `BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT',
@ -258,8 +248,7 @@ CREATE TABLE `HZIMS_MAIL_LOG` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_MESSAGE_PUSH_RECORD -- TABLE STRUCTURE FOR HZIMS_MESSAGE_PUSH_RECORD
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_MESSAGE_PUSH_RECORD`; CREATE TABLE IF NOT EXISTS `HZIMS_MESSAGE_PUSH_RECORD` (
CREATE TABLE `HZIMS_MESSAGE_PUSH_RECORD` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`TASK_ID` BIGINT(20) NOT NULL COMMENT '消息类型', `TASK_ID` BIGINT(20) NOT NULL COMMENT '消息类型',
`TEMPLATE_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '消息模板ID', `TEMPLATE_ID` BIGINT(20) NULL DEFAULT NULL COMMENT '消息模板ID',
@ -299,8 +288,7 @@ CREATE TABLE `HZIMS_MESSAGE_PUSH_RECORD` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_MESSAGE_TEMPLATE -- TABLE STRUCTURE FOR HZIMS_MESSAGE_TEMPLATE
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_MESSAGE_TEMPLATE`; CREATE TABLE IF NOT EXISTS `HZIMS_MESSAGE_TEMPLATE` (
CREATE TABLE `HZIMS_MESSAGE_TEMPLATE` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '消息类型', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '消息类型',
`TYPE` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '主键ID', `TYPE` VARCHAR(50) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '主键ID',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字',
@ -324,8 +312,7 @@ CREATE TABLE `HZIMS_MESSAGE_TEMPLATE` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_MSG_MAIL_RECORD -- TABLE STRUCTURE FOR HZIMS_MSG_MAIL_RECORD
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_MSG_MAIL_RECORD`; CREATE TABLE IF NOT EXISTS `HZIMS_MSG_MAIL_RECORD` (
CREATE TABLE `HZIMS_MSG_MAIL_RECORD` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL DEFAULT '' COMMENT '业务关键字', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL DEFAULT '' COMMENT '业务关键字',
`BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL DEFAULT '' COMMENT '业务分类', `BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL DEFAULT '' COMMENT '业务分类',
@ -350,8 +337,7 @@ CREATE TABLE `HZIMS_MSG_MAIL_RECORD` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_PUSH_CONFIG -- TABLE STRUCTURE FOR HZIMS_PUSH_CONFIG
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_PUSH_CONFIG`; CREATE TABLE IF NOT EXISTS `HZIMS_PUSH_CONFIG` (
CREATE TABLE `HZIMS_PUSH_CONFIG` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字',
`BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT', `BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT',
@ -377,8 +363,7 @@ CREATE TABLE `HZIMS_PUSH_CONFIG` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_PUSH_MESSAGE -- TABLE STRUCTURE FOR HZIMS_PUSH_MESSAGE
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_PUSH_MESSAGE`; CREATE TABLE IF NOT EXISTS `HZIMS_PUSH_MESSAGE` (
CREATE TABLE `HZIMS_PUSH_MESSAGE` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`MESSAGE_TYPE` VARCHAR(20) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '消息类型', `MESSAGE_TYPE` VARCHAR(20) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '消息类型',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务KEY值', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务KEY值',
@ -396,7 +381,8 @@ CREATE TABLE `HZIMS_PUSH_MESSAGE` (
`IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除 0-正常 1-删除', `IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除 0-正常 1-删除',
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB AUTO_INCREMENT = 1 CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC; ) ENGINE = INNODB AUTO_INCREMENT = 1 CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC;
CREATE TABLE `hzims_message`.`hzims_message_push_record` (
CREATE TABLE IF NOT EXISTS `hzims_message_push_record` (
`ID` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`TASK_ID` bigint(20) NOT NULL COMMENT '消息类型', `TASK_ID` bigint(20) NOT NULL COMMENT '消息类型',
`TEMPLATE_ID` bigint(20) NULL DEFAULT NULL COMMENT '消息模板ID', `TEMPLATE_ID` bigint(20) NULL DEFAULT NULL COMMENT '消息模板ID',
@ -433,7 +419,7 @@ CREATE TABLE `hzims_message`.`hzims_message_push_record` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '消息推送记录' ROW_FORMAT = Dynamic; ) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '消息推送记录' ROW_FORMAT = Dynamic;
CREATE TABLE `hzims_message`.`hzims_message_template` ( CREATE TABLE IF NOT EXISTS `hzims_message_template` (
`ID` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '消息类型', `ID` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '消息类型',
`TYPE` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '主键ID', `TYPE` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '主键ID',
`BUSINESS_KEY` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务关键字', `BUSINESS_KEY` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务关键字',
@ -457,8 +443,7 @@ CREATE TABLE `hzims_message`.`hzims_message_template` (
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_SMS_LOG -- TABLE STRUCTURE FOR HZIMS_SMS_LOG
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_SMS_LOG`; CREATE TABLE IF NOT EXISTS `HZIMS_SMS_LOG` (
CREATE TABLE `HZIMS_SMS_LOG` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字',
`BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT', `BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT',
@ -482,9 +467,10 @@ CREATE TABLE `HZIMS_SMS_LOG` (
`IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除 0-正常 1-删除', `IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除 0-正常 1-删除',
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB AUTO_INCREMENT = 1612776146498326531 CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC; ) ENGINE = INNODB AUTO_INCREMENT = 1612776146498326531 CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC;
ALTER TABLE `hzims_message`.`hzims_push_config` MODIFY COLUMN `TIME_UNIT` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '时间单位' AFTER `DURATION`;
CREATE TABLE `hzims_message`.`hzims_push_message` ( ALTER TABLE `hzims_push_config` MODIFY COLUMN `TIME_UNIT` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '时间单位' AFTER `DURATION`;
CREATE TABLE IF NOT EXISTS `hzims_push_message` (
`ID` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`MESSAGE_TYPE` varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '消息类型', `MESSAGE_TYPE` varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '消息类型',
`BUSINESS_KEY` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务key值', `BUSINESS_KEY` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务key值',
@ -503,17 +489,16 @@ CREATE TABLE `hzims_message`.`hzims_push_message` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = Dynamic; ) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = Dynamic;
ALTER TABLE `hzims_message`.`hzims_sms_config` MODIFY COLUMN `CONTENT_VARIABLES` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '短信模板参数变量定义' AFTER `IS_DELETED`; ALTER TABLE `hzims_sms_config` MODIFY COLUMN `CONTENT_VARIABLES` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '短信模板参数变量定义' AFTER `IS_DELETED`;
ALTER TABLE `hzims_message`.`hzims_sms_config` MODIFY COLUMN `TIME_UNIT` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '时间单位' AFTER `DURATION`; ALTER TABLE `hzims_sms_config` MODIFY COLUMN `TIME_UNIT` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '时间单位' AFTER `DURATION`;
ALTER TABLE `hzims_message`.`hzims_ws_config` ADD COLUMN `DURATION` mediumint(9) NULL DEFAULT NULL COMMENT '多长时间内的推送' AFTER `IS_DELETED`; ALTER TABLE `hzims_ws_config` ADD COLUMN `DURATION` mediumint(9) NULL DEFAULT NULL COMMENT '多长时间内的推送' AFTER `IS_DELETED`;
-- ---------------------------- -- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_WS_CONFIG -- TABLE STRUCTURE FOR HZIMS_WS_CONFIG
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `HZIMS_WS_CONFIG`; CREATE TABLE IF NOT EXISTS `HZIMS_WS_CONFIG` (
CREATE TABLE `HZIMS_WS_CONFIG` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID', `ID` BIGINT(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字', `BUSINESS_KEY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务关键字',
`BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT', `BUSINESS_CLASSIFY` VARCHAR(100) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NOT NULL COMMENT '业务分类。系统通知:SYSTEM,事务消息:BUSINESS,日常提醒:DAILYREMIND,巡检消息:INSPECT',

0
hzims-service/message/src/main/resources/db/2.0.0.sql.1 → hzims-service/message/src/main/resources/db/2.0.0.sql

42
hzims-service/operational/src/main/resources/db/4.0.0 .sql.1

@ -1,42 +0,0 @@
-- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_OPER_CONSTRUCTION
-- ----------------------------
DROP TABLE IF EXISTS `HZIMS_OPER_CONSTRUCTION`;
CREATE TABLE `HZIMS_OPER_CONSTRUCTION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CODE` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '施工编号',
`CONSTRUCTION_TIME` DATETIME NULL DEFAULT NULL COMMENT '施工时间',
`OVERHAUL_NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '检修名称',
`CONSTRUCTION_LOCATION` VARCHAR(1024) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '施工地点',
`OVERHAUL_HEAD` BIGINT(20) NULL DEFAULT NULL COMMENT '检修负责人',
`OVERHAUL_HEAD_NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '检修负责人名称',
`OVERHAUL_PERSONNEL` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '检修人员: 根据“,”分割',
`OVERHAUL_PERSONNEL_NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '检修人员名称: 根据“,”分割',
`OVERHAUL_TIME` DATETIME NULL DEFAULT NULL COMMENT '检修时间',
`COMPLETE_WORK_DESC` VARCHAR(2048) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NOT NULL COMMENT '今日完成任务描述',
`PLAN_WORK_DESC` VARCHAR(2048) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '明日工作计划描述',
`CONSTRUCTION_IMG` VARCHAR(512) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '施工图片: 根据“,”分割',
`CONSTRUCTION_ATTACHMENT` VARCHAR(512) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '施工附件',
`RECORDER` BIGINT(20) NULL DEFAULT NULL COMMENT '记录人',
`RECORDER_NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '记录人名称',
`REVIEWER` BIGINT(20) NULL DEFAULT NULL COMMENT '审核人',
`REVIEWER_NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '审核人名称',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`STATUS` TINYINT(4) NULL DEFAULT 0 COMMENT '业务状态',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '创建单位',
`IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`CREATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '创建人',
`CREATE_TIME` DATETIME NOT NULL COMMENT '创建时间',
`UPDATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '修改人',
`UPDATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '修改时间',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8MB4 COLLATE = UTF8MB4_GENERAL_CI ROW_FORMAT = DYNAMIC;
alter table `hzims_oper_maintenance_library` add column `duty_class_tree` VARCHAR(100) NULL COMMENT '班次树,机构/班次类型/班次';
alter table `hzims_station` add COLUMN `deleted_id` BIGINT(20) DEFAULT null COMMENT '删除记录ID';
update `hzims_station` set `deleted_id` = id where `IS_DELETED` = 1;
ALTER TABLE `hzims_station` ADD CONSTRAINT index_code_deleted UNIQUE (`code`, `deleted_id`);
alter table `hzims_station` add column `is_push_project` tinyint(2) default 0 comment '是否推送数据平台';
alter table `hzims_station` add column `is_push_fdp` tinyint(2) default 0 comment '是否推送FDP';
ALTER TABLE `hz_ims_duty_analyse_example` ADD COLUMN `name` varchar(255) NULL COMMENT '配置名称' AFTER `CREATE_DEPT`;

49
hzims-service/operational/src/main/resources/db/2.0.0.sql.1 → hzims-service/operational/src/main/resources/db/5.0.0.sql

@ -1,5 +1,6 @@
alter table hzims_oper_maintenance_plan add column station_code varchar(60) comment '站点编码'; alter table hzims_oper_maintenance_plan add column station_code varchar(60) comment '站点编码';
alter table `hzims_oper_maintenance_task` add column `is_delay` tinyint(2) DEFAULT 0 COMMENT '是否逾期'; alter table `hzims_oper_maintenance_task` add column `is_delay` tinyint(2) DEFAULT 0 COMMENT '是否逾期';
-- 补充执行人、创建人、更新人名称 -- 补充执行人、创建人、更新人名称
alter table `hzims_oper_maintenance_task` add column `disposer_name` varchar(255) comment '执行人姓名'; alter table `hzims_oper_maintenance_task` add column `disposer_name` varchar(255) comment '执行人姓名';
alter table `hzims_oper_maintenance_task` add column `create_user_name` varchar(255) comment '创建人姓名'; alter table `hzims_oper_maintenance_task` add column `create_user_name` varchar(255) comment '创建人姓名';
@ -12,6 +13,7 @@ alter table `hzims_oper_maintenance_task` add COLUMN `ticket_name` VARCHAR(255)
alter table hzims_oper_maintenance_plan add column station_code varchar(60) comment '站点编码'; alter table hzims_oper_maintenance_plan add column station_code varchar(60) comment '站点编码';
alter table `hzims_oper_maintenance_task` add column `is_delay` tinyint(2) DEFAULT 0 COMMENT '是否逾期'; alter table `hzims_oper_maintenance_task` add column `is_delay` tinyint(2) DEFAULT 0 COMMENT '是否逾期';
-- 补充执行人、创建人、更新人名称 -- 补充执行人、创建人、更新人名称
alter table `hzims_oper_maintenance_task` add column `disposer_name` varchar(255) comment '执行人姓名'; alter table `hzims_oper_maintenance_task` add column `disposer_name` varchar(255) comment '执行人姓名';
alter table `hzims_oper_maintenance_task` add column `create_user_name` varchar(255) comment '创建人姓名'; alter table `hzims_oper_maintenance_task` add column `create_user_name` varchar(255) comment '创建人姓名';
@ -19,10 +21,11 @@ alter table `hzims_oper_maintenance_task` add column `update_user_name` varchar(
alter table `hzims_oper_maintenance_plan` add column `disposer_name` varchar(255) comment '执行人姓名'; alter table `hzims_oper_maintenance_plan` add column `disposer_name` varchar(255) comment '执行人姓名';
alter table `hzims_oper_maintenance_plan` add column `create_user_name` varchar(255) comment '创建人姓名'; alter table `hzims_oper_maintenance_plan` add column `create_user_name` varchar(255) comment '创建人姓名';
alter table `hzims_oper_maintenance_plan` add column `update_user_name` varchar(255) comment '更新人姓名'; alter table `hzims_oper_maintenance_plan` add column `update_user_name` varchar(255) comment '更新人姓名';
-- 日常维护任务添加工作票名称 -- 日常维护任务添加工作票名称
alter table `hzims_oper_maintenance_task` add COLUMN `ticket_name` VARCHAR(255) comment '票据名称'; alter table `hzims_oper_maintenance_task` add COLUMN `ticket_name` VARCHAR(255) comment '票据名称';
CREATE TABLE `hzims_operation`.`hz_ims_duty_log` ( CREATE TABLE IF NOT EXISTS `hzims_operation`.`hz_ims_duty_log` (
`id` bigint(20) NOT NULL, `id` bigint(20) NOT NULL,
`duty_id` bigint(20) NULL DEFAULT NULL, `duty_id` bigint(20) NULL DEFAULT NULL,
`time` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `time` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL,
@ -177,3 +180,45 @@ ALTER TABLE `hzims_oper_phenomenon` ADD COLUMN `PRINCIPAL_NAME` varchar(255) CHA
ALTER TABLE `hzims_oper_phenomenon` ADD COLUMN `PLAN_HANDLER_NAME` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '消缺处理人' AFTER `PRINCIPAL_NAME`; ALTER TABLE `hzims_oper_phenomenon` ADD COLUMN `PLAN_HANDLER_NAME` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '消缺处理人' AFTER `PRINCIPAL_NAME`;
-- ----------------------------
-- TABLE STRUCTURE FOR HZIMS_OPER_CONSTRUCTION
-- ----------------------------
CREATE TABLE IF NOT EXISTS `HZIMS_OPER_CONSTRUCTION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CODE` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '施工编号',
`CONSTRUCTION_TIME` DATETIME NULL DEFAULT NULL COMMENT '施工时间',
`OVERHAUL_NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '检修名称',
`CONSTRUCTION_LOCATION` VARCHAR(1024) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '施工地点',
`OVERHAUL_HEAD` BIGINT(20) NULL DEFAULT NULL COMMENT '检修负责人',
`OVERHAUL_HEAD_NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '检修负责人名称',
`OVERHAUL_PERSONNEL` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '检修人员: 根据“,”分割',
`OVERHAUL_PERSONNEL_NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '检修人员名称: 根据“,”分割',
`OVERHAUL_TIME` DATETIME NULL DEFAULT NULL COMMENT '检修时间',
`COMPLETE_WORK_DESC` VARCHAR(2048) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NOT NULL COMMENT '今日完成任务描述',
`PLAN_WORK_DESC` VARCHAR(2048) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '明日工作计划描述',
`CONSTRUCTION_IMG` VARCHAR(512) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '施工图片: 根据“,”分割',
`CONSTRUCTION_ATTACHMENT` VARCHAR(512) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '施工附件',
`RECORDER` BIGINT(20) NULL DEFAULT NULL COMMENT '记录人',
`RECORDER_NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '记录人名称',
`REVIEWER` BIGINT(20) NULL DEFAULT NULL COMMENT '审核人',
`REVIEWER_NAME` VARCHAR(255) CHARACTER SET UTF8MB4 COLLATE UTF8MB4_GENERAL_CI NULL DEFAULT NULL COMMENT '审核人名称',
`TENANT_ID` VARCHAR(12) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '租户ID',
`STATUS` TINYINT(4) NULL DEFAULT 0 COMMENT '业务状态',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '创建单位',
`IS_DELETED` TINYINT(4) NOT NULL DEFAULT 0 COMMENT '是否删除',
`CREATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '创建人',
`CREATE_TIME` DATETIME NOT NULL COMMENT '创建时间',
`UPDATE_USER` BIGINT(20) NULL DEFAULT NULL COMMENT '修改人',
`UPDATE_TIME` DATETIME NULL DEFAULT NULL COMMENT '修改时间',
PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8MB4 COLLATE = UTF8MB4_GENERAL_CI ROW_FORMAT = DYNAMIC;
alter table `hzims_oper_maintenance_library` add column `duty_class_tree` VARCHAR(100) NULL COMMENT '班次树,机构/班次类型/班次';
alter table `hzims_station` add COLUMN `deleted_id` BIGINT(20) DEFAULT null COMMENT '删除记录ID';
update `hzims_station` set `deleted_id` = id where `IS_DELETED` = 1;
ALTER TABLE `hzims_station` ADD CONSTRAINT index_code_deleted UNIQUE (`code`, `deleted_id`);
alter table `hzims_station` add column `is_push_project` tinyint(2) default 0 comment '是否推送数据平台';
alter table `hzims_station` add column `is_push_fdp` tinyint(2) default 0 comment '是否推送FDP';
ALTER TABLE `hz_ims_duty_analyse_example` ADD COLUMN `name` varchar(255) NULL COMMENT '配置名称' AFTER `CREATE_DEPT`;

88
hzims-service/safeproduct/src/main/resources/db/2.0.0.sql.1 → hzims-service/safeproduct/src/main/resources/db/2.0.0.sql

@ -1,4 +1,4 @@
CREATE TABLE DOCUMENT_MANAGEMENT CREATE TABLE IF NOT EXISTS DOCUMENT_MANAGEMENT
( (
ID BIGINT PRIMARY KEY AUTO_INCREMENT, ID BIGINT PRIMARY KEY AUTO_INCREMENT,
DOCUMENT_NAME VARCHAR(100) COMMENT '文档名称', DOCUMENT_NAME VARCHAR(100) COMMENT '文档名称',
@ -12,7 +12,7 @@ CREATE TABLE DOCUMENT_MANAGEMENT
ALTER TABLE `HZIMS_SAFE_SAFETY_TOOL` ADD COLUMN `ADVANCE_NOTICE_DAYS` TINYINT(4) DEFAULT 0 COMMENT '安全工器具提前通知天数'; ALTER TABLE `HZIMS_SAFE_SAFETY_TOOL` ADD COLUMN `ADVANCE_NOTICE_DAYS` TINYINT(4) DEFAULT 0 COMMENT '安全工器具提前通知天数';
CREATE TABLE `HZIMS_REHEARSAL_PLAN` ( CREATE TABLE IF NOT EXISTS `HZIMS_REHEARSAL_PLAN` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`UNIT` VARCHAR(50) NOT NULL COMMENT '单位', `UNIT` VARCHAR(50) NOT NULL COMMENT '单位',
`SUBJECT` VARCHAR(50) NOT NULL COMMENT '演练科目', `SUBJECT` VARCHAR(50) NOT NULL COMMENT '演练科目',
@ -32,7 +32,7 @@ CREATE TABLE `HZIMS_REHEARSAL_PLAN` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='演练计划表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='演练计划表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_REHEARSAL_RECORD` ( CREATE TABLE IF NOT EXISTS `HZIMS_REHEARSAL_RECORD` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`REHEARSAL_PLAN_ID` BIGINT(20) NOT NULL COMMENT '演练计划ID', `REHEARSAL_PLAN_ID` BIGINT(20) NOT NULL COMMENT '演练计划ID',
`CODE` VARCHAR(50) NOT NULL COMMENT '编号', `CODE` VARCHAR(50) NOT NULL COMMENT '编号',
@ -54,7 +54,7 @@ CREATE TABLE `HZIMS_REHEARSAL_RECORD` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='演练记录表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='演练记录表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_TRAIN_PLAN` ( CREATE TABLE IF NOT EXISTS `HZIMS_TRAIN_PLAN` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`UNIT` VARCHAR(50) NOT NULL COMMENT '单位', `UNIT` VARCHAR(50) NOT NULL COMMENT '单位',
`SCHEDULED_START_TIME` DATE NOT NULL COMMENT '计划培训开始时间', `SCHEDULED_START_TIME` DATE NOT NULL COMMENT '计划培训开始时间',
@ -75,7 +75,7 @@ CREATE TABLE `HZIMS_TRAIN_PLAN` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='培训计划表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='培训计划表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_TRAIN_RECORD` ( CREATE TABLE IF NOT EXISTS `HZIMS_TRAIN_RECORD` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TRAIN_PLAN_ID` BIGINT(20) DEFAULT NULL COMMENT '培训计划ID', `TRAIN_PLAN_ID` BIGINT(20) DEFAULT NULL COMMENT '培训计划ID',
`TRAIN_RECORD_NAME` VARCHAR(50) NOT NULL DEFAULT '' COMMENT '培训记录名称', `TRAIN_RECORD_NAME` VARCHAR(50) NOT NULL DEFAULT '' COMMENT '培训记录名称',
@ -97,7 +97,7 @@ CREATE TABLE `HZIMS_TRAIN_RECORD` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='培训记录表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='培训记录表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_TEST` ( CREATE TABLE IF NOT EXISTS `HZIMS_TEST` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TRAIN_PLAN_ID` BIGINT(20) DEFAULT NULL COMMENT '培训计划ID', `TRAIN_PLAN_ID` BIGINT(20) DEFAULT NULL COMMENT '培训计划ID',
`TRAIN_RECORD_ID` BIGINT(20) DEFAULT NULL COMMENT '培训记录ID', `TRAIN_RECORD_ID` BIGINT(20) DEFAULT NULL COMMENT '培训记录ID',
@ -123,7 +123,7 @@ CREATE TABLE `HZIMS_TEST` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='考试记录表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='考试记录表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_TEST_SCORE` ( CREATE TABLE IF NOT EXISTS `HZIMS_TEST_SCORE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TEST_ID` BIGINT(20) DEFAULT NULL COMMENT '考试记录ID', `TEST_ID` BIGINT(20) DEFAULT NULL COMMENT '考试记录ID',
`NAME` VARCHAR(50) NOT NULL COMMENT '姓名', `NAME` VARCHAR(50) NOT NULL COMMENT '姓名',
@ -138,7 +138,12 @@ CREATE TABLE `HZIMS_TEST_SCORE` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='考试成绩表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='考试成绩表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_CONFERENCE_PLAN` ( ALTER TABLE `hzims_test_score`
ADD COLUMN `user_id` bigint(20) NULL AFTER `is_deleted`,
ADD COLUMN `dept_name` varchar(255) NULL AFTER `user_id`,
ADD COLUMN `dept_id` bigint(20) NULL AFTER `dept_name`;
CREATE TABLE IF NOT EXISTS `HZIMS_CONFERENCE_PLAN` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`UNIT` VARCHAR(50) NOT NULL COMMENT '单位', `UNIT` VARCHAR(50) NOT NULL COMMENT '单位',
`THEME` VARCHAR(50) NOT NULL COMMENT '会议主题', `THEME` VARCHAR(50) NOT NULL COMMENT '会议主题',
@ -158,7 +163,7 @@ CREATE TABLE `HZIMS_CONFERENCE_PLAN` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='会议计划表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='会议计划表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_CONFERENCE_RECORD` ( CREATE TABLE IF NOT EXISTS `HZIMS_CONFERENCE_RECORD` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CONFERENCE_PLAN_ID` BIGINT(20) NOT NULL COMMENT '会议计划ID', `CONFERENCE_PLAN_ID` BIGINT(20) NOT NULL COMMENT '会议计划ID',
`CODE` VARCHAR(50) NOT NULL COMMENT '编号', `CODE` VARCHAR(50) NOT NULL COMMENT '编号',
@ -179,7 +184,7 @@ CREATE TABLE `HZIMS_CONFERENCE_RECORD` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='会议记录表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='会议记录表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_HYGIENE_PLAN` ( CREATE TABLE IF NOT EXISTS `HZIMS_HYGIENE_PLAN` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`UNIT` VARCHAR(50) NOT NULL COMMENT '单位', `UNIT` VARCHAR(50) NOT NULL COMMENT '单位',
`NAME` VARCHAR(50) NOT NULL COMMENT '名称', `NAME` VARCHAR(50) NOT NULL COMMENT '名称',
@ -197,7 +202,7 @@ CREATE TABLE `HZIMS_HYGIENE_PLAN` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='卫生自查计划表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='卫生自查计划表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_HYGIENE_ZONE` ( CREATE TABLE IF NOT EXISTS `HZIMS_HYGIENE_ZONE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`HYGIENE_PLAN_ID` BIGINT(20) NOT NULL COMMENT '卫生自查计划ID', `HYGIENE_PLAN_ID` BIGINT(20) NOT NULL COMMENT '卫生自查计划ID',
`ZONE` VARCHAR(50) NOT NULL COMMENT '责任区', `ZONE` VARCHAR(50) NOT NULL COMMENT '责任区',
@ -214,7 +219,7 @@ CREATE TABLE `HZIMS_HYGIENE_ZONE` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='卫生自查区域表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='卫生自查区域表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_HYGIENE_RECORD` ( CREATE TABLE IF NOT EXISTS `HZIMS_HYGIENE_RECORD` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`HYGIENE_PLAN_ID` BIGINT(20) NOT NULL COMMENT '卫生自查计划ID', `HYGIENE_PLAN_ID` BIGINT(20) NOT NULL COMMENT '卫生自查计划ID',
`UNIT` VARCHAR(50) NOT NULL COMMENT '单位', `UNIT` VARCHAR(50) NOT NULL COMMENT '单位',
@ -238,7 +243,7 @@ CREATE TABLE `HZIMS_HYGIENE_RECORD` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='卫生自查记录表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='卫生自查记录表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_CAR` ( CREATE TABLE IF NOT EXISTS `HZIMS_CAR` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`UNIT` VARCHAR(50) NOT NULL COMMENT '单位', `UNIT` VARCHAR(50) NOT NULL COMMENT '单位',
`CAR_BRAND` VARCHAR(50) NOT NULL COMMENT '品牌', `CAR_BRAND` VARCHAR(50) NOT NULL COMMENT '品牌',
@ -269,7 +274,7 @@ CREATE TABLE `HZIMS_CAR` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车辆台账表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车辆台账表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_CAR_MAINTENANCE` ( CREATE TABLE IF NOT EXISTS `HZIMS_CAR_MAINTENANCE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CAR_ID` BIGINT(20) NOT NULL COMMENT '车辆ID', `CAR_ID` BIGINT(20) NOT NULL COMMENT '车辆ID',
`CODE` VARCHAR(50) NOT NULL COMMENT '编号', `CODE` VARCHAR(50) NOT NULL COMMENT '编号',
@ -294,7 +299,7 @@ CREATE TABLE `HZIMS_CAR_MAINTENANCE` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车辆维保记录表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车辆维保记录表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_CAR_USED_RECORD` ( CREATE TABLE IF NOT EXISTS `HZIMS_CAR_USED_RECORD` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CAR_ID` BIGINT(20) NOT NULL COMMENT '车辆ID', `CAR_ID` BIGINT(20) NOT NULL COMMENT '车辆ID',
`CODE` VARCHAR(50) NOT NULL COMMENT '编号', `CODE` VARCHAR(50) NOT NULL COMMENT '编号',
@ -320,7 +325,7 @@ CREATE TABLE `HZIMS_CAR_USED_RECORD` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='用车记录表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='用车记录表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_CAR_CHECK_RECORD` ( CREATE TABLE IF NOT EXISTS `HZIMS_CAR_CHECK_RECORD` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CAR_ID` BIGINT(20) NOT NULL COMMENT '车辆ID', `CAR_ID` BIGINT(20) NOT NULL COMMENT '车辆ID',
`CODE` VARCHAR(50) NOT NULL COMMENT '编号', `CODE` VARCHAR(50) NOT NULL COMMENT '编号',
@ -338,7 +343,7 @@ CREATE TABLE `HZIMS_CAR_CHECK_RECORD` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车检记录表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车检记录表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_CAR_CHECK_ITEM` ( CREATE TABLE IF NOT EXISTS `HZIMS_CAR_CHECK_ITEM` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CAR_CHECK_RECORD_ID` BIGINT(20) NOT NULL COMMENT '车检记录ID', `CAR_CHECK_RECORD_ID` BIGINT(20) NOT NULL COMMENT '车检记录ID',
`CHECK_ITEM` VARCHAR(500) NOT NULL COMMENT '检查项目', `CHECK_ITEM` VARCHAR(500) NOT NULL COMMENT '检查项目',
@ -354,7 +359,7 @@ CREATE TABLE `HZIMS_CAR_CHECK_ITEM` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车检项表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车检项表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_CAR_ANNUAL_INSPECTION` ( CREATE TABLE IF NOT EXISTS `HZIMS_CAR_ANNUAL_INSPECTION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CAR_ID` BIGINT(20) NOT NULL COMMENT '车辆ID', `CAR_ID` BIGINT(20) NOT NULL COMMENT '车辆ID',
`CODE` VARCHAR(50) NOT NULL COMMENT '编号', `CODE` VARCHAR(50) NOT NULL COMMENT '编号',
@ -372,7 +377,7 @@ CREATE TABLE `HZIMS_CAR_ANNUAL_INSPECTION` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车辆年检记录表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车辆年检记录表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_CAR_INSURANCE` ( CREATE TABLE IF NOT EXISTS `HZIMS_CAR_INSURANCE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CAR_ID` BIGINT(20) NOT NULL COMMENT '车辆ID', `CAR_ID` BIGINT(20) NOT NULL COMMENT '车辆ID',
`CODE` VARCHAR(50) NOT NULL COMMENT '编号', `CODE` VARCHAR(50) NOT NULL COMMENT '编号',
@ -390,7 +395,7 @@ CREATE TABLE `HZIMS_CAR_INSURANCE` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车保记录表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='车保记录表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_DEVICE` ( CREATE TABLE IF NOT EXISTS `HZIMS_DEVICE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`NAME` VARCHAR(50) NOT NULL COMMENT '设备名称', `NAME` VARCHAR(50) NOT NULL COMMENT '设备名称',
`TYPE` VARCHAR(50) NOT NULL DEFAULT '' COMMENT '规格型号', `TYPE` VARCHAR(50) NOT NULL DEFAULT '' COMMENT '规格型号',
@ -416,7 +421,7 @@ CREATE TABLE `HZIMS_DEVICE` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='特种设备表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='特种设备表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_DEVICE_INSPECTION` ( CREATE TABLE IF NOT EXISTS `HZIMS_DEVICE_INSPECTION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`DEVICE_ID` BIGINT(20) NOT NULL COMMENT '设备ID', `DEVICE_ID` BIGINT(20) NOT NULL COMMENT '设备ID',
`INSPECTION_TIME` DATE NOT NULL COMMENT '设备检验时间', `INSPECTION_TIME` DATE NOT NULL COMMENT '设备检验时间',
@ -434,7 +439,7 @@ CREATE TABLE `HZIMS_DEVICE_INSPECTION` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='特种设备表' ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB CHARACTER SET=UTF8MB4 COLLATE=UTF8MB4_GENERAL_CI COMMENT='特种设备表' ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_HAZARD_LIBRARY` ( CREATE TABLE IF NOT EXISTS `HZIMS_HAZARD_LIBRARY` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`STATION_TYPE` TINYINT(4) NOT NULL COMMENT '站点类型', `STATION_TYPE` TINYINT(4) NOT NULL COMMENT '站点类型',
`STATION_TYPE_NAME` VARCHAR(25) NOT NULL COMMENT '站点类型名称', `STATION_TYPE_NAME` VARCHAR(25) NOT NULL COMMENT '站点类型名称',
@ -602,8 +607,7 @@ INSERT INTO `BLADEX`.`BLADE_DICT` (`ID`, `PARENT_ID`, `CODE`, `DICT_KEY`, `DICT_
INSERT INTO `BLADEX`.`BLADE_DICT` (`ID`, `PARENT_ID`, `CODE`, `DICT_KEY`, `DICT_VALUE`, `SORT`, `REMARK`, `IS_SEALED`, `IS_DELETED`, `DICT_TYPE`, `APP_ID`, `APP_CODE`) VALUES (1811421133117767769, 1810401848933404699, 'INNER_DANGER_TYPE', '4', '管理因素', 5, '', 0, 0, 1, -1, 'HZIMS_SAFEPRODUCT'); INSERT INTO `BLADEX`.`BLADE_DICT` (`ID`, `PARENT_ID`, `CODE`, `DICT_KEY`, `DICT_VALUE`, `SORT`, `REMARK`, `IS_SEALED`, `IS_DELETED`, `DICT_TYPE`, `APP_ID`, `APP_CODE`) VALUES (1811421133117767769, 1810401848933404699, 'INNER_DANGER_TYPE', '4', '管理因素', 5, '', 0, 0, 1, -1, 'HZIMS_SAFEPRODUCT');
INSERT INTO `BLADEX`.`BLADE_DICT` (`ID`, `PARENT_ID`, `CODE`, `DICT_KEY`, `DICT_VALUE`, `SORT`, `REMARK`, `IS_SEALED`, `IS_DELETED`, `DICT_TYPE`, `APP_ID`, `APP_CODE`) VALUES (1811421133117767770, 1810401848933404699, 'INNER_DANGER_TYPE', '5', '其他', 5, '', 0, 0, 1, -1, 'HZIMS_SAFEPRODUCT'); INSERT INTO `BLADEX`.`BLADE_DICT` (`ID`, `PARENT_ID`, `CODE`, `DICT_KEY`, `DICT_VALUE`, `SORT`, `REMARK`, `IS_SEALED`, `IS_DELETED`, `DICT_TYPE`, `APP_ID`, `APP_CODE`) VALUES (1811421133117767770, 1810401848933404699, 'INNER_DANGER_TYPE', '5', '其他', 5, '', 0, 0, 1, -1, 'HZIMS_SAFEPRODUCT');
DROP TABLE IF EXISTS `HZIMS_INNER_DANGER_INFO`; CREATE TABLE IF NOT EXISTS `HZIMS_INNER_DANGER_INFO` (
CREATE TABLE `HZIMS_INNER_DANGER_INFO` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`CODE` VARCHAR(255) NOT NULL COMMENT '隐患编码', `CODE` VARCHAR(255) NOT NULL COMMENT '隐患编码',
`STATION_CODE` VARCHAR(255) DEFAULT NULL COMMENT '站点编码', `STATION_CODE` VARCHAR(255) DEFAULT NULL COMMENT '站点编码',
@ -660,7 +664,7 @@ CREATE TABLE `HZIMS_INNER_DANGER_INFO` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_RISK_HAZARD_CATEGORY` ( CREATE TABLE IF NOT EXISTS `HZIMS_RISK_HAZARD_CATEGORY` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`STATION_TYPE` TINYINT(4) DEFAULT NULL COMMENT '站点类别 :闸门、水库', `STATION_TYPE` TINYINT(4) DEFAULT NULL COMMENT '站点类别 :闸门、水库',
`CATEGORY` TINYINT(4) DEFAULT NULL COMMENT '类别 :构筑物类、金属结构类、设备设施类', `CATEGORY` TINYINT(4) DEFAULT NULL COMMENT '类别 :构筑物类、金属结构类、设备设施类',
@ -676,7 +680,7 @@ CREATE TABLE `HZIMS_INNER_DANGER_INFO` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_HIDDEN_DANGER_PLAN` ( CREATE TABLE IF NOT EXISTS `HZIMS_HIDDEN_DANGER_PLAN` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`PLAN_NAME` VARCHAR(50) NOT NULL COMMENT '计划名称', `PLAN_NAME` VARCHAR(50) NOT NULL COMMENT '计划名称',
`CHECK_TYPE` VARCHAR(2) DEFAULT NULL COMMENT '排查类型,字典:HD_CHECK_TYPE', `CHECK_TYPE` VARCHAR(2) DEFAULT NULL COMMENT '排查类型,字典:HD_CHECK_TYPE',
@ -702,7 +706,7 @@ CREATE TABLE `HZIMS_HIDDEN_DANGER_PLAN` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_HIDDEN_DANGER_PLAN_ITEM` ( CREATE TABLE IF NOT EXISTS `HZIMS_HIDDEN_DANGER_PLAN_ITEM` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`PLAN_ID` BIGINT(20) NOT NULL COMMENT '隐患排查计划ID', `PLAN_ID` BIGINT(20) NOT NULL COMMENT '隐患排查计划ID',
`AREA_ID` BIGINT(20) DEFAULT NULL COMMENT '区域/位置ID', `AREA_ID` BIGINT(20) DEFAULT NULL COMMENT '区域/位置ID',
@ -725,7 +729,7 @@ CREATE TABLE `HZIMS_HIDDEN_DANGER_PLAN_ITEM` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_RISK_HAZARD_ESTIMATE` ( CREATE TABLE IF NOT EXISTS `HZIMS_RISK_HAZARD_ESTIMATE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`TASK_ID` BIGINT(20) DEFAULT NULL COMMENT '风险任务排查ID', `TASK_ID` BIGINT(20) DEFAULT NULL COMMENT '风险任务排查ID',
`CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '风险点ID', `CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '风险点ID',
@ -754,7 +758,7 @@ CREATE TABLE `HZIMS_RISK_HAZARD_ESTIMATE` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_RISK_HAZARD_LEVEL` ( CREATE TABLE IF NOT EXISTS `HZIMS_RISK_HAZARD_LEVEL` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '风险点编号', `CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '风险点编号',
`SOURCE_ID` BIGINT(20) DEFAULT NULL COMMENT '危险源编号', `SOURCE_ID` BIGINT(20) DEFAULT NULL COMMENT '危险源编号',
@ -775,7 +779,7 @@ CREATE TABLE `HZIMS_RISK_HAZARD_LEVEL` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_RISK_HAZARD_SOURCE` ( CREATE TABLE IF NOT EXISTS `HZIMS_RISK_HAZARD_SOURCE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '危险源项目类别ID', `CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '危险源项目类别ID',
`HAZARD_NAME` VARCHAR(255) DEFAULT NULL COMMENT '危险源', `HAZARD_NAME` VARCHAR(255) DEFAULT NULL COMMENT '危险源',
@ -799,7 +803,7 @@ CREATE TABLE `HZIMS_RISK_HAZARD_SOURCE` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_RISK_HAZARD_TASK` ( CREATE TABLE IF NOT EXISTS `HZIMS_RISK_HAZARD_TASK` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`PROCESS_INSTANCE_ID` VARCHAR(64) CHARACTER SET UTF8 DEFAULT '' COMMENT '工作流实例', `PROCESS_INSTANCE_ID` VARCHAR(64) CHARACTER SET UTF8 DEFAULT '' COMMENT '工作流实例',
`STATION_CODE` VARCHAR(64) DEFAULT NULL COMMENT '站点编码', `STATION_CODE` VARCHAR(64) DEFAULT NULL COMMENT '站点编码',
@ -824,7 +828,7 @@ CREATE TABLE `HZIMS_RISK_HAZARD_TASK` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_RISK_HAZARD_WORK` ( CREATE TABLE IF NOT EXISTS `HZIMS_RISK_HAZARD_WORK` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`STATION_CODE` VARCHAR(64) DEFAULT NULL COMMENT '站点编码', `STATION_CODE` VARCHAR(64) DEFAULT NULL COMMENT '站点编码',
`STATION_NAME` VARCHAR(612) DEFAULT NULL COMMENT '站点名称', `STATION_NAME` VARCHAR(612) DEFAULT NULL COMMENT '站点名称',
@ -845,7 +849,7 @@ CREATE TABLE `HZIMS_RISK_HAZARD_WORK` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_RISK_WORK_SOURCE_CORRELATION` ( CREATE TABLE IF NOT EXISTS `HZIMS_RISK_WORK_SOURCE_CORRELATION` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`WORK_ID` BIGINT(20) DEFAULT NULL COMMENT '作业区域ID', `WORK_ID` BIGINT(20) DEFAULT NULL COMMENT '作业区域ID',
`CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '风险点ID', `CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '风险点ID',
@ -861,7 +865,7 @@ CREATE TABLE `HZIMS_RISK_WORK_SOURCE_CORRELATION` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_SAFE_CHECK_COMPANY` ( CREATE TABLE IF NOT EXISTS `HZIMS_SAFE_CHECK_COMPANY` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`TENANT_ID` VARCHAR(12) NOT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) NOT NULL COMMENT '租户ID',
`START_TIME` DATETIME DEFAULT NULL COMMENT '开始时间', `START_TIME` DATETIME DEFAULT NULL COMMENT '开始时间',
@ -878,7 +882,7 @@ CREATE TABLE `HZIMS_SAFE_CHECK_COMPANY` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC COMMENT='公司检查'; ) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC COMMENT='公司检查';
CREATE TABLE `HZIMS_SAFE_CHECK_ITEM` ( CREATE TABLE IF NOT EXISTS `HZIMS_SAFE_CHECK_ITEM` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`TENANT_ID` VARCHAR(12) NOT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) NOT NULL COMMENT '租户ID',
`PARENT_ITEM` BIGINT(20) DEFAULT NULL COMMENT '父级检查项', `PARENT_ITEM` BIGINT(20) DEFAULT NULL COMMENT '父级检查项',
@ -896,7 +900,7 @@ CREATE TABLE `HZIMS_SAFE_CHECK_ITEM` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC COMMENT='检查项管理'; ) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC COMMENT='检查项管理';
CREATE TABLE `HZIMS_SAFE_CHECK_ITEM_INSTANCE` ( CREATE TABLE IF NOT EXISTS `HZIMS_SAFE_CHECK_ITEM_INSTANCE` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`TENANT_ID` VARCHAR(12) NOT NULL COMMENT '租户ID', `TENANT_ID` VARCHAR(12) NOT NULL COMMENT '租户ID',
`OID` BIGINT(20) DEFAULT NULL COMMENT '原始ID,用于维持父子结构', `OID` BIGINT(20) DEFAULT NULL COMMENT '原始ID,用于维持父子结构',
@ -920,7 +924,7 @@ CREATE TABLE `HZIMS_SAFE_CHECK_ITEM_INSTANCE` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC COMMENT='检查项实例'; ) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC COMMENT='检查项实例';
CREATE TABLE `HZIMS_HIDDEN_DANGER_TASK` ( CREATE TABLE IF NOT EXISTS `HZIMS_HIDDEN_DANGER_TASK` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`PLAN_ID` BIGINT(20) NOT NULL COMMENT '隐患排查计划ID', `PLAN_ID` BIGINT(20) NOT NULL COMMENT '隐患排查计划ID',
`PLAN_NAME` VARCHAR(50) NOT NULL COMMENT '计划名称', `PLAN_NAME` VARCHAR(50) NOT NULL COMMENT '计划名称',
@ -945,7 +949,7 @@ CREATE TABLE `HZIMS_HIDDEN_DANGER_TASK` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_HIDDEN_DANGER_TASK_ITEM` ( CREATE TABLE IF NOT EXISTS `HZIMS_HIDDEN_DANGER_TASK_ITEM` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`TASK_ID` BIGINT(20) NOT NULL COMMENT '隐患排查任务ID', `TASK_ID` BIGINT(20) NOT NULL COMMENT '隐患排查任务ID',
`CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '风险点ID', `CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '风险点ID',
@ -972,7 +976,7 @@ CREATE TABLE `HZIMS_HIDDEN_DANGER_TASK_ITEM` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_RISK_ESTIMATE` ( CREATE TABLE IF NOT EXISTS `HZIMS_RISK_ESTIMATE` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`STATION_CODE` VARCHAR(64) DEFAULT NULL COMMENT '站点编码', `STATION_CODE` VARCHAR(64) DEFAULT NULL COMMENT '站点编码',
`STATION_NAME` VARCHAR(255) DEFAULT NULL COMMENT '站点名称', `STATION_NAME` VARCHAR(255) DEFAULT NULL COMMENT '站点名称',
@ -989,7 +993,7 @@ CREATE TABLE `HZIMS_RISK_ESTIMATE` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_RISK_ESTIMATE_POINT` ( CREATE TABLE IF NOT EXISTS `HZIMS_RISK_ESTIMATE_POINT` (
`ID` BIGINT(20) NOT NULL COMMENT '主键ID', `ID` BIGINT(20) NOT NULL COMMENT '主键ID',
`ESTIMATE_ID` BIGINT(20) DEFAULT NULL COMMENT '风险评估ID', `ESTIMATE_ID` BIGINT(20) DEFAULT NULL COMMENT '风险评估ID',
`CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '风险点ID', `CATEGORY_ID` BIGINT(20) DEFAULT NULL COMMENT '风险点ID',
@ -1024,7 +1028,7 @@ CREATE TABLE `HZIMS_RISK_ESTIMATE_POINT` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8MB4 ROW_FORMAT=DYNAMIC;
CREATE TABLE `HZIMS_RISK_CHECK` ( CREATE TABLE IF NOT EXISTS `HZIMS_RISK_CHECK` (
`ID` BIGINT(20) NOT NULL, `ID` BIGINT(20) NOT NULL,
`CATEGORY_ID` BIGINT(20) NOT NULL COMMENT '风险点ID', `CATEGORY_ID` BIGINT(20) NOT NULL COMMENT '风险点ID',
`CATEGORY_NAME` VARCHAR(50) NOT NULL COMMENT '风险点名称', `CATEGORY_NAME` VARCHAR(50) NOT NULL COMMENT '风险点名称',
@ -1041,8 +1045,6 @@ CREATE TABLE `HZIMS_RISK_CHECK` (
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC; ) ENGINE=INNODB DEFAULT CHARSET=UTF8 ROW_FORMAT=DYNAMIC;
ALTER TABLE `HZIMS_INNER_DANGER_INFO` ADD COLUMN `TASK_ID` VARCHAR(100) COMMENT '平台任务ID';
-- 电站安全标准附件字段长度限制 -- 电站安全标准附件字段长度限制
ALTER TABLE HZIMS_REVIEW MODIFY COLUMN FILE_NAME VARCHAR(2048) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '附件文件名称' AFTER REVIEW_TIME; ALTER TABLE HZIMS_REVIEW MODIFY COLUMN FILE_NAME VARCHAR(2048) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '附件文件名称' AFTER REVIEW_TIME;
ALTER TABLE HZIMS_REVIEW MODIFY COLUMN FILE_URL VARCHAR(1024) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '附件文件URL' AFTER FILE_NAME; ALTER TABLE HZIMS_REVIEW MODIFY COLUMN FILE_URL VARCHAR(1024) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '附件文件URL' AFTER FILE_NAME;

4
hzims-service/safeproduct/src/main/resources/db/3.0.0.sql.1

@ -1,4 +0,0 @@
ALTER TABLE `hzims_test_score`
ADD COLUMN `user_id` bigint(20) NULL AFTER `is_deleted`,
ADD COLUMN `dept_name` varchar(255) NULL AFTER `user_id`,
ADD COLUMN `dept_id` bigint(20) NULL AFTER `dept_name`;

38
hzims-service/ticket/src/main/resources/db/4.0.0.sql → hzims-service/ticket/src/main/resources/db/3.0.0.sql

@ -1,8 +1,34 @@
-- ---------------------------- ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `create_user_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建人姓名' AFTER `class_group_name`;
-- TABLE STRUCTURE FOR HZIMS_WORK_TASK
-- ---------------------------- ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `update_user_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '修改人姓名' AFTER `create_user_name`;
DROP TABLE IF EXISTS `HZIMS_WORK_TASK`;
CREATE TABLE `HZIMS_WORK_TASK` ( ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `issue_order_person_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '发令人名称' AFTER `update_user_name`;
ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `access_order_person_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '受令人名称' AFTER `issue_order_person_name`;
ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `guardian_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '许可人名称' AFTER `access_order_person_name`;
ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `principal_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '负责人名称' AFTER `guardian_name`;
alter table `hzims_work_ticket_finish` add column `end_principal_name` varchar(50) comment '工作终结负责人';
alter table `hzims_work_ticket_finish` add column `end_licensor_name` varchar(50) comment '工作终结许可人';
alter table `hzims_work_ticket_finish` add column `finish_licensor_name` varchar(50) comment '工作票终结许可人';
alter table `hzims_work_ticket_info` add column `is_offline` tinyint(2) default 0 comment '是否线下 : 1-线下,0-线上';
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `signer_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '签发人名称' AFTER `is_offline`;
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `licensor_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '许可人名称' AFTER `signer_name`;
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `watch_principal_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '值班负责人名称' AFTER `licensor_name`;
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `implement_status` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '执行状态字段:0未执行,1为执行(运行人员确认过)' AFTER `watch_principal_name`;
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `update_user_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '修改人名称' AFTER `implement_status`;
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `create_user_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建人名称' AFTER `update_user_name`;
CREATE TABLE IF NOT EXISTS `HZIMS_WORK_TASK` (
`ID` BIGINT(20) NOT NULL COMMENT '主键', `ID` BIGINT(20) NOT NULL COMMENT '主键',
`CODE` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '工作任务单编号', `CODE` VARCHAR(255) CHARACTER SET UTF8 COLLATE UTF8_GENERAL_CI NULL DEFAULT NULL COMMENT '工作任务单编号',
`HEAD` BIGINT(20) NULL DEFAULT NULL COMMENT '工作负责人', `HEAD` BIGINT(20) NULL DEFAULT NULL COMMENT '工作负责人',
@ -38,4 +64,4 @@ CREATE TABLE `HZIMS_WORK_TASK` (
`STATUS` TINYINT(4) NULL DEFAULT NULL COMMENT '状态 ', `STATUS` TINYINT(4) NULL DEFAULT NULL COMMENT '状态 ',
`CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '创建部门', `CREATE_DEPT` BIGINT(20) NULL DEFAULT NULL COMMENT '创建部门',
PRIMARY KEY (`ID`) USING BTREE PRIMARY KEY (`ID`) USING BTREE
) ENGINE = INNODB CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC; ) ENGINE = INNODB CHARACTER SET = UTF8 COLLATE = UTF8_GENERAL_CI ROW_FORMAT = DYNAMIC;

30
hzims-service/ticket/src/main/resources/db/3.0.0.sql.1

@ -1,30 +0,0 @@
ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `create_user_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建人姓名' AFTER `class_group_name`;
ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `update_user_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '修改人姓名' AFTER `create_user_name`;
ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `issue_order_person_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '发令人名称' AFTER `update_user_name`;
ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `access_order_person_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '受令人名称' AFTER `issue_order_person_name`;
ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `guardian_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '许可人名称' AFTER `access_order_person_name`;
ALTER TABLE `hzims_standard_ticket_info` ADD COLUMN `principal_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '负责人名称' AFTER `guardian_name`;
alter table `hzims_work_ticket_finish` add column `end_principal_name` varchar(50) comment '工作终结负责人';
alter table `hzims_work_ticket_finish` add column `end_licensor_name` varchar(50) comment '工作终结许可人';
alter table `hzims_work_ticket_finish` add column `finish_licensor_name` varchar(50) comment '工作票终结许可人';
alter table `hzims_work_ticket_info` add column `is_offline` tinyint(2) default 0 comment '是否线下 : 1-线下,0-线上';
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `signer_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '签发人名称' AFTER `is_offline`;
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `licensor_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '许可人名称' AFTER `signer_name`;
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `watch_principal_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '值班负责人名称' AFTER `licensor_name`;
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `implement_status` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '执行状态字段:0未执行,1为执行(运行人员确认过)' AFTER `watch_principal_name`;
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `update_user_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '修改人名称' AFTER `implement_status`;
ALTER TABLE `hzims_work_ticket_info` ADD COLUMN `create_user_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建人名称' AFTER `update_user_name`;
Loading…
Cancel
Save