编辑portal系统参数时,如果不刷新页面,配置出现覆盖,不是新增

parent 7545bd3c
......@@ -44,6 +44,7 @@ public class ServerConfigController {
if (Objects.isNull(storedConfig)) {//create
serverConfig.setDataChangeCreatedBy(modifiedBy);
serverConfig.setDataChangeLastModifiedBy(modifiedBy);
serverConfig.setId(0L);//为空,设置ID 为0,jpa执行新增操作
return serverConfigRepository.save(serverConfig);
} else {//update
BeanUtils.copyEntityProperties(serverConfig, storedConfig);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment