Sfoglia il codice sorgente

大苏接口 监控数据

魏熙美 6 anni fa
parent
commit
6620338318

+ 4
- 2
CODE/foreign-service/src/main/java/com/community/huiju/common/sign/DaSuSign.java Vedi File

@@ -78,9 +78,11 @@ public class DaSuSign {
78 78
         System.out.println(timeMillis);
79 79
         TreeMap<String, Object> treeMap = new TreeMap<>();
80 80
         treeMap.put("appid", "dssdw2576sd997");
81
-        treeMap.put("datetime","1560223595398");
81
+        treeMap.put("datetime",timeMillis);
82 82
         treeMap.put("encrypt", "md5");
83
-        treeMap.put("communityId", "107");
83
+        //treeMap.put("communityId", "107");
84
+        treeMap.put("pageNo", 1);
85
+        treeMap.put("pageSize", 10);
84 86
         //treeMap.put("carNo","苏A90GM7");
85 87
         String sign = createSign(treeMap, "fgexhd855sf4");
86 88
     }

+ 1
- 1
CODE/foreign-service/src/main/java/com/community/huiju/dao/TpEquipmentMapper.java Vedi File

@@ -28,7 +28,7 @@ public interface TpEquipmentMapper extends BaseMapper<TpEquipment> {
28 28
     @ResultType(TpEquipment.class)
29 29
     @Select("select " +
30 30
             "tm.*, " +
31
-            "(select `key` FROM tp_configuration WHERE id = tm.url_id) as monitoringUrl, " +
31
+            "(select configuration_value FROM tp_configuration WHERE id = tm.url_id) as monitoringUrl, " +
32 32
             "(select configuration_value FROM tp_configuration WHERE id = tm.security_guard_tel_id) as securityGuardTel, " +
33 33
             "(select configuration_value FROM tp_configuration WHERE id = tm.security_room_tel_id) as securityRoomTel, " +
34 34
             "(select configuration_value FROM tp_configuration WHERE id = tm.address_id) as monitoringAddress " +

+ 4
- 1
CODE/foreign-service/src/main/java/com/community/huiju/service/impl/TpEquipmentServiceImpl.java Vedi File

@@ -13,6 +13,7 @@ import org.springframework.stereotype.Service;
13 13
 
14 14
 import java.util.List;
15 15
 import java.util.Map;
16
+import java.util.stream.Collectors;
16 17
 
17 18
 /**
18 19
  * <p>
@@ -35,12 +36,14 @@ public class TpEquipmentServiceImpl extends ServiceImpl<TpEquipmentMapper, TpEqu
35 36
         page.setCurrent(pageNum);
36 37
         page.setSize(pageSize);
37 38
         IPage<TpEquipment> equipmentIPage = tpEquipmentMapper.selectMonitoringByCommunityId(page,communityId);
39
+        List<TpEquipment> records = equipmentIPage.getRecords();
40
+        records = records.stream().filter(e-> e.getMonitoringUrl().contains("m3u8")).collect(Collectors.toList());
38 41
 
39 42
         Map<String, Object> map = Maps.newHashMap();
40 43
         map.put("pageNum", equipmentIPage.getCurrent());
41 44
         map.put("pageSize", equipmentIPage.getSize());
42 45
         map.put("total", equipmentIPage.getTotal());
43
-        map.put("list", equipmentIPage.getRecords());
46
+        map.put("list", records);
44 47
         responseBean.addSuccess(map);
45 48
         return responseBean;
46 49
     }