Commit 76b37a4d authored by maoying's avatar maoying

解决冲突

parents fad02218 060a9a98
...@@ -49,6 +49,9 @@ ...@@ -49,6 +49,9 @@
<foreach collection="buildingIds" item="buildingId" open="(" close=")" separator=","> <foreach collection="buildingIds" item="buildingId" open="(" close=")" separator=",">
#{buildingId} #{buildingId}
</foreach> </foreach>
</if>
<if test="buildingId != null and buildingId != -1 and buildingId != '-1'">
AND c.`building_id`= #{buildingId}
</if> </if>
<if test="fireEnduranceRate != null and fireEnduranceRate != ''"> <if test="fireEnduranceRate != null and fireEnduranceRate != ''">
AND c.`fire_endurance_rate`= #{fireEnduranceRate} AND c.`fire_endurance_rate`= #{fireEnduranceRate}
......
...@@ -101,4 +101,12 @@ public class EquipmentSpecificIndex extends BaseEntity { ...@@ -101,4 +101,12 @@ public class EquipmentSpecificIndex extends BaseEntity {
@TableField(exist = false) @TableField(exist = false)
private String valueEnum; private String valueEnum;
@ApiModelProperty(value = "设备CODE")
@TableField(exist = false)
private String equipmentSpecificCode;
@ApiModelProperty(value = "设备所属系统ids")
@TableField(exist = false)
private String systemId;
} }
...@@ -9,11 +9,14 @@ import lombok.Data; ...@@ -9,11 +9,14 @@ import lombok.Data;
@Data @Data
@ApiModel(description = "性能指标类") @ApiModel(description = "性能指标类")
public class SpeIndexVo { public class SpeIndexVo {
private String key;
private String name; private String key = "";
private String value;
private String name = "";
private String value = "";
private String typeCode; private String typeCode = "";
private Long equipmentSpecificId; private Long equipmentSpecificId;
} }
...@@ -547,7 +547,18 @@ public class FireFightingSystemController extends AbstractBaseController { ...@@ -547,7 +547,18 @@ public class FireFightingSystemController extends AbstractBaseController {
/** /**
* 设备报警信息 * 获取点位图,区域树数据
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(value = "获取点位图,区域树数据", notes = "消防系统点位图使用")
@GetMapping(value = "/point/tree")
public List<PointTreeVo> getPointTree(@RequestParam(required = false) String systemId) {
return fireFightingSystemService.getPointTree(systemId, getOrgCode());
}
/**
* 设备指标数据查询
* *
* @param id * @param id
* @return * @return
......
...@@ -55,7 +55,9 @@ ...@@ -55,7 +55,9 @@
wesi.update_date AS updateDate, wesi.update_date AS updateDate,
ed.code AS equipmentCode, ed.code AS equipmentCode,
ed.equipment_id AS equipmentId, ed.equipment_id AS equipmentId,
ed.id AS equipmentDetailId ed.id AS equipmentDetailId,
wes.code as equipmentSpecificCode,
wes.system_id as systemId
FROM FROM
wl_equipment_specific_index AS wesi wl_equipment_specific_index AS wesi
LEFT JOIN wl_equipment_specific AS wes ON wes.id = wesi.equipment_specific_id LEFT JOIN wl_equipment_specific AS wes ON wes.id = wesi.equipment_specific_id
......
...@@ -334,21 +334,53 @@ ...@@ -334,21 +334,53 @@
p_point p p_point p
</select> </select>
<select id="getSpeIndex" resultType="com.yeejoin.equipmanage.common.vo.SpeIndexVo"> <select id="getSpeIndex" resultType="com.yeejoin.equipmanage.common.vo.SpeIndexVo">
select * from ( SELECT
select *
eqin.name_key as `key`, FROM
eqin.name as name, (
eqin.type_code, SELECT
spein.update_date as updateDate, eqin.name_key AS `key`,
if (eqin.unit is null, spein.value,concat(spein.value,eqin.unit)) as value eqin.`name` AS `name`,
from eqin.type_code,
wl_equipment_specific_index as spein spein.update_date AS updateDate,
left join wl_equipment_index as eqin on spein.equipment_index_id = eqin.id spein.equipment_specific_id as equipmentSpecificId,
where IF (
spein.equipment_specific_id = #{id} eqin.unit IS NULL,
order by eqin.sort_num) as dat IF (
where `key` is not null and `key` != '' (
ORDER BY dat.updateDate DESC ISNULL(spein.value_label)
OR spein.value_label = ''
),
spein.`value`,
spein.value_label
),
concat(
IF (
(
ISNULL(spein.value_label)
OR spein.value_label = ''
),
spein.`value`,
spein.value_label
),
' ',
eqin.unit
)
) AS `value`
FROM
wl_equipment_specific_index AS spein
LEFT JOIN wl_equipment_index AS eqin ON spein.equipment_index_id = eqin.id
WHERE
spein.equipment_specific_id = #{id}
ORDER BY
eqin.sort_num
) AS dat
WHERE
`key` IS NOT NULL
AND `key` != ''
ORDER BY
dat.updateDate DESC
</select> </select>
<select id="getSpeIndexIn" resultType="com.yeejoin.equipmanage.common.vo.SpeIndexVo"> <select id="getSpeIndexIn" resultType="com.yeejoin.equipmanage.common.vo.SpeIndexVo">
select * from ( select * from (
......
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