Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -42,10 +42,6 @@ public class PmsMonitorBaseDTO implements Serializable {
|
||||
*/
|
||||
private String terminalId;
|
||||
|
||||
/***
|
||||
* 母线ID
|
||||
*/
|
||||
private String generatrixId;
|
||||
|
||||
/***
|
||||
* 监测线路名称
|
||||
|
||||
@@ -43,17 +43,17 @@
|
||||
|
||||
<select id="getDoubleUserByDept" resultType="DoubleUserVO">
|
||||
(
|
||||
select yong.name,yong.id,0 as type from pms_power_client yong
|
||||
inner join pms_distribution_monitor dis on yong.id = dis.Monitor_Id and dis.If_Power_User = 0
|
||||
where yong.org_id = #{orgId}
|
||||
and dis.status = 1
|
||||
select yong.name,yong.id,0 as type from pms_power_client yong
|
||||
inner join pms_distribution_monitor dis on yong.id = dis.Monitor_Id and dis.If_Power_User = 0
|
||||
where yong.org_id = #{orgId}
|
||||
and dis.status = 1
|
||||
)
|
||||
UNION ALL
|
||||
(
|
||||
select fa.name,fa.id,1 as type from pms_power_generation_user fa
|
||||
inner join pms_distribution_monitor dis on fa.id = dis.Monitor_Id and dis.If_Power_User = 1
|
||||
where fa.org_id = #{orgId}
|
||||
and dis.status = 1
|
||||
select fa.name,fa.id,1 as type from pms_power_generation_user fa
|
||||
inner join pms_distribution_monitor dis on fa.id = dis.Monitor_Id and dis.If_Power_User = 1
|
||||
where fa.org_id = #{orgId}
|
||||
and dis.status = 1
|
||||
)
|
||||
</select>
|
||||
|
||||
@@ -185,44 +185,49 @@
|
||||
<foreach collection="deptIds" item="item" open="(" close=")" separator=",">
|
||||
#{item}
|
||||
</foreach>
|
||||
) temp
|
||||
WHERE
|
||||
a.Monitor_Id = temp.id
|
||||
)
|
||||
</select>
|
||||
) temp
|
||||
WHERE
|
||||
a.Monitor_Id = temp.id
|
||||
)
|
||||
</select>
|
||||
<select id="statisticMonitor" resultType="com.njcn.device.pms.pojo.dto.PmsSimpleDTO">
|
||||
SELECT
|
||||
COUNT(pm.Id) AS statistics,
|
||||
pm.Voltage_Level AS name
|
||||
pm.Id,
|
||||
COUNT(pm.Id) AS statistics,
|
||||
pm.Voltage_Level AS name
|
||||
FROM pms_monitor pm
|
||||
WHERE pm.Id IN
|
||||
<foreach item="item" collection="list" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
GROUP BY pm.Voltage_Level
|
||||
<foreach item="item" collection="list" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
GROUP BY
|
||||
pm.Id,
|
||||
pm.Voltage_Level
|
||||
</select>
|
||||
<select id="statisticTerminal" resultType="com.njcn.device.pms.pojo.dto.PmsSimpleDTO">
|
||||
SELECT
|
||||
COUNT(t.Terminal_Id) as statistics,
|
||||
t.Voltage_Level as name
|
||||
FROM
|
||||
( SELECT
|
||||
DISTINCT pm.Terminal_Id,
|
||||
pm.Voltage_Level
|
||||
FROM pms_monitor pm
|
||||
WHERE pm.Terminal_Id IN
|
||||
<foreach item="item" collection="list" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
AND
|
||||
pm.Terminal_Id != ''
|
||||
) t
|
||||
COUNT(t.Terminal_Id) statistics,
|
||||
t.Voltage_Level name
|
||||
FROM
|
||||
( SELECT
|
||||
DISTINCT pm.Terminal_Id,
|
||||
pss.Voltage_Level
|
||||
FROM pms_monitor pm
|
||||
INNER JOIN pms_terminal pt on pt.Id=pm.Terminal_Id
|
||||
INNER JOIN pms_statation_stat pss on pss.Power_Id=pt.Power_Station_Id
|
||||
WHERE pm.Terminal_Id IN
|
||||
<foreach item="item" collection="list" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
AND
|
||||
pm.Terminal_Id != ''
|
||||
) t
|
||||
GROUP BY t.Voltage_Level
|
||||
</select>
|
||||
<select id="getOnlineRate" resultType="com.njcn.device.pms.pojo.dto.PmsSimpleDTO">
|
||||
SELECT
|
||||
pm.Voltage_Level name,
|
||||
IFNULL(SUM(rmded.dev_effective_rate),0) doubleValue
|
||||
pm.Voltage_Level name,
|
||||
IFNULL(SUM(rmded.dev_effective_rate),0) doubleValue
|
||||
FROM pms_monitor pm
|
||||
LEFT JOIN r_mp_dev_evaluate_detail rmded ON pm.Terminal_Id = rmded.device_id
|
||||
WHERE pm.Terminal_Id IN
|
||||
@@ -233,8 +238,8 @@
|
||||
</select>
|
||||
<select id="getIntegrity" resultType="com.njcn.device.pms.pojo.dto.PmsSimpleDTO">
|
||||
SELECT
|
||||
pm.Voltage_Level name,
|
||||
IFNULL(SUM(romd.data_integrity_rate),0) doubleValue
|
||||
pm.Voltage_Level name,
|
||||
IFNULL(SUM(romd.data_integrity_rate),0) doubleValue
|
||||
FROM pms_monitor pm
|
||||
LEFT JOIN r_operating_monitor_d romd ON pm.Id = romd.measurement_point_id
|
||||
WHERE pm.Id IN
|
||||
|
||||
Reference in New Issue
Block a user