|
@@ -2452,7 +2452,7 @@ public class VipGroupServiceImpl extends BaseServiceImpl<Long, VipGroup> impleme
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
- @Transactional(rollbackFor = Exception.class)
|
|
|
+ @Transactional(rollbackFor = Exception.class, isolation = Isolation.READ_COMMITTED)
|
|
|
public void addVipGroupStudents(Long vipGroupId, List<Integer> studentIds) {
|
|
|
if(CollectionUtils.isEmpty(studentIds)){
|
|
|
throw new BizException("请选择学生");
|
|
@@ -2652,6 +2652,18 @@ public class VipGroupServiceImpl extends BaseServiceImpl<Long, VipGroup> impleme
|
|
|
courseScheduleStudentPayment.setCreateTime(now);
|
|
|
courseScheduleStudentPayment.setUpdateTime(now);
|
|
|
courseScheduleStudentPayments.add(courseScheduleStudentPayment);
|
|
|
+
|
|
|
+
|
|
|
+ if(!CollectionUtils.isEmpty(classGroupStudentMappers)){
|
|
|
+ classGroupStudentMapperDao.classGroupStudentsInsert(classGroupStudentMappers);
|
|
|
+ if(vipGroup.getOnlineClassesNum()>0){
|
|
|
+ try {
|
|
|
+ teacherCourseRewardService.addConvertReward(studentId, vipGroup.getUserId());
|
|
|
+ } catch (Exception e) {
|
|
|
+ e.printStackTrace();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
courseScheduleStudentPaymentDao.batchInsert(courseScheduleStudentPayments);
|
|
|
|
|
@@ -2678,10 +2690,6 @@ public class VipGroupServiceImpl extends BaseServiceImpl<Long, VipGroup> impleme
|
|
|
imGroupMemberList.add(new ImGroupMember(studentId.toString()));
|
|
|
}
|
|
|
|
|
|
- if(!CollectionUtils.isEmpty(classGroupStudentMappers)){
|
|
|
- classGroupStudentMapperDao.classGroupStudentsInsert(classGroupStudentMappers);
|
|
|
- }
|
|
|
-
|
|
|
VipGroupStatusEnum vipGroupStatus = vipGroup.getStatus();
|
|
|
|
|
|
Integer currentStudentNum = classGroupStudentMapperDao.countClassGroupStudentNum(classGroup.getId());
|