Bläddra i källkod

26.本地自测”查获工作区域分布“接口;
27.本地自测”不安全事件物品分布“接口;
28.本地自测”不安全事件类型分布“接口;
29.本地自测”不安全事件岗位分布“接口;

sunpanhu 4 veckor sedan
förälder
incheckning
f7742d1479

+ 1 - 5
airport-ledger/src/main/java/com/sundot/airport/ledger/domain/vo/UnsafeTypeVO.java

@@ -13,14 +13,10 @@ import java.io.Serializable;
13 13
 @Data
14 14
 public class UnsafeTypeVO implements Serializable {
15 15
     /**
16
-     * 事件类型值(数据字典
16
+     * 事件类型值(存储的是中文
17 17
      */
18 18
     private String eventType;
19 19
     /**
20
-     * 事件类型名称(数据字典)
21
-     */
22
-    private String eventTypeName;
23
-    /**
24 20
      * 该类型不安全事件数量(饼图数值,统计条数)
25 21
      */
26 22
     private Integer eventTypeNum;

+ 1 - 18
airport-ledger/src/main/java/com/sundot/airport/ledger/service/impl/LedgerUnsafeEventServiceImpl.java

@@ -76,24 +76,7 @@ public class LedgerUnsafeEventServiceImpl extends ServiceImpl<LedgerUnsafeEventM
76 76
     @Override
77 77
     public List<UnsafeTypeVO> countSeizureStatsType(CountQueryReqVO countQueryReq) {
78 78
         List<UnsafeTypeVO> unsafeTypeList = this.baseMapper.countSeizureStatsType(countQueryReq);
79
-        if (CollUtil.isEmpty(unsafeTypeList)){
80
-            return Lists.newArrayList();
81
-        }
82
-
83
-        SysDictData dictData = new SysDictData();
84
-        dictData.setDictType("sys_unsafe_type");
85
-        dictData.setStatus("0");
86
-        List<SysDictData> sysDictData = dictDataService.selectDictDataList(dictData);
87
-        Map<String, SysDictData> trendDataMap = CollUtil.emptyIfNull(sysDictData).stream().collect(Collectors.toMap(SysDictData::getDictValue, dto -> dto));
88
-
89
-        unsafeTypeList.forEach(unsafeType -> {
90
-            SysDictData dict = trendDataMap.get(unsafeType.getEventType());
91
-            if (Objects.nonNull(dict)) {
92
-                unsafeType.setEventTypeName(dict.getDictLabel());
93
-            }
94
-        });
95
-
96
-        return unsafeTypeList;
79
+        return CollUtil.emptyIfNull(unsafeTypeList);
97 80
     }
98 81
 
99 82
     /**

+ 1 - 1
airport-ledger/src/main/resources/mapper/ledger/LedgerUnsafeEventMapper.xml

@@ -77,7 +77,7 @@
77 77
             AND event_type IS NOT NULL AND event_type != ''
78 78
         </where>
79 79
         GROUP BY event_type
80
-        ORDER BY typeNum DESC
80
+        ORDER BY eventTypeNum DESC
81 81
     </select>
82 82
 
83 83
     <select id="countSeizureStatsPost" parameterType="com.sundot.airport.ledger.domain.vo.CountQueryReqVO" resultType="com.sundot.airport.ledger.domain.vo.UnsafePositionVO">