lin %!s(int64=3) %!d(string=hai) anos
pai
achega
486eb18092

+ 2 - 2
zoniot-rmcp/zoniot-rmcp-web/src/main/java/com/zcxk/rmcp/web/service/impl/DeviceServiceImpl.java

@@ -635,8 +635,8 @@ public class DeviceServiceImpl implements DeviceService{
         }
         if (syncDeviceService.updateDeviceStatus(device.getIotDeviceId(), state) > 0){
             Device DeviceUpdate = new Device();
-            device.setId(deviceId);
-            device.setDeviceStatus(state);
+            DeviceUpdate.setId(deviceId);
+            DeviceUpdate.setDeviceStatus(state);
             updateByPrimaryKeySelective(DeviceUpdate);
             return;
         }