fix: 【IoT 物联网】修复 IotDeviceServiceImpl 中的更新支持逻辑,确保在不支持更新时抛出异常

This commit is contained in:
haohao
2025-12-06 12:38:07 +08:00
parent 68437cd830
commit ca014bdba5

View File

@@ -382,7 +382,7 @@ public class IotDeviceServiceImpl implements IotDeviceService {
return; return;
} }
// 2.2.2 如果存在,判断是否允许更新 // 2.2.2 如果存在,判断是否允许更新
if (updateSupport) { if (!updateSupport) {
throw exception(DEVICE_KEY_EXISTS); throw exception(DEVICE_KEY_EXISTS);
} }
updateDevice(new IotDeviceSaveReqVO().setId(existDevice.getId()) updateDevice(new IotDeviceSaveReqVO().setId(existDevice.getId())