瀏覽代碼

fix 统计接口查询sql修复

A17404李放 3 年之前
父節點
當前提交
302b3d8991

+ 2 - 2
nb-system/src/main/java/com/nb/bus/service/dto/CombineQuery.java

@@ -134,10 +134,10 @@ public class CombineQuery {
     @NotNull(message = "分页参数不可为空")
     private Page<CombineResult> page;
 
-    @ApiModelProperty(value = "设备运行状态",hidden = true)
+    @ApiModelProperty(value = "设备运行状态")
     private Integer deviceRunState;
 
-    @ApiModelProperty(value = "设备报警状态",hidden = true)
+    @ApiModelProperty(value = "设备报警状态")
     private Integer deviceAlarm;
 
     @ApiModelProperty("按照输注开始时间排序")

+ 8 - 23
nb-system/src/main/java/com/nb/bus/stats/entity/AlarmTotalPieResult.java

@@ -21,27 +21,6 @@ import java.util.HashMap;
  */
 @EqualsAndHashCode(callSuper = true)
 public class AlarmTotalPieResult extends HashMap<String,PieContent> {
-    @ApiModelProperty(value = "堵塞报警")
-    private PieContent jam;
-    @ApiModelProperty(value = "极限报警")
-    private PieContent limit;
-    @ApiModelProperty(value = "未装药盒报警")
-    private PieContent noBox;
-    @ApiModelProperty(value = "电机失控报警")
-    private PieContent outOfControl;
-    @ApiModelProperty(value = "镇痛不足报警")
-    private PieContent analgesicPoor;
-    @ApiModelProperty(value = "不在服务区报警")
-    private PieContent noSignal;
-    @ApiModelProperty(value = "机械故障报警")
-    private PieContent machine;
-    @ApiModelProperty(value = "电量耗尽报警")
-    private PieContent lowBattery;
-    @ApiModelProperty(value = "气泡无液报警")
-    private PieContent bubble;
-    @ApiModelProperty(value = "低输注状态")
-    private PieContent lowInfusion;
-
     @ApiModelProperty(value = "该报警集总数")
     @Getter
     private long total=0;
@@ -149,8 +128,14 @@ public class AlarmTotalPieResult extends HashMap<String,PieContent> {
         ++total;
     }
 
-
-
+    public AlarmTotalPieResult() {
+        getJam();
+        getLimit();
+        getNoBox();
+        getMachine();
+        getOutOfControl();
+        getLowBattery();
+    }
 
     public void handle(CombineAlarmResult alarmResult) {
         if (Boolean.TRUE.equals(alarmResult.getIsAlarm())) {

+ 1 - 1
nb-system/src/main/resources/mapper/bus/BusInfusionHistoryMapper.xml

@@ -323,7 +323,7 @@
                 </if>
             </if>
             <if test="query.deviceType != null">
-                and device_type =  #{query.deviceType}
+                and type =  #{query.deviceType}
             </if>
             <if test="query.deviceId != null">
                 and device_id like concat('%',#{query.deviceId},'%')