修改基础信息推送到省厅程序 添加了对国标编码设置值的功能
parent
6b5aa718d2
commit
7b3586d48c
|
|
@ -194,7 +194,11 @@ public class DeviceSyncService {
|
|||
|
||||
// 转换为目标设备
|
||||
Device targetDevice = FieldMapper.mapToTargetDevice(sourceDevice, deviceSyncConfig.getInfoSource());
|
||||
|
||||
if ("05".equals(targetDevice.getDeviceType()) && targetDevice.getDeviceCode().length()!=20){
|
||||
targetDevice.setGbbm(targetDevice.getRemark1());
|
||||
}else if ("05".equals(targetDevice.getDeviceType())){
|
||||
targetDevice.setGbbm(targetDevice.getDeviceCode());
|
||||
}
|
||||
if (existingDevice != null) {
|
||||
// 更新现有设备
|
||||
targetDevice.setId(existingDevice.getId());
|
||||
|
|
|
|||
Loading…
Reference in New Issue