魏熙美 6 年之前
父節點
當前提交
c4c921fd53

+ 2
- 2
CODE/smart-community/app-api/src/main/java/com/community/huiju/service/impl/MonitoringServiceImpl.java 查看文件

218
             queryMap.put("appKey", tpEquipment.getAppkey());
218
             queryMap.put("appKey", tpEquipment.getAppkey());
219
             queryMap.put("appSecret", tpEquipment.getSecret());
219
             queryMap.put("appSecret", tpEquipment.getSecret());
220
             try {
220
             try {
221
-                String result = OkHttpRequestUtils.doGet(yinShiProperties.getVideoTokenUrl(), queryMap);
222
-                JSONObject jsonObject = JSONObject.parseObject(result);
221
+                String result = OkHttpRequestUtils.doPost(yinShiProperties.getVideoTokenUrl(), queryMap);
222
+                JSONObject jsonObject = JSONObject.parseObject(result).getJSONObject("data");
223
                 tpEquipment.setOpUserUuid(jsonObject.getString("accessToken"));
223
                 tpEquipment.setOpUserUuid(jsonObject.getString("accessToken"));
224
                 tpEquipment.setUnitUuids(String.valueOf(jsonObject.getLong("expireTime")));
224
                 tpEquipment.setUnitUuids(String.valueOf(jsonObject.getLong("expireTime")));
225
                 tpEquipmentMapper.updateByPrimaryKeySelective(tpEquipment);
225
                 tpEquipmentMapper.updateByPrimaryKeySelective(tpEquipment);