Commit 6e20d9bc authored by KeYong's avatar KeYong

更新

parent d9e7256e
...@@ -96,7 +96,8 @@ public class EquipmentSpecificIndex extends BaseEntity { ...@@ -96,7 +96,8 @@ public class EquipmentSpecificIndex extends BaseEntity {
@TableField(exist = false) @TableField(exist = false)
private String orgCode; private String orgCode;
@TableField(exist = false) @ApiModelProperty(value = "指标类型编码")
@TableField(value = "type_code")
private String typeCode; private String typeCode;
@TableField(exist = false) @TableField(exist = false)
......
...@@ -1603,6 +1603,7 @@ public class EquipmentSpecificSerivceImpl extends ServiceImpl<EquipmentSpecificM ...@@ -1603,6 +1603,7 @@ public class EquipmentSpecificSerivceImpl extends ServiceImpl<EquipmentSpecificM
equipmentSpecificIndex.setEmergencyLevelDescribe(index.getEmergencyLevelDescribe()); equipmentSpecificIndex.setEmergencyLevelDescribe(index.getEmergencyLevelDescribe());
equipmentSpecificIndex.setUnit(index.getUnit()); equipmentSpecificIndex.setUnit(index.getUnit());
equipmentSpecificIndex.setValueEnum(index.getValueEnum()); equipmentSpecificIndex.setValueEnum(index.getValueEnum());
equipmentSpecificIndex.setTypeCode(index.getTypeCode());
equipmentSpecificIndices.add(equipmentSpecificIndex); equipmentSpecificIndices.add(equipmentSpecificIndex);
}); });
} }
......
...@@ -791,6 +791,7 @@ public class StockServiceImpl extends ServiceImpl<StockMapper, Stock> implements ...@@ -791,6 +791,7 @@ public class StockServiceImpl extends ServiceImpl<StockMapper, Stock> implements
equipmentSpecificIndex.setIsAlarm(index.getIsAlarm()); equipmentSpecificIndex.setIsAlarm(index.getIsAlarm());
equipmentSpecificIndex.setEmergencyLevel(index.getEmergencyLevel()); equipmentSpecificIndex.setEmergencyLevel(index.getEmergencyLevel());
equipmentSpecificIndex.setEmergencyLevelDescribe(index.getEmergencyLevelDescribe()); equipmentSpecificIndex.setEmergencyLevelDescribe(index.getEmergencyLevelDescribe());
equipmentSpecificIndex.setTypeCode(index.getTypeCode());
return equipmentSpecificIndex; return equipmentSpecificIndex;
}).collect(Collectors.toList()); }).collect(Collectors.toList());
if (!equipmentSpecificIndices.isEmpty()) { if (!equipmentSpecificIndices.isEmpty()) {
......
...@@ -915,4 +915,17 @@ ...@@ -915,4 +915,17 @@
alter table `wl_equipment_specific_index` add column `gateway_id` varchar(50) COMMENT '网关标识ID'; alter table `wl_equipment_specific_index` add column `gateway_id` varchar(50) COMMENT '网关标识ID';
</sql> </sql>
</changeSet> </changeSet>
<changeSet author="keyong" id="1694056741">
<preConditions onFail="MARK_RAN">
<not>
<columnExists tableName="wl_equipment_specific_index" columnName="type_code"/>
</not>
</preConditions>
<comment>新增字段 type_code</comment>
<sql>
alter table `wl_equipment_specific_index` add column `type_code` varchar(50) COMMENT '指标类型编码';
UPDATE wl_equipment_specific_index esi SET esi.type_code = ( SELECT type_code FROM wl_equipment_index wei WHERE esi.equipment_index_id = wei.id );
</sql>
</changeSet>
</databaseChangeLog> </databaseChangeLog>
\ No newline at end of file
...@@ -311,7 +311,7 @@ ...@@ -311,7 +311,7 @@
SELECT SELECT
temp.id, temp.id,
temp.name, temp.name,
temp.nowPressure, IF(temp.nowPressure = '--', '--', TRUNCATE(ROUND(temp.nowPressure, 2),2)) AS nowPressure,
temp.area, temp.area,
temp.minPressure AS `minValue`, temp.minPressure AS `minValue`,
temp.maxPressure AS `maxValue`, temp.maxPressure AS `maxValue`,
...@@ -350,7 +350,7 @@ ...@@ -350,7 +350,7 @@
SELECT SELECT
temp.id, temp.id,
temp.name, temp.name,
temp.nowFlow, IF(temp.nowFlow = '--', '--', TRUNCATE(ROUND(temp.nowFlow, 2),2)) AS nowFlow,
temp.area, temp.area,
temp.minFlow AS `minValue`, temp.minFlow AS `minValue`,
temp.maxFlow AS `maxValue`, temp.maxFlow AS `maxValue`,
......
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