From 090412a5759ff51b41bd9b68137205f7ab5c043c Mon Sep 17 00:00:00 2001 From: Charles7c Date: Sun, 16 Nov 2025 20:52:47 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20=E4=BC=98=E5=8C=96=E9=83=A8=E5=88=86?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=E6=A0=BC=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../admin/generator/service/impl/GeneratorServiceImpl.java | 3 ++- .../continew/admin/system/service/impl/OptionServiceImpl.java | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/continew-plugin/continew-plugin-generator/src/main/java/top/continew/admin/generator/service/impl/GeneratorServiceImpl.java b/continew-plugin/continew-plugin-generator/src/main/java/top/continew/admin/generator/service/impl/GeneratorServiceImpl.java index 1306de0a..a2115502 100644 --- a/continew-plugin/continew-plugin-generator/src/main/java/top/continew/admin/generator/service/impl/GeneratorServiceImpl.java +++ b/continew-plugin/continew-plugin-generator/src/main/java/top/continew/admin/generator/service/impl/GeneratorServiceImpl.java @@ -158,7 +158,8 @@ public class GeneratorServiceImpl implements GeneratorService { Set>> typeMappingEntrySet = typeMappingMap.entrySet(); // 新增或更新字段配置 Map fieldConfigMap = fieldConfigList.stream() - .collect(Collectors.toMap(FieldConfigDO::getColumnName, Function.identity(), (key1, key2) -> key2)); + .collect(Collectors.toMap(FieldConfigDO::getColumnName, Function.identity(), (existing, + replacement) -> existing)); int i = 1; for (Column column : columnList) { FieldConfigDO fieldConfig = Optional.ofNullable(fieldConfigMap.get(column.getName())) diff --git a/continew-system/src/main/java/top/continew/admin/system/service/impl/OptionServiceImpl.java b/continew-system/src/main/java/top/continew/admin/system/service/impl/OptionServiceImpl.java index c81a7f39..9bcf223d 100644 --- a/continew-system/src/main/java/top/continew/admin/system/service/impl/OptionServiceImpl.java +++ b/continew-system/src/main/java/top/continew/admin/system/service/impl/OptionServiceImpl.java @@ -70,7 +70,7 @@ public class OptionServiceImpl implements OptionService { return baseMapper.selectByCategory(category.name()) .stream() .collect(Collectors.toMap(OptionDO::getCode, o -> StrUtil.emptyIfNull(ObjectUtil.defaultIfNull(o - .getValue(), o.getDefaultValue())), (oldVal, newVal) -> oldVal)); + .getValue(), o.getDefaultValue())), (existing, replacement) -> existing)); } @Override @@ -91,7 +91,7 @@ public class OptionServiceImpl implements OptionService { Map passwordPolicyOptionMap = options.stream() .filter(option -> StrUtil.startWith(option.getCode(), PasswordPolicyEnum.CATEGORY .name() + StringConstants.UNDERLINE)) - .collect(Collectors.toMap(OptionReq::getCode, OptionReq::getValue, (oldVal, newVal) -> oldVal)); + .collect(Collectors.toMap(OptionReq::getCode, OptionReq::getValue, (existing, replacement) -> existing)); for (Map.Entry passwordPolicyOptionEntry : passwordPolicyOptionMap.entrySet()) { String code = passwordPolicyOptionEntry.getKey(); String value = passwordPolicyOptionEntry.getValue();