|
|
@@ -946,7 +946,12 @@ public class SysLearningGrowthServiceImpl implements ISysLearningGrowthService {
|
|
946
|
946
|
BigDecimal sum = target.stream().map(SysLargeScreenLearningGrowthSqlDto::getExamScore).reduce(BigDecimal.ZERO, BigDecimal::add);
|
|
947
|
947
|
int count = target.size();
|
|
948
|
948
|
return count == 0 ? BigDecimal.ZERO : sum.divide(BigDecimal.valueOf(count), 1, RoundingMode.HALF_UP);
|
|
949
|
|
- } else if (StrUtil.equals(DeptTypeEnum.DEPARTMENT.getCode(), sysDept.getDeptType())) {
|
|
|
949
|
+ } else if (StrUtil.equals(DeptTypeEnum.BRIGADE.getCode(), sysDept.getDeptType())) {
|
|
|
950
|
+ List<SysLargeScreenLearningGrowthSqlDto> target = all.stream().filter(item -> ObjUtil.equals(item.getDdDeptId(), dto.getDeptId())).collect(Collectors.toList());
|
|
|
951
|
+ BigDecimal sum = target.stream().map(SysLargeScreenLearningGrowthSqlDto::getExamScore).reduce(BigDecimal.ZERO, BigDecimal::add);
|
|
|
952
|
+ int count = target.size();
|
|
|
953
|
+ return count == 0 ? BigDecimal.ZERO : sum.divide(BigDecimal.valueOf(count), 1, RoundingMode.HALF_UP);
|
|
|
954
|
+ } else if (StrUtil.equals(DeptTypeEnum.MANAGER.getCode(), sysDept.getDeptType())) {
|
|
950
|
955
|
List<SysLargeScreenLearningGrowthSqlDto> target = all.stream().filter(item -> ObjUtil.equals(item.getKsDeptId(), dto.getDeptId())).collect(Collectors.toList());
|
|
951
|
956
|
BigDecimal sum = target.stream().map(SysLargeScreenLearningGrowthSqlDto::getExamScore).reduce(BigDecimal.ZERO, BigDecimal::add);
|
|
952
|
957
|
int count = target.size();
|