Commit 7e37171b authored by 单奇雲's avatar 单奇雲

新增liqubase脚本

parent 0a036e61
...@@ -349,4 +349,101 @@ ...@@ -349,4 +349,101 @@
</sql> </sql>
</changeSet> </changeSet>
<changeSet author="shanqiyun" id="1593309428780-1">
<preConditions onFail="MARK_RAN">
<not>
<tableExists tableName="contingency_original_data" />
</not>
</preConditions>
<comment>create table contingency_original_data</comment>
<sql>
DROP TABLE IF EXISTS contingency_original_data;
CREATE TABLE `contingency_original_data` (
`id` varchar(36) NOT NULL COMMENT 'rule',
`fire_Equipment_Name` varchar(32) NOT NULL COMMENT '记录类型:消息MESSAGE,操作OPERATE',
`fire_Equipment_Id` varchar(500) NOT NULL COMMENT '记录内容:文本信息或者json数据',
`layer` int(11) NOT NULL COMMENT '一级分类',
`fire_Equipment_Layer` int(11) NOT NULL COMMENT '二级分类',
`fire_Equipment_Position` varchar(255) DEFAULT NULL COMMENT '图标,url,或者文件名',
`equipment_Id` int(11) NOT NULL COMMENT '排序',
`equipment_Name` varchar(255) DEFAULT NULL,
`mobile` varchar(255) DEFAULT NULL,
`admin_Name` varchar(255) DEFAULT NULL,
`camera_Codes` varchar(255) DEFAULT NULL,
`camera_Ids` varchar(255) DEFAULT NULL,
`fire_Count` int(11) DEFAULT NULL,
`confirm` varchar(255) DEFAULT NULL,
`create_date` datetime DEFAULT NULL,
`create_user` varchar(50) DEFAULT NULL,
`update_date` datetime DEFAULT NULL,
`update_user` varchar(50) DEFAULT NULL,
`is_delete` bit(1) DEFAULT NULL,
`batch_No` varchar(36) NOT NULL,
`picture1` varchar(255) DEFAULT NULL,
`picture2` varchar(255) DEFAULT NULL,
`picture4` varchar(255) DEFAULT NULL,
`picture3` varchar(255) DEFAULT NULL,
`fire_Truck_Route` varchar(2000) DEFAULT NULL,
`runstep` bit(1) DEFAULT NULL,
`step_state` varchar(255) DEFAULT NULL,
`step` varchar(255) DEFAULT NULL,
`equipment_position3d` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `INDEX_BATCH_NO` (`batch_No`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='应急预案信息节点定义';
</sql>
</changeSet>
<changeSet author="shanqiyun" id="1593309428780-2">
<preConditions onFail="MARK_RAN">
<not>
<tableExists tableName="contingency_plan" />
</not>
</preConditions>
<comment>create table contingency_plan</comment>
<sql>
DROP TABLE IF EXISTS contingency_plan;
CREATE TABLE `contingency_plan` (
`id` varchar(36) NOT NULL COMMENT 'rule',
`record_type` varchar(32) NOT NULL COMMENT '记录类型:消息MESSAGE,操作OPERATE',
`content` varchar(500) NOT NULL COMMENT '记录内容:文本信息或者json数据',
`category` varchar(36) NOT NULL COMMENT '一级分类',
`sub_category` varchar(36) NOT NULL COMMENT '二级分类',
`icon` varchar(255) DEFAULT NULL COMMENT '图标,url,或者文件名',
`sort` int(11) NOT NULL COMMENT '排序',
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='应急预案信息节点定义';
</sql>
</changeSet>
<changeSet author="shanqiyun" id="1593309428780-3">
<preConditions onFail="MARK_RAN">
<not>
<tableExists tableName="contingency_plan_instance" />
</not>
</preConditions>
<comment>create table contingency_plan_instance</comment>
<sql>
DROP TABLE IF EXISTS contingency_plan_instance;
CREATE TABLE `contingency_plan_instance` (
`id` varchar(36) NOT NULL COMMENT 'rule',
`record_type` varchar(32) NOT NULL COMMENT '记录类型:消息MESSAGE,操作OPERATE',
`category` varchar(36) DEFAULT NULL COMMENT '一级分类',
`content` varchar(2000) NOT NULL COMMENT '记录内容:文本信息或者json数据',
`icon` varchar(255) DEFAULT NULL COMMENT '图标,url,或者文件名',
`sort` int(11) DEFAULT NULL COMMENT '所有节点一起的排序号',
`sequence_num` int(11) DEFAULT NULL COMMENT '用于显示的序号',
`batch_no` varchar(36) NOT NULL COMMENT '预案实例编号,暂时无法区分多个火灾,暂时存储报警设备id',
`create_date` datetime DEFAULT NULL,
`create_user` varchar(50) DEFAULT NULL,
`update_date` datetime DEFAULT NULL,
`update_user` varchar(50) DEFAULT NULL,
`is_delete` bit(1) DEFAULT NULL,
`tips` varchar(255) DEFAULT NULL,
`runstate` bit(1) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='应急预案执行记录实例';
</sql>
</changeSet>
</databaseChangeLog> </databaseChangeLog>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment