|
@@ -295,16 +295,7 @@ public class MusicGroupPaymentCalenderServiceImpl extends BaseServiceImpl<Long,
|
|
|
BigDecimal memberActualAmount = musicGroupPaymentCalenderMemberService.getActualAmount(musicGroupPaymentBaseCalender);
|
|
|
BigDecimal repairActualAmount = musicGroupPaymentCalenderRepairService.getActualAmount(musicGroupPaymentBaseCalender);
|
|
|
BigDecimal activityActualAmount = musicGroupPaymentCalenderActivityService.getActualAmount(musicGroupPaymentBaseCalender);
|
|
|
- //标记是否云教练缴费
|
|
|
- if(musicGroupPaymentCalender.getPayUserType() == STUDENT && musicGroup.getCourseViewType() == CourseViewTypeEnum.MEMBER_FEE){
|
|
|
- if(musicGroupPaymentCalender.getPaymentType() == ADD_STUDENT){
|
|
|
- musicGroupPaymentCalender.setCloudTeacherPaymentFlag(true);
|
|
|
- }else if(memberActualAmount.compareTo(BigDecimal.ZERO) > 0 && (courseActualAmount.compareTo(BigDecimal.ZERO) == 0 || activityActualAmount.compareTo(BigDecimal.ZERO) == 0)) {
|
|
|
- if(CollectionUtils.isNotEmpty(musicGroupPaymentBaseCalender.getMusicGroupPaymentCalenderCourseSettingsList()) || CollectionUtils.isNotEmpty(musicGroupPaymentBaseCalender.getCalenderActivityList())){
|
|
|
- musicGroupPaymentCalender.setCloudTeacherPaymentFlag(true);
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
+
|
|
|
BigDecimal actualTotalAmount = courseActualAmount.add(memberActualAmount)
|
|
|
.add(repairActualAmount)
|
|
|
.add(activityActualAmount).setScale(0, BigDecimal.ROUND_HALF_UP);
|
|
@@ -361,6 +352,16 @@ public class MusicGroupPaymentCalenderServiceImpl extends BaseServiceImpl<Long,
|
|
|
// 设置批次号
|
|
|
String batchNo = idGeneratorService.generatorId() + "";
|
|
|
musicGroupPaymentCalender.setBatchNo(batchNo);
|
|
|
+ //标记是否云教练缴费
|
|
|
+ if(musicGroupPaymentCalender.getPayUserType() == STUDENT && musicGroup.getCourseViewType() == CourseViewTypeEnum.MEMBER_FEE){
|
|
|
+ if(musicGroupPaymentCalender.getPaymentType() == ADD_STUDENT){
|
|
|
+ musicGroupPaymentCalender.setCloudTeacherPaymentFlag(true);
|
|
|
+ }else if(memberActualAmount.compareTo(BigDecimal.ZERO) > 0 && (courseActualAmount.compareTo(BigDecimal.ZERO) == 0 || activityActualAmount.compareTo(BigDecimal.ZERO) == 0)) {
|
|
|
+ if(CollectionUtils.isNotEmpty(musicGroupPaymentBaseCalender.getMusicGroupPaymentCalenderCourseSettingsList()) || CollectionUtils.isNotEmpty(musicGroupPaymentBaseCalender.getCalenderActivityList())){
|
|
|
+ musicGroupPaymentCalender.setCloudTeacherPaymentFlag(true);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
musicGroupPaymentCalenderDao.insert(musicGroupPaymentCalender);
|
|
|
|
|
|
operatingReportCloudService.save(musicGroupPaymentCalender);
|