Commit 83eb8fc095ac48a396e759d545083665a4f9474b

Authored by 云中非
1 parent 744d890d

fix: 编辑设备客户信息丢失问题修复

@@ -468,8 +468,10 @@ public class TkDeviceController extends BaseController { @@ -468,8 +468,10 @@ public class TkDeviceController extends BaseController {
468 DeviceProfileId deviceProfileId = 468 DeviceProfileId deviceProfileId =
469 new DeviceProfileId(UUID.fromString(deviceDTO.getProfileId())); 469 new DeviceProfileId(UUID.fromString(deviceDTO.getProfileId()));
470 470
  471 + CustomerId customerId = StringUtils.isBlank(deviceDTO.getCustomerId())?null:new CustomerId(UUID.fromString(deviceDTO.getCustomerId()));
  472 +
471 tbDevice.setAdditionalInfo(additionalInfo); 473 tbDevice.setAdditionalInfo(additionalInfo);
472 - tbDevice.setCustomerId(null); 474 + tbDevice.setCustomerId(customerId);
473 tbDevice.setDeviceProfileId(deviceProfileId); 475 tbDevice.setDeviceProfileId(deviceProfileId);
474 tbDevice.setLabel(deviceDTO.getLabel()); 476 tbDevice.setLabel(deviceDTO.getLabel());
475 tbDevice.setName(deviceDTO.getName()); 477 tbDevice.setName(deviceDTO.getName());