From 78fbce0ccb37e2c802a8ebf49b5bc2ef2a0d9691 Mon Sep 17 00:00:00 2001 From: zhc077 <565291854> Date: Thu, 23 Nov 2023 16:51:53 +0800 Subject: [PATCH] =?UTF-8?q?1=E3=80=81=E5=B9=B4=E5=BA=A6=E7=A7=AF=E5=88=86?= =?UTF-8?q?=E9=97=AE=E9=A2=98=E4=BF=AE=E6=94=B9=2011.23?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...alAbilityEvaluationCollectServiceImpl.java | 4 +- .../PersonalAbilityEvaluationServiceImpl.java | 4 +- .../entity/AnnualCompPoint.java | 272 +++++++++++------- .../entity/PersonalCompTotalScore.java | 81 ++++-- .../impl/PersonalCompScoreServiceImpl.java | 22 +- .../committee/AnnualCompPoint.data.ts | 2 + .../PersonalCompScore.data.ts | 59 ++-- .../PersonalCompTotalScore.data.ts | 88 +++--- 8 files changed, 313 insertions(+), 219 deletions(-) diff --git a/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationCollectServiceImpl.java b/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationCollectServiceImpl.java index 357779dc..9ebdbf6c 100644 --- a/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationCollectServiceImpl.java +++ b/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationCollectServiceImpl.java @@ -73,7 +73,7 @@ public class PersonalAbilityEvaluationCollectServiceImpl extends ServiceImpl() // .eq(TeamManagement::getEnrollCode, enrollCode)); SysUser sysUser = iSysUserService.getOne(new LambdaQueryWrapper().eq(SysUser::getWorkNo, workNo)); - SysDepart sysDepart = iSysDepartService.getById(sysUser.getOrgCode()); +// SysDepart sysDepart = iSysDepartService.getDepartByOrgCode(sysUser.getOrgCode()); //每个学生同一类型能力指标分组查询 List evaluationList4User = iPersonalAbilityEvaluationService.list(new LambdaQueryWrapper() @@ -82,7 +82,7 @@ public class PersonalAbilityEvaluationCollectServiceImpl extends ServiceImpl()).stream().forEach(en -> { PersonalAbilityEvaluationCollect person = new PersonalAbilityEvaluationCollect(); person.setAnnualCompP(projectId); - person.setDepetId(sysDepart.getId()); + person.setDepetId(sysUser.getDepartIds()); person.setWorkOn(workNo); person.setName(sysUser.getRealname()); double sum = evaluationList4User.stream().mapToDouble(e -> e.getValue()).sum(); diff --git a/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationServiceImpl.java b/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationServiceImpl.java index 9aae2635..df11f183 100644 --- a/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationServiceImpl.java +++ b/jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationServiceImpl.java @@ -123,7 +123,7 @@ public class PersonalAbilityEvaluationServiceImpl extends ServiceImpl() .eq(TeamManagement::getEnrollCode, e.getEnrollCode())); SysUser sysUser = iSysUserService.getById(management.getUserId()); - SysDepart sysDepart = iSysDepartService.getById(sysUser.getOrgCode()); +// SysDepart sysDepart = iSysDepartService.getDepartByOrgCode(sysUser.getOrgCode()); //遍历每一类能力指标 compskillList.forEach(compskill -> { @@ -133,7 +133,7 @@ public class PersonalAbilityEvaluationServiceImpl extends ServiceImpl implements IPersonalCompScoreService { @Autowired @@ -98,22 +100,25 @@ public class PersonalCompScoreServiceImpl extends ServiceImpl saveList = new LinkedList<>(); if (!ObjectUtils.isEmpty(annualCompPoint)) { + //年度比赛项目 奖项设置 + AnnualCompAward annualCompAward = iAnnualCompAwardService.getOne(new LambdaQueryWrapper() + .eq(AnnualCompAward::getAnnucompid, annualCompPoint.getId())); + if (ObjectUtils.isEmpty(annualCompAward)) return; + //1、根据年度比赛项目id,查询获取管理(award_persion)列表,即参赛人员及获取奖项顺序号 List awardPersionList = iAwardPersionService.list(new LambdaQueryWrapper() .eq(AwardPersion::getAnnualCompP, annualCompPoint.getId())); - //2、遍历获奖理理(award_persion)列表,根据奖项id查询比赛奖项设置表(annual_comp_award) + //2、遍历获奖管理(award_persion)列表,根据奖项id查询比赛奖项设置表(annual_comp_award) Optional.ofNullable(awardPersionList).orElse(new LinkedList<>()).forEach(en -> { //2.1、比赛奖项设置 根据awardsort奖项顺序,获取对应的奖项权重值 //奖项顺序与奖项权重值映射关系: wardsort(1:first_weight,2:second_weight,3:third_weight,4:fourth_weight,5:fifth_weight - AnnualCompAward annualCompAward = iAnnualCompAwardService.getById(en.getId()); - if (ObjectUtils.isEmpty(annualCompAward)) return; //奖项权重值 百分比 String weightVal; switch (en.getAwardsort()) { case 1: - weightVal = annualCompAward.getFifthWeight(); + weightVal = annualCompAward.getFirstWeight(); break; case 2: weightVal = annualCompAward.getSecondWeight(); @@ -140,6 +145,7 @@ public class PersonalCompScoreServiceImpl extends ServiceImpl score = new AtomicReference<>((double) 0); if (StringUtils.equals("Y", entryForm)) { //团队赛 @@ -159,8 +165,8 @@ public class PersonalCompScoreServiceImpl extends ServiceImpl