fix:公告查询接口开发

dev
wangxy 11 months ago
parent 1cd05b8285
commit b7c2c1f447

@ -74,12 +74,12 @@ public class ScoreInfoManager {
RewScoreInfoVO rewScoreInfoVO = new RewScoreInfoVO(); RewScoreInfoVO rewScoreInfoVO = new RewScoreInfoVO();
LambdaQueryWrapper<RewScoreInfo> queryWrapper = new LambdaQueryWrapper<>(); LambdaQueryWrapper<RewScoreInfo> queryWrapper = new LambdaQueryWrapper<>();
queryWrapper.eq(RewScoreInfo::getApplyId,applyId); queryWrapper.eq(RewScoreInfo::getApplyId,applyId);
queryWrapper.orderByDesc(RewScoreInfo::getScore);
if (!SysUser.isAdmin(SecurityUtils.getUserId())){ if (!SysUser.isAdmin(SecurityUtils.getUserId())){
queryWrapper.eq(RewScoreInfo::getCreateId, SecurityUtils.getUserId()); queryWrapper.eq(RewScoreInfo::getCreateId, SecurityUtils.getUserId());
}else { }else {
rewScoreInfoVO.setAvgScore(avgRewScore(applyId)); rewScoreInfoVO.setAvgScore(avgRewScore(applyId));
} }
queryWrapper.orderByDesc(RewScoreInfo::getScore);
List<RewScoreInfo> list = scoreInfoService.list(queryWrapper); List<RewScoreInfo> list = scoreInfoService.list(queryWrapper);
rewScoreInfoVO.setRewScoreInfos(list); rewScoreInfoVO.setRewScoreInfos(list);
return rewScoreInfoVO; return rewScoreInfoVO;

Loading…
Cancel
Save