Browse Source

宁夏分停机事件参数异常处理

shilin 5 days ago
parent
commit
b6372da887

+ 4 - 1
alarm-web/src/main/java/com/gyee/alarm/mapper/auto/ProEconShutdownEvent2Mapper.java

@@ -35,6 +35,9 @@ public interface ProEconShutdownEvent2Mapper extends BaseMapper<ProEconShutdownE
             "<if test='modelId != null'>",
             "and  a.model_id=#{modelId}",
             "</if>",
+            "<if test='wtId != null'>",
+            "and  s.windturbine_id=#{wtId}",
+            "</if>",
             "<if test='type != null'>",
             "and  s.stop_type_id=#{type}",
             "</if>",
@@ -44,7 +47,7 @@ public interface ProEconShutdownEvent2Mapper extends BaseMapper<ProEconShutdownE
             "</where>",
 
             "</script>"})
-    List<ProEconShutdownEvent2> queryShutdownEvent(@Param("wpId") String wpId, @Param("modelId") String modelId,@Param("begin")Date begin, @Param("end") Date end, @Param("type") String type);
+    List<ProEconShutdownEvent2> queryShutdownEvent(@Param("wpId") String wpId, @Param("modelId") String modelId,@Param("begin")Date begin, @Param("end") Date end, @Param("type") String type, @Param("wtId") String wtId);
 
 
     @Select({"<script>",

+ 1 - 1
alarm-web/src/main/java/com/gyee/alarm/service/auto/impl/ProEconShutdownEvent2ServiceImpl.java

@@ -79,7 +79,7 @@ public class ProEconShutdownEvent2ServiceImpl extends ServiceImpl<ProEconShutdow
             try {
                 Date beginDate = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").parse(begin);
                 Date endDate = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").parse(end);
-                List<ProEconShutdownEvent2> ls=proEconShutdownEvent2Mapper.queryShutdownEvent( wpId, modelId, beginDate,  endDate,type);
+                List<ProEconShutdownEvent2> ls=proEconShutdownEvent2Mapper.queryShutdownEvent( wpId, modelId, beginDate,  endDate,type,wtId);
 
                 map.put("total",ls.size());
                 List<ProEconShutdownEvent2> vos = paginate(ls, pageNum, pageSize);