体检项目重置名单控制按项目清空人员范围,再重新导入

This commit is contained in:
2026-04-09 11:41:48 +08:00
parent f1c3258ee4
commit 429f22f764
@@ -230,7 +230,9 @@ public class HealthCheckupProjectMangeController {
List<String> userSelectionIds = list.stream().map(v -> v.getString("id")).collect(Collectors.toList());
List<String> userIds = list.stream().map(v -> v.getString("selectUserId")).collect(Collectors.toList());
healthCheckupProjectService.dao().clear(HealthCheckupUserSelection.class, Cnd.where("selectUserId", "in", userIds));
healthCheckupProjectService.dao().clear(HealthCheckupUserSelection.class,
Cnd.NEW().and("selectUserId", "in", userIds)
.and("projectId", "=", healthCheckupProject.getId()));
healthCheckupProjectService.dao().clear(HealthCheckupUserCompanion.class, Cnd.where("userSelectionId", "in", userSelectionIds));
healthCheckupProjectService.dao().clear(HealthCheckupUser.class, Cnd.where("projectId", "=", healthCheckupProject.getId()));
healthCheckupProjectService.addHealthCheckupUser(healthCheckupProject);