fix(oa):修复奖金池服务中进度负责人收集逻辑

- 移除多余的空行以优化代码格式- 在收集进度ID时增加对null值的过滤
-修复进度步骤负责人昵称过滤逻辑,确保过滤null和空字符串- 保证进度负责人收集的准确性和完整性
This commit is contained in:
2025-10-24 16:05:59 +08:00
parent 74cd7dda48
commit 8fbc1f5aa2

View File

@@ -181,7 +181,6 @@ public class OaBonusPoolServiceImpl implements IOaBonusPoolService {
.eq(OaProjectSchedule::getDelFlag, "0")
.select(OaProjectSchedule::getScheduleId)
);
// 收集进度负责人oa_project_schedule_step.header
if (CollUtil.isEmpty(schedules)) {
Log.warn("项目ID对应的进度主表记录为空仅收集项目负责人");
@@ -189,6 +188,7 @@ public class OaBonusPoolServiceImpl implements IOaBonusPoolService {
List<Long> scheduleIds = schedules.stream()
.filter(Objects::nonNull) // 过滤null进度对象
.map(OaProjectSchedule::getScheduleId)
.filter(Objects::nonNull) // 再过滤null的scheduleId
.collect(Collectors.toList());
List<OaProjectScheduleStep> scheduleSteps = projectScheduleStepMapper.selectList(
@@ -200,7 +200,7 @@ public class OaBonusPoolServiceImpl implements IOaBonusPoolService {
scheduleSteps.stream()
.filter(Objects::nonNull) // 过滤null步骤对象
.map(OaProjectScheduleStep::getHeader)
.filter(StrUtil::isNotBlank) // 过滤空昵称
.filter(StrUtil::isNotBlank) // 过滤null/空字符串的header
.forEach(allNickNames::add); // Set自动去重
}