From 8ba5282f1eda35edc66fabbd2c1e0d9ccbe400f3 Mon Sep 17 00:00:00 2001 From: zhouwentao <1577701412@qq.com> Date: Sat, 28 Jun 2025 15:56:08 +0800 Subject: [PATCH] updates --- .../service/impl/YxVolunteerServiceImpl.java | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/yx/service/impl/YxVolunteerServiceImpl.java b/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/yx/service/impl/YxVolunteerServiceImpl.java index 06c46c5..9e4d896 100644 --- a/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/yx/service/impl/YxVolunteerServiceImpl.java +++ b/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/yx/service/impl/YxVolunteerServiceImpl.java @@ -423,6 +423,15 @@ public class YxVolunteerServiceImpl extends ServiceImpl volunteerRecordEarlyAdmissionList = activeByCreateVolunteerDto.getVolunteerRecordEarlyAdmissionList(); + List volunteerRecordUndergraduateAList = activeByCreateVolunteerDto.getVolunteerRecordUndergraduateAList(); + List volunteerRecordUndergraduateBList = activeByCreateVolunteerDto.getVolunteerRecordUndergraduateBList(); + List volunteerRecordUndergraduateList = activeByCreateVolunteerDto.getVolunteerRecordUndergraduateList(); + // 将本科批合并 + volunteerRecordUndergraduateList.addAll(volunteerRecordUndergraduateAList); + volunteerRecordUndergraduateList.addAll(volunteerRecordUndergraduateBList); + volunteerRecordUndergraduateList.addAll(volunteerRecordEarlyAdmissionList); String volunteerId = activeByCreateVolunteerDto.getId(); YxCalculationMajor calculationMajor = null; for (YxVolunteerRecord yxVolunteerRecord : volunteerRecordList) { @@ -437,6 +446,17 @@ public class YxVolunteerServiceImpl extends ServiceImplp.getIndexs().equals(yxVolunteerRecord.getIndexs())).findAny().isPresent()) { + throw new JeecgBootException("保存失败,该志愿顺序已填报!请重新登录账号尝试"); + } + }else{ + if (activeByCreateVolunteerDto.getVolunteerRecordJuniorCollegeList().stream().filter(p->p.getIndexs().equals(yxVolunteerRecord.getIndexs())).findAny().isPresent()) { + throw new JeecgBootException("保存失败,该志愿顺序已填报!请重新登录账号尝试"); + } + } yxVolunteerRecord.setCreateBy(loginUser.getId()); yxVolunteerRecord.setVolunteerId(volunteerId); yxVolunteerRecord.setBatch(calculationMajor.getBatch());