Commit 5d6e11d8 authored by litengwei's avatar litengwei

代码提交

parent dc51e9f2
......@@ -294,4 +294,8 @@ public interface EquipmentSpecificMapper extends BaseMapper<EquipmentSpecific> {
IPage<EquipTypeImgAmountVO> getMonitoringUnitList(@Param("page") IPage page,@Param("equipTypeAmountPage") EquipTypeAmountPageDTO equipTypeAmountPage);
List<Map<String, Object >> getMonitoringCount(String bizOrgCode);
String getMonitoringEquip(String id);
String getMonitoringOther(String id);
}
......@@ -2149,6 +2149,11 @@ public class EquipmentSpecificSerivceImpl extends ServiceImpl<EquipmentSpecificM
@Override
public IPage<EquipTypeImgAmountVO> getMonitoringUnitList(EquipTypeAmountPageDTO equipTypeAmountPage) {
IPage<EquipTypeImgAmountVO> record = equipmentSpecificMapper.getMonitoringUnitList(equipTypeAmountPage.getPage(),equipTypeAmountPage);
record.getRecords().forEach(e-> {
e.setEquip(equipmentSpecificMapper.getMonitoringEquip(String.valueOf(e.getId())));
e.setOther(equipmentSpecificMapper.getMonitoringOther(String.valueOf(e.getId())));
});
return equipmentSpecificMapper.getMonitoringUnitList(equipTypeAmountPage.getPage(),equipTypeAmountPage);
}
......
......@@ -2601,9 +2601,7 @@
wes.biz_org_name as bizOrgName,
wes.name as equipmentName,
wed.equipment_name systemType,
wes.equip_status AS equipStatus,
(SELECT IFNULL(SUM(IF(aqr.SOURCE = 'equip', 1, 0)), 0) FROM dl_amos_idx_biz.idx_access_qrcode_record aqr WHERE aqr.buss_id = wes.id ) as 'equip',
(SELECT IFNULL(SUM(IF(aqr.SOURCE != 'equip', 1, 0)), 0) FROM dl_amos_idx_biz.idx_access_qrcode_record aqr WHERE aqr.buss_id = wes.id ) as 'other'
wes.equip_status AS equipStatus
FROM
wl_equipment_specific wes
LEFT JOIN wl_equipment_detail wed ON wed.id = wes.equipment_detail_id
......@@ -2635,4 +2633,11 @@
GROUP BY code
</select>
<select id="getMonitoringEquip" resultType="java.lang.String">
SELECT IFNULL(SUM(IF(aqr.SOURCE = 'equip', 1, 0)), 0) as num FROM dl_amos_idx_biz.idx_access_qrcode_record aqr WHERE aqr.buss_id = #{id}
</select>
<select id="getMonitoringOther" resultType="java.lang.String">
SELECT IFNULL(SUM(IF(aqr.SOURCE != 'equip', 1, 0)), 0) as num FROM dl_amos_idx_biz.idx_access_qrcode_record aqr WHERE aqr.buss_id = #{id}
</select>
</mapper>
\ 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