|
@@ -647,6 +647,7 @@ public class VipGroupServiceImpl extends BaseServiceImpl<Long, VipGroup> impleme
|
|
|
if(dataList != null && dataList.size() > 0){
|
|
|
List<String> vipGroupIds = dataList.stream().map(vipGroup -> String.valueOf(vipGroup.getId())).distinct().collect(Collectors.toList());
|
|
|
List<Map<Long, Integer>> vipGroupOverCourses = courseScheduleDao.countGroupOverCourse(vipGroupIds,"VIP");
|
|
|
+ List<Map<String, Integer>> groupStudentNumMaps = classGroupStudentMapperDao.countGroupAllStudentNum(vipGroupIds, GroupType.VIP);
|
|
|
Map<String,Integer> vipGroupOverCourseMaps = JSONObject.parseObject(JSONObject.toJSONString(MapUtil.convertIntegerMap(vipGroupOverCourses)),HashMap.class);
|
|
|
List<Integer> educationalTeacherIds=dataList.stream().filter(data -> Objects.nonNull(data.getEducationalTeacherId())).map(VipGroup::getEducationalTeacherId).collect(Collectors.toList());
|
|
|
|
|
@@ -659,6 +660,7 @@ public class VipGroupServiceImpl extends BaseServiceImpl<Long, VipGroup> impleme
|
|
|
Map<String,Long> totalClassTimeMap = MapUtil.convertIntegerMap(courseScheduleDao.countTotalCourseScheduleNum(vipGroupIds,"VIP"));
|
|
|
Map<String,Long> currentClassTimeMap = MapUtil.convertIntegerMap(courseScheduleDao.countCourseScheduleNum(vipGroupIds,"VIP"));
|
|
|
Map<String,String> lastOverTimeMap = MapUtil.convertIntegerMap(courseScheduleDao.findLastOverTime(vipGroupIds));
|
|
|
+ Map<String,Long> groupStudentNumMap = MapUtil.convertIntegerMap(groupStudentNumMaps);
|
|
|
|
|
|
List<Map<String, BigDecimal>> groupCoursesUnitPriceMaps = courseScheduleStudentPaymentDao.findGroupCoursesUnitPrice(GroupType.VIP, vipGroupIds);
|
|
|
Map<String,BigDecimal> groupCoursesUnitPrice=new HashMap<>();
|
|
@@ -689,8 +691,14 @@ public class VipGroupServiceImpl extends BaseServiceImpl<Long, VipGroup> impleme
|
|
|
vipGroup.setTotalClassTimes(aLong==null?0:aLong.intValue());
|
|
|
Long aLong1 = currentClassTimeMap.get(vipGroup.getId() + "");
|
|
|
vipGroup.setCurrentClassTimes(aLong1==null?0:aLong1.intValue());
|
|
|
+
|
|
|
+ Long allStudentNum=groupStudentNumMap.get(vipGroup.getId().toString());
|
|
|
+ if(Objects.isNull(allStudentNum)){
|
|
|
+ allStudentNum=Long.valueOf(0);
|
|
|
+ }
|
|
|
+
|
|
|
if((Objects.isNull(aLong)||aLong<=0)
|
|
|
- &&(Objects.isNull(vipGroup.getStudentNum())||vipGroup.getStudentNum()<=0)
|
|
|
+ &&(allStudentNum<=0)
|
|
|
&&(VipGroupStatusEnum.NOT_START.equals(vipGroup.getStatus())
|
|
|
||VipGroupStatusEnum.APPLYING.equals(vipGroup.getStatus()))){
|
|
|
vipGroup.setEnableDelete(1);
|