|
|
@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
|
|
|
import org.jeecg.common.exception.JeecgBootException; |
|
|
|
import org.jeecg.common.exception.JeecgBootException; |
|
|
|
import org.jeecg.common.util.ComputeUtils; |
|
|
|
import org.jeecg.common.util.ComputeUtils; |
|
|
|
import org.jeecg.common.util.DateUtils; |
|
|
|
import org.jeecg.common.util.DateUtils; |
|
|
|
|
|
|
|
import org.jeecg.common.util.RedisUtil; |
|
|
|
import org.jeecg.modules.demo.abilityEvaluation.entity.DepartAbilityEvaluation; |
|
|
|
import org.jeecg.modules.demo.abilityEvaluation.entity.DepartAbilityEvaluation; |
|
|
|
import org.jeecg.modules.demo.abilityEvaluation.entity.PersonalAbilityEvaluationCollect; |
|
|
|
import org.jeecg.modules.demo.abilityEvaluation.entity.PersonalAbilityEvaluationCollect; |
|
|
|
import org.jeecg.modules.demo.abilityEvaluation.service.IDepartAbilityEvaluationService; |
|
|
|
import org.jeecg.modules.demo.abilityEvaluation.service.IDepartAbilityEvaluationService; |
|
|
@ -108,6 +109,9 @@ public class UserHomePageServiceImpl implements UserHomePageService { |
|
|
|
|
|
|
|
|
|
|
|
final String BASE_PARENT_ID = "1693446350597038081"; |
|
|
|
final String BASE_PARENT_ID = "1693446350597038081"; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired |
|
|
|
|
|
|
|
private RedisUtil redisUtil; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public Map<String, Object> homePage4Depart(String orgCode) { |
|
|
|
public Map<String, Object> homePage4Depart(String orgCode) { |
|
|
@ -358,9 +362,12 @@ public class UserHomePageServiceImpl implements UserHomePageService { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public Map<String, Object> report4School() { |
|
|
|
public Object report4School(boolean recreateFlag) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
final String REPORT4SCHOOL = "report4School"; |
|
|
|
|
|
|
|
|
|
|
|
Map<String, Object> resultMap = new LinkedHashMap<>(); |
|
|
|
Map<String, Object> resultMap = new LinkedHashMap<>(); |
|
|
|
|
|
|
|
if (recreateFlag) { |
|
|
|
int currentYear = DateUtils.getCurrentYear(); |
|
|
|
int currentYear = DateUtils.getCurrentYear(); |
|
|
|
//当前年度
|
|
|
|
//当前年度
|
|
|
|
Annual annual = iAnnualService.getOne(new LambdaQueryWrapper<Annual>().eq(Annual::getAnnualName, currentYear + "")); |
|
|
|
Annual annual = iAnnualService.getOne(new LambdaQueryWrapper<Annual>().eq(Annual::getAnnualName, currentYear + "")); |
|
|
@ -579,8 +586,16 @@ public class UserHomePageServiceImpl implements UserHomePageService { |
|
|
|
}); |
|
|
|
}); |
|
|
|
scoreList4Point.stream().sorted(Comparator.comparing(HomePageCompVo::getTotalScore)).collect(Collectors.toList()); |
|
|
|
scoreList4Point.stream().sorted(Comparator.comparing(HomePageCompVo::getTotalScore)).collect(Collectors.toList()); |
|
|
|
resultMap.put("比赛学生积分况分析", scoreList4Point); |
|
|
|
resultMap.put("比赛学生积分况分析", scoreList4Point); |
|
|
|
|
|
|
|
redisUtil.set(REPORT4SCHOOL, resultMap.toString()); |
|
|
|
return resultMap; |
|
|
|
return resultMap; |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
boolean hasKey = redisUtil.hasKey(REPORT4SCHOOL); |
|
|
|
|
|
|
|
if (hasKey) { |
|
|
|
|
|
|
|
return redisUtil.get(REPORT4SCHOOL); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
return this.report4School(true); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
private List<AnnualCompPoint> convertPoint4Depart(SysDepart depart) { |
|
|
|
private List<AnnualCompPoint> convertPoint4Depart(SysDepart depart) { |
|
|
|