significative 4 months ago
commit a41e7a495d
  1. 2
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationServiceImpl.java
  2. 29
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualCompPoint/controller/AnnualCompPointController.java
  3. 5
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualScore/service/impl/PersonalCompScoreServiceImpl.java
  4. 213
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualcompetitionprojectregistration/controller/AnnualCompetitionProjectRegistrationController.java
  5. 17
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualcompgroup/controller/AnnualCompGroupController.java
  6. 19
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/awardpersion/controller/AwardPersionController.java
  7. 15
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/scorepersion/controller/ScorePersionController.java
  8. 17
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/scoresta/controller/ScoreStaController.java

@ -127,7 +127,7 @@ public class PersonalAbilityEvaluationServiceImpl extends ServiceImpl<PersonalAb
person.setCapacityName(basicsskill.getName());
//计算能力量化各类指标 能力量化值 = 直接按项目的能力权值和项目奖项得分算
//能力量化值 = 项目得分*项目的能力权值/100
//能力量化值 = 个人积分*项目的能力权值/100
this.convertScore(compskill.getWeight(), person, en.getScore());
saveList.add(person);
});

@ -50,6 +50,8 @@ import org.jeecg.modules.demo.expscore.service.IExpScoreService;
import org.jeecg.modules.demo.score_management.entity.ScoreManagement;
import org.jeecg.modules.demo.scorepersion.entity.ScorePersion;
import org.jeecg.modules.demo.scorepersion.service.IScorePersionService;
import org.jeecg.modules.demo.upfile_persion.entity.UpfilePersion;
import org.jeecg.modules.demo.upfile_persion.service.IUpfilePersionService;
import org.jeecg.modules.system.entity.SysUser;
import org.jeecg.modules.system.service.ISysUserService;
import org.jeecgframework.poi.excel.ExcelImportUtil;
@ -124,6 +126,9 @@ public class AnnualCompPointController extends JeecgController<AnnualCompPoint,
@Resource
private JeecgBaseConfig jeecgBaseConfig;
@Autowired
private IUpfilePersionService upfilePersionService;
/**
* 分页列表查询
@ -412,6 +417,18 @@ public class AnnualCompPointController extends JeecgController<AnnualCompPoint,
}
annualCompPoint.setIsCjhz(1);
annualCompPointService.updateById(annualCompPoint);
//更新作品状态为已评分
for (int b = 0 ; b < list.size() ; b++){
UpfilePersion up = new UpfilePersion();
QueryWrapper<UpfilePersion> queryWrapperup = new QueryWrapper<>();
queryWrapperup.eq("apply_code",list.get(b).getBmcode());
List<UpfilePersion> listup = upfilePersionService.list(queryWrapperup);
if(listup.size()>0){
up = listup.get(0);
up.setStatus(1);
upfilePersionService.updateById(up);
}
}
return Result.OK("成功!");
}
/**
@ -484,6 +501,18 @@ public class AnnualCompPointController extends JeecgController<AnnualCompPoint,
}
annualCompPoint.setIsCjhz(1);
annualCompPointService.updateById(annualCompPoint);
//更新作品状态为已评分
for (int b = 0 ; b < list.size() ; b++){
UpfilePersion up = new UpfilePersion();
QueryWrapper<UpfilePersion> queryWrapperup = new QueryWrapper<>();
queryWrapperup.eq("apply_code",list.get(b).getBmcode());
List<UpfilePersion> listup = upfilePersionService.list(queryWrapperup);
if(listup.size()>0){
up = listup.get(0);
up.setStatus(1);
upfilePersionService.updateById(up);
}
}
return Result.OK("成功!");
}

@ -149,14 +149,15 @@ public class PersonalCompScoreServiceImpl extends ServiceImpl<PersonalCompScoreM
if (ObjectUtils.isEmpty(managementList)) return;
//modify 7.12 新需求
//3、计算积分 项目分值*项目级别权得百分比*获奖奖项权重百分比
//3、计算积分 项目分值*项目层次权得百分比*获奖奖项权重百分比
// log.info("***************年度比赛项目-{},项目分值:{},奖项权重值:{}", annualCompPoint.getObjName(), compweight_val, weightVal);
Projectlevel projectlevel = iProjectlevelService.getById(annualCompPoint.getObjLevel());
double scale_ratio = ComputeUtils.div2(new Double(projectlevel.getScale()), ONE_HUNDRED);
double baseScore = ComputeUtils.mul2(ComputeUtils.mul2(compweight_val, ComputeUtils.div2(new Double(weightVal), ONE_HUNDRED)),scale_ratio);
log.info("***************年度比赛项目-{},项目分值:{}", annualCompPoint.getObjName(), compweight_val);
log.info("***************年度比赛项目-级别权重比值:{}", scale_ratio);
log.info("***************年度比赛项目-层次权重比值:{}", scale_ratio);
log.info("***************获奖奖项权重百分比:{}", weightVal);
log.info("***************基础积分:{}", baseScore);
AtomicReference<Double> score = new AtomicReference<>((double) 0);
if (StringUtils.equals("Y", entryForm)) { //团队赛
Optional.ofNullable(managementList).orElse(new ArrayList<>()).forEach(e -> {

@ -143,8 +143,40 @@ public class AnnualCompetitionProjectRegistrationController {
//处理查询信息
QueryWrapper<AnnualCompetitionProjectRegistration> queryWrapper = QueryGenerator.initQueryWrapper(annualCompetitionProjectRegistration, req.getParameterMap());
Page<AnnualCompetitionProjectRegistration> page = new Page<AnnualCompetitionProjectRegistration>(pageNo, pageSize);
LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
//根据登录信息查询负责比赛
List<Comp> compList =compService.query().eq("comp_admin",loginUser.getUsername()).list();
//判空
if (compList.isEmpty()){
return Result.error("未绑定比赛");
}
//将比赛的id放进一个list里面
List<String> compIds = compList.stream()
.map(Comp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据比赛的id查询年度比赛id,这里没有去卡年度
List<AnnualComp> annualCompList = annualCompService.query().in("compid",compIds).list();
//判空
if (annualCompList.isEmpty()){
return Result.error("未创建年度比赛");
}
//将年度比赛id存放到一个list里面
List<String> anncompIds = annualCompList.stream()
.map(AnnualComp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
List<AnnualCompPoint> annualCompPointList = annualCompPointService.query().in("annual_comp_id", anncompIds).list();
//判空
if (annualCompPointList.isEmpty()){
return Result.error("未创建年度比赛项目");
}
//将年度比赛项目id存放到一个list里面
List<String> anncomppointIds = annualCompPointList.stream()
.map(AnnualCompPoint::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据用户角色决定查询信息
queryWrapperAddRoleInfo(queryWrapper);
queryWrapper.in("annual_compid",anncomppointIds);
/* queryWrapperAddRoleInfo(queryWrapper);*/
//查询
IPage<AnnualCompetitionProjectRegistration> pageList = annualCompetitionProjectRegistrationService.page(page, queryWrapper);
//处理返回信息
@ -163,8 +195,40 @@ public class AnnualCompetitionProjectRegistrationController {
//处理查询信息
QueryWrapper<AnnualCompetitionProjectRegistration> queryWrapper = QueryGenerator.initQueryWrapper(annualCompetitionProjectRegistration, req.getParameterMap());
Page<AnnualCompetitionProjectRegistration> page = new Page<AnnualCompetitionProjectRegistration>(pageNo, pageSize);
LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
//根据登录信息查询负责比赛
List<Comp> compList =compService.query().eq("comp_admin",loginUser.getUsername()).list();
//判空
if (compList.isEmpty()){
return Result.error("未绑定比赛");
}
//将比赛的id放进一个list里面
List<String> compIds = compList.stream()
.map(Comp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据比赛的id查询年度比赛id,这里没有去卡年度
List<AnnualComp> annualCompList = annualCompService.query().in("compid",compIds).list();
//判空
if (annualCompList.isEmpty()){
return Result.error("未创建年度比赛");
}
//将年度比赛id存放到一个list里面
List<String> anncompIds = annualCompList.stream()
.map(AnnualComp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
List<AnnualCompPoint> annualCompPointList = annualCompPointService.query().in("annual_comp_id", anncompIds).list();
//判空
if (annualCompPointList.isEmpty()){
return Result.error("未创建年度比赛项目");
}
//将年度比赛项目id存放到一个list里面
List<String> anncomppointIds = annualCompPointList.stream()
.map(AnnualCompPoint::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据用户角色决定查询信息
queryWrapperAddRoleInfo(queryWrapper);
queryWrapper.in("annual_compid",anncomppointIds);
/* queryWrapperAddRoleInfo(queryWrapper);*/
queryWrapper.eq("enroll_static", "2");
//查询
IPage<AnnualCompetitionProjectRegistration> pageList = annualCompetitionProjectRegistrationService.page(page, queryWrapper);
@ -184,8 +248,40 @@ public class AnnualCompetitionProjectRegistrationController {
//处理查询信息
QueryWrapper<AnnualCompetitionProjectRegistration> queryWrapper = QueryGenerator.initQueryWrapper(annualCompetitionProjectRegistration, req.getParameterMap());
Page<AnnualCompetitionProjectRegistration> page = new Page<AnnualCompetitionProjectRegistration>(pageNo, pageSize);
LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
//根据登录信息查询负责比赛
List<Comp> compList =compService.query().eq("comp_admin",loginUser.getUsername()).list();
//判空
if (compList.isEmpty()){
return Result.error("未绑定比赛");
}
//将比赛的id放进一个list里面
List<String> compIds = compList.stream()
.map(Comp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据比赛的id查询年度比赛id,这里没有去卡年度
List<AnnualComp> annualCompList = annualCompService.query().in("compid",compIds).list();
//判空
if (annualCompList.isEmpty()){
return Result.error("未创建年度比赛");
}
//将年度比赛id存放到一个list里面
List<String> anncompIds = annualCompList.stream()
.map(AnnualComp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
List<AnnualCompPoint> annualCompPointList = annualCompPointService.query().in("annual_comp_id", anncompIds).list();
//判空
if (annualCompPointList.isEmpty()){
return Result.error("未创建年度比赛项目");
}
//将年度比赛项目id存放到一个list里面
List<String> anncomppointIds = annualCompPointList.stream()
.map(AnnualCompPoint::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据用户角色决定查询信息
queryWrapperAddRoleInfo(queryWrapper);
queryWrapper.in("annual_compid",anncomppointIds);
/* queryWrapperAddRoleInfo(queryWrapper);*/
queryWrapper.eq("enroll_static", "4");
//查询
IPage<AnnualCompetitionProjectRegistration> pageList = annualCompetitionProjectRegistrationService.page(page, queryWrapper);
@ -206,8 +302,40 @@ public class AnnualCompetitionProjectRegistrationController {
//处理查询信息
QueryWrapper<AnnualCompetitionProjectRegistration> queryWrapper = QueryGenerator.initQueryWrapper(annualCompetitionProjectRegistration, req.getParameterMap());
Page<AnnualCompetitionProjectRegistration> page = new Page<AnnualCompetitionProjectRegistration>(pageNo, pageSize);
LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
//根据登录信息查询负责比赛
List<Comp> compList =compService.query().eq("comp_admin",loginUser.getUsername()).list();
//判空
if (compList.isEmpty()){
return Result.error("未绑定比赛");
}
//将比赛的id放进一个list里面
List<String> compIds = compList.stream()
.map(Comp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据比赛的id查询年度比赛id,这里没有去卡年度
List<AnnualComp> annualCompList = annualCompService.query().in("compid",compIds).list();
//判空
if (annualCompList.isEmpty()){
return Result.error("未创建年度比赛");
}
//将年度比赛id存放到一个list里面
List<String> anncompIds = annualCompList.stream()
.map(AnnualComp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
List<AnnualCompPoint> annualCompPointList = annualCompPointService.query().in("annual_comp_id", anncompIds).list();
//判空
if (annualCompPointList.isEmpty()){
return Result.error("未创建年度比赛项目");
}
//将年度比赛项目id存放到一个list里面
List<String> anncomppointIds = annualCompPointList.stream()
.map(AnnualCompPoint::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据用户角色决定查询信息
queryWrapperAddRoleInfo(queryWrapper);
queryWrapper.in("annual_compid",anncomppointIds);
/* queryWrapperAddRoleInfo(queryWrapper);*/
queryWrapper.eq("enroll_static", "1");
//查询
IPage<AnnualCompetitionProjectRegistration> pageList = annualCompetitionProjectRegistrationService.page(page, queryWrapper);
@ -227,8 +355,40 @@ public class AnnualCompetitionProjectRegistrationController {
//处理查询信息
QueryWrapper<AnnualCompetitionProjectRegistration> queryWrapper = QueryGenerator.initQueryWrapper(annualCompetitionProjectRegistration, req.getParameterMap());
Page<AnnualCompetitionProjectRegistration> page = new Page<AnnualCompetitionProjectRegistration>(pageNo, pageSize);
LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
//根据登录信息查询负责比赛
List<Comp> compList =compService.query().eq("comp_admin",loginUser.getUsername()).list();
//判空
if (compList.isEmpty()){
return Result.error("未绑定比赛");
}
//将比赛的id放进一个list里面
List<String> compIds = compList.stream()
.map(Comp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据比赛的id查询年度比赛id,这里没有去卡年度
List<AnnualComp> annualCompList = annualCompService.query().in("compid",compIds).list();
//判空
if (annualCompList.isEmpty()){
return Result.error("未创建年度比赛");
}
//将年度比赛id存放到一个list里面
List<String> anncompIds = annualCompList.stream()
.map(AnnualComp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
List<AnnualCompPoint> annualCompPointList = annualCompPointService.query().in("annual_comp_id", anncompIds).list();
//判空
if (annualCompPointList.isEmpty()){
return Result.error("未创建年度比赛项目");
}
//将年度比赛项目id存放到一个list里面
List<String> anncomppointIds = annualCompPointList.stream()
.map(AnnualCompPoint::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据用户角色决定查询信息
queryWrapperAddRoleInfo(queryWrapper);
queryWrapper.in("annual_compid",anncomppointIds);
/* queryWrapperAddRoleInfo(queryWrapper);*/
queryWrapper.eq("enroll_static", "0");
//查询
IPage<AnnualCompetitionProjectRegistration> pageList = annualCompetitionProjectRegistrationService.page(page, queryWrapper);
@ -248,8 +408,40 @@ public class AnnualCompetitionProjectRegistrationController {
//处理查询信息
QueryWrapper<AnnualCompetitionProjectRegistration> queryWrapper = QueryGenerator.initQueryWrapper(annualCompetitionProjectRegistration, req.getParameterMap());
Page<AnnualCompetitionProjectRegistration> page = new Page<AnnualCompetitionProjectRegistration>(pageNo, pageSize);
LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
//根据登录信息查询负责比赛
List<Comp> compList =compService.query().eq("comp_admin",loginUser.getUsername()).list();
//判空
if (compList.isEmpty()){
return Result.error("未绑定比赛");
}
//将比赛的id放进一个list里面
List<String> compIds = compList.stream()
.map(Comp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据比赛的id查询年度比赛id,这里没有去卡年度
List<AnnualComp> annualCompList = annualCompService.query().in("compid",compIds).list();
//判空
if (annualCompList.isEmpty()){
return Result.error("未创建年度比赛");
}
//将年度比赛id存放到一个list里面
List<String> anncompIds = annualCompList.stream()
.map(AnnualComp::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
List<AnnualCompPoint> annualCompPointList = annualCompPointService.query().in("annual_comp_id", anncompIds).list();
//判空
if (annualCompPointList.isEmpty()){
return Result.error("未创建年度比赛项目");
}
//将年度比赛项目id存放到一个list里面
List<String> anncomppointIds = annualCompPointList.stream()
.map(AnnualCompPoint::getId) // 使用方法引用获取每个Comp对象的id
.collect(Collectors.toList()); // 收集到List中
//根据用户角色决定查询信息
queryWrapperAddRoleInfo(queryWrapper);
queryWrapper.in("annual_compid",anncomppointIds);
/* queryWrapperAddRoleInfo(queryWrapper);*/
queryWrapper.eq("enroll_static", "3");
//查询
IPage<AnnualCompetitionProjectRegistration> pageList = annualCompetitionProjectRegistrationService.page(page, queryWrapper);
@ -273,6 +465,9 @@ public class AnnualCompetitionProjectRegistrationController {
} else if (role.equals("committee")) {
//首先获取负责的比赛
List<Comp> compList = compService.query().eq("comp_admin",loginUser.getUsername()).list();
if(compList.isEmpty()){
return ;
}
//将比赛的id放进一个list里面
List<String> compIds = compList.stream()
.map(Comp::getId) // 使用方法引用获取每个Comp对象的id
@ -995,7 +1190,7 @@ public class AnnualCompetitionProjectRegistrationController {
LoginUser user = (LoginUser) SecurityUtils.getSubject().getPrincipal();
Comp comp = new Comp();
QueryWrapper<Comp> queryWrappercomp = QueryGenerator.initQueryWrapper(comp, req.getParameterMap());
queryWrappercomp.like("comp_admin", user.getUsername());
queryWrappercomp.eq("comp_admin", user.getUsername());
List<Comp> list = compService.list(queryWrappercomp);
Map<String, Object> map = new HashMap<>();
if (list.size() > 0) {
@ -1774,7 +1969,7 @@ public class AnnualCompetitionProjectRegistrationController {
LoginUser user = (LoginUser) SecurityUtils.getSubject().getPrincipal();
Comp comp = new Comp();
QueryWrapper<Comp> queryWrappercomp = QueryGenerator.initQueryWrapper(comp, req.getParameterMap());
queryWrappercomp.like("comp_admin", user.getUsername());
queryWrappercomp.eq("comp_admin", user.getUsername());
List<Comp> list = compService.list(queryWrappercomp);
Map<String, Object> map = new HashMap<>();
if (list.size() > 0) {
@ -2129,7 +2324,7 @@ public class AnnualCompetitionProjectRegistrationController {
LoginUser user = (LoginUser) SecurityUtils.getSubject().getPrincipal();
Comp comp = new Comp();
QueryWrapper<Comp> queryWrappercomp = QueryGenerator.initQueryWrapper(comp, req.getParameterMap());
queryWrappercomp.like("comp_admin",user.getUsername());
queryWrappercomp.eq("comp_admin",user.getUsername());
List<Comp> list = compService.list(queryWrappercomp);
List<String> ids = list.stream().map(Comp::getId).collect(Collectors.toList());
QueryWrapper<AnnualComp> queryWrapperAnnual = new QueryWrapper<>();

@ -95,21 +95,30 @@ public class AnnualCompGroupController extends JeecgController<AnnualCompGroup,
LoginUser user = (LoginUser) SecurityUtils.getSubject().getPrincipal();
Comp comp = new Comp();
QueryWrapper<Comp> queryWrappercomp = QueryGenerator.initQueryWrapper(comp, req.getParameterMap());
queryWrappercomp.like("comp_admin",user.getUsername());
queryWrappercomp.eq("comp_admin",user.getUsername());
List<Comp> list = compService.list(queryWrappercomp);
if(list.size()==0){
return Result.error("未绑定比赛");
}
List<String> ids = list.stream().map(Comp::getId).collect(Collectors.toList());
QueryWrapper<AnnualComp> queryWrapperAnnual = new QueryWrapper<>();
queryWrapperAnnual.in(ids.size()!=0,"compid",ids);
queryWrapperAnnual.in("compid",ids);
List<AnnualComp> listAnnual = annualCompService.list(queryWrapperAnnual);
if(listAnnual.size()==0){
return Result.error("未创建年度比赛");
}
List<String> annualIds = listAnnual.stream().map(AnnualComp::getId).collect(Collectors.toList());
QueryWrapper<AnnualCompGroup> queryWrapper = QueryGenerator.initQueryWrapper(annualCompGroup, req.getParameterMap());
queryWrapper.in(annualIds.size()!=0,"annal_comp",annualIds);
AnnualCompPoint annualCompPoint = new AnnualCompPoint();
QueryWrapper<AnnualCompPoint> queryWrapperacp = QueryGenerator.initQueryWrapper(annualCompPoint, req.getParameterMap());
queryWrapperacp.in(annualIds.size()!=0,"annual_comp_id",annualIds);
queryWrapperacp.in("annual_comp_id",annualIds);
queryWrapperacp.eq("annual_comp_switch","Y"); // 比赛必须是开启的
List<AnnualCompPoint> listacp = annualCompPointService.list(queryWrapperacp);
if(listacp.size()==0){
return Result.error("未创建年度比赛项目");
}
List<String> acpIds = listacp.stream().map(AnnualCompPoint::getId).collect(Collectors.toList());
queryWrapper.in(acpIds.size()!=0,"ann_comp_p",acpIds);
@ -190,7 +199,7 @@ public class AnnualCompGroupController extends JeecgController<AnnualCompGroup,
LoginUser user = (LoginUser) SecurityUtils.getSubject().getPrincipal();
Comp comp = new Comp();
QueryWrapper<Comp> queryWrapper = QueryGenerator.initQueryWrapper(comp, req.getParameterMap());
queryWrapper.like("comp_admin",user.getUsername());
queryWrapper.eq("comp_admin",user.getUsername());
List<Comp> list = compService.list(queryWrapper);
String str = "";
for(int i = 0 ; i < list.size() ; i++){

@ -127,23 +127,32 @@ public class AwardPersionController extends JeecgController<AwardPersion, IAward
//组委会(全部都可以)(根据比赛负责人查询比赛id筛选)
Comp comp = new Comp();
QueryWrapper<Comp> queryWrappercomp = QueryGenerator.initQueryWrapper(comp, req.getParameterMap());
queryWrappercomp.like("comp_admin",user.getUsername());
queryWrappercomp.eq("comp_admin",user.getUsername());
List<Comp> list = compService.list(queryWrappercomp);
if(list.size()==0){
return Result.error("未绑定比赛");
}
List<String> ids = list.stream().map(Comp::getId).collect(Collectors.toList());
QueryWrapper<AnnualComp> queryWrapperAnnual = new QueryWrapper<>();
queryWrapperAnnual.in(ids.size()!=0,"compid",ids);
queryWrapperAnnual.in("compid",ids);
List<AnnualComp> listAnnual = annualCompService.list(queryWrapperAnnual);
if(listAnnual.size()==0){
return Result.error("未创建年度比赛");
}
List<String> annualIds = listAnnual.stream().map(AnnualComp::getId).collect(Collectors.toList());
QueryWrapper<AwardPersion> queryWrapper = QueryGenerator.initQueryWrapper(awardPersion, req.getParameterMap());
queryWrapper.in(annualIds.size()!=0,"annal_comp",annualIds);
queryWrapper.in("annal_comp",annualIds);
AnnualCompPoint annualCompPoint = new AnnualCompPoint();
QueryWrapper<AnnualCompPoint> queryWrapperacp = QueryGenerator.initQueryWrapper(annualCompPoint, req.getParameterMap());
queryWrapperacp.in(annualIds.size()!=0,"annual_comp_id",annualIds);
queryWrapperacp.in("annual_comp_id",annualIds);
queryWrapperacp.eq("annual_comp_switch","Y"); // 比赛必须是开启的
List<AnnualCompPoint> listacp = annualCompPointService.list(queryWrapperacp);
if(listacp.size()==0){
return Result.error("未创建年度比赛项目");
}
List<String> acpIds = listacp.stream().map(AnnualCompPoint::getId).collect(Collectors.toList());
queryWrapper.in(acpIds.size()!=0,"annual_comp_p",acpIds);
queryWrapper.in("annual_comp_p",acpIds);
Page<AwardPersion> page = new Page<AwardPersion>(pageNo, pageSize);
IPage<AwardPersion> pageList = awardPersionService.page(page, queryWrapper);

@ -105,21 +105,30 @@ public class ScorePersionController extends JeecgController<ScorePersion, IScore
LoginUser user = (LoginUser) SecurityUtils.getSubject().getPrincipal();
Comp comp = new Comp();
QueryWrapper<Comp> queryWrappercomp = QueryGenerator.initQueryWrapper(comp, req.getParameterMap());
queryWrappercomp.like("comp_admin",user.getUsername());
queryWrappercomp.eq("comp_admin",user.getUsername());
List<Comp> list = compService.list(queryWrappercomp);
if(list.size()==0){
return Result.error("未绑定比赛");
}
List<String> ids = list.stream().map(Comp::getId).collect(Collectors.toList());
QueryWrapper<AnnualComp> queryWrapperAnnual = new QueryWrapper<>();
queryWrapperAnnual.in(ids.size()!=0,"compid",ids);
List<AnnualComp> listAnnual = annualCompService.list(queryWrapperAnnual);
if(listAnnual.size()==0){
return Result.error("未创建年度比赛");
}
List<String> annualIds = listAnnual.stream().map(AnnualComp::getId).collect(Collectors.toList());
QueryWrapper<ScorePersion> queryWrapper = QueryGenerator.initQueryWrapper(scorePersion, req.getParameterMap());
queryWrapper.in(annualIds.size()!=0,"annual_compid",annualIds);
queryWrapper.in("annual_compid",annualIds);
AnnualCompPoint annualCompPoint = new AnnualCompPoint();
QueryWrapper<AnnualCompPoint> queryWrapperacp = QueryGenerator.initQueryWrapper(annualCompPoint, req.getParameterMap());
queryWrapperacp.in(annualIds.size()!=0,"annual_comp_id",annualIds);
queryWrapperacp.in("annual_comp_id",annualIds);
queryWrapperacp.eq("annual_comp_switch","Y"); // 比赛必须是开启的
List<AnnualCompPoint> listacp = annualCompPointService.list(queryWrapperacp);
if(listacp.size()==0){
return Result.error("未创建年度比赛项目");
}
List<String> acpIds = listacp.stream().map(AnnualCompPoint::getId).collect(Collectors.toList());
queryWrapper.in(acpIds.size()!=0,"annual_comp_p",acpIds);

@ -87,23 +87,32 @@ public class ScoreStaController extends JeecgController<ScoreSta, IScoreStaServi
LoginUser user = (LoginUser) SecurityUtils.getSubject().getPrincipal();
Comp comp = new Comp();
QueryWrapper<Comp> queryWrappercomp = QueryGenerator.initQueryWrapper(comp, req.getParameterMap());
queryWrappercomp.like("comp_admin",user.getUsername());
queryWrappercomp.eq("comp_admin",user.getUsername());
List<Comp> list = compService.list(queryWrappercomp);
if(list.size()==0){
return Result.error("未绑定比赛");
}
List<String> ids = list.stream().map(Comp::getId).collect(Collectors.toList());
QueryWrapper<AnnualComp> queryWrapperAnnual = new QueryWrapper<>();
queryWrapperAnnual.in(ids.size()!=0,"compid",ids);
queryWrapperAnnual.in("compid",ids);
List<AnnualComp> listAnnual = annualCompService.list(queryWrapperAnnual);
if(listAnnual.size()==0){
return Result.error("未创建年度比赛");
}
List<String> annualIds = listAnnual.stream().map(AnnualComp::getId).collect(Collectors.toList());
QueryWrapper<ScoreSta> queryWrapper = QueryGenerator.initQueryWrapper(scoreSta, req.getParameterMap());
queryWrapper.in(annualIds.size()!=0,"annal_comp",annualIds);
queryWrapper.in("annal_comp",annualIds);
AnnualCompPoint annualCompPoint = new AnnualCompPoint();
QueryWrapper<AnnualCompPoint> queryWrapperacp = QueryGenerator.initQueryWrapper(annualCompPoint, req.getParameterMap());
queryWrapperacp.in(annualIds.size()!=0,"annual_comp_id",annualIds);
queryWrapperacp.eq("annual_comp_switch","Y"); // 比赛必须是开启的
List<AnnualCompPoint> listacp = annualCompPointService.list(queryWrapperacp);
if(listacp.size()==0){
return Result.error("未创建年度比赛项目");
}
List<String> acpIds = listacp.stream().map(AnnualCompPoint::getId).collect(Collectors.toList());
queryWrapper.in(acpIds.size()!=0,"annual_compid",acpIds);
queryWrapper.in("annual_compid",acpIds);
Page<ScoreSta> page = new Page<ScoreSta>(pageNo, pageSize);

Loading…
Cancel
Save