禅道#1001、#1006问题修复

This commit is contained in:
gaoqr
2025-01-16 15:14:51 +08:00
parent eca15a1d13
commit e0f70a0ef4
3 changed files with 13 additions and 1 deletions
@@ -4,6 +4,7 @@ import com.cf.imes.framework.common.pojo.PageParam;
import com.cf.imes.module.system.validation.common.CommonStatus;
import com.cf.imes.module.system.validation.config.SystemConfigTypeEnumValid;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Builder;
import lombok.Data;
import lombok.EqualsAndHashCode;
@@ -18,6 +19,7 @@ import javax.validation.constraints.Size;
@Schema(description = "管理后台 - 系统配置分页 Request VO")
@Data
@EqualsAndHashCode(callSuper = true)
@Builder
public class ConfigPageReqVO extends PageParam {
@Schema(description = "配置项名称", example = "晨丰")
@@ -30,13 +30,18 @@ public class DefaultSystemConfigServiceHandler extends AbstractSystemConfigServi
@Resource
private SystemConfigMapper systemConfigMapper;
@Resource
private CustomPlateNoServiceHandler customPlateNoServiceHandler;
@Override
public List<SystemConfigDO> selectList(ConfigPageReqVO reqVO) {
// 查询所有的 SystemConfigTypeEnum 类型
List<SystemConfigTypeEnum> allConfigTypes = Arrays.asList(SystemConfigTypeEnum.values());
List<SystemConfigTypeEnum> list = allConfigTypes.stream().filter(f -> !f.getType().equals(3)).toList();
// 自定义板编号、高级筛选不走通用分页查询
List<SystemConfigTypeEnum> list = allConfigTypes.stream()
.filter(f -> ObjectUtil.notEqual(SystemConfigTypeEnum.ADVANCED_SCREEN.getType(), f.getType()) && ObjectUtil.notEqual(SystemConfigTypeEnum.CUSTOM_PLATE_NO.getType(), f.getType())).toList();
List<SystemConfigDO> systemConfigDOS = systemConfigMapper.selectList(new LambdaQueryWrapperX<SystemConfigDO>()
.likeIfPresent(SystemConfigDO::getName, reqVO.getName())
@@ -88,6 +93,9 @@ public class DefaultSystemConfigServiceHandler extends AbstractSystemConfigServi
}
}
// 增加自定义板编号配置
List<SystemConfigDO> customPlateNoConfigList = customPlateNoServiceHandler.selectList(ConfigPageReqVO.builder().type(SystemConfigTypeEnum.CUSTOM_PLATE_NO.getType()).build());
resultList.addAll(0, customPlateNoConfigList);
return resultList;
}
@@ -305,6 +305,8 @@ public class AdminUserServiceImpl implements AdminUserService {
// 更新密码
AdminUserDO updateObj = new AdminUserDO();
updateObj.setId(id);
// 校验密码
validatePassword(password);
updateObj.setPassword(encodePassword(password)); // 加密密码
userMapper.updateById(updateObj);
}