张延森 преди 2 години
родител
ревизия
9ce6d05e8e
променени са 1 файла, в които са добавени 6 реда и са изтрити 2 реда
  1. 6
    2
      src/main/java/com/yunzhi/nanyang/controller/TaMachineryController.java

+ 6
- 2
src/main/java/com/yunzhi/nanyang/controller/TaMachineryController.java Целия файл

@@ -276,8 +276,12 @@ public class TaMachineryController extends BaseController {
276 276
         DeviceSummary deviceSummary = JSONObject.parseObject(tdDevice.getApiConfig(), DeviceSummary.class);
277 277
         TdHatcDevice hatcDevice = iTdHatcDeviceService.getById(deviceSummary.getDeviceId());
278 278
 
279
-        if (hatcDevice == null || null == hatcDevice.getDeviceStatus() || hatcDevice.getDeviceStatus() != 1) {
280
-            return ResponseBean.error("车辆设备离线");
279
+//        if (hatcDevice == null || null == hatcDevice.getDeviceStatus() || hatcDevice.getDeviceStatus() != 1) {
280
+//            return ResponseBean.error("车辆设备离线");
281
+//        }
282
+
283
+        if (hatcDevice == null) {
284
+            return ResponseBean.error("未同步设备");
281 285
         }
282 286
 
283 287
         String url = String.format("%s/preview?terminalID=%s&productKey=%s&channelNo=%d&netType=%d",