|
@@ -230,12 +230,11 @@ public class ConfigService {
|
|
|
|
|
|
List<ConfigVO> list = configMapper.checkConfigName(configPO);
|
|
|
if (ObjectUtil.isNotNull(list)) {
|
|
|
- String configId = list.get(0).getId();
|
|
|
+
|
|
|
configPO.setModifyUserId(currentUserId);
|
|
|
configPO.setModifyTime(currentTime);
|
|
|
configPO.setIsDeleted(DictConstants.NO);
|
|
|
configMapper.updateConfig(configPO);
|
|
|
- relationConfigSensorMapper.deleteByConfigId(configId);
|
|
|
LogUtil.update();
|
|
|
} else {
|
|
|
configPO.setCreateUserId(currentUserId);
|
|
@@ -332,6 +331,7 @@ public class ConfigService {
|
|
|
});
|
|
|
}
|
|
|
if (ObjectUtil.isNotNull(configSensorPOs)) {
|
|
|
+ relationConfigSensorMapper.deleteByConfigId(configPO.getId());
|
|
|
configMapper.insertConfigSensors(configSensorPOs);
|
|
|
}
|
|
|
return configPO;
|