|
|
@@ -1,10 +1,10 @@
|
|
|
package com.ym.mec.web.controller;
|
|
|
|
|
|
+import com.ym.mec.biz.dal.dao.MusicGroupPaymentCalenderCourseSettingsDao;
|
|
|
+import com.ym.mec.biz.dal.dao.MusicGroupPaymentCalenderDao;
|
|
|
import com.ym.mec.biz.dal.dto.MusicGroupSubjectGoodsAndInfoDto;
|
|
|
import com.ym.mec.biz.dal.dto.StudentAddDto;
|
|
|
-import com.ym.mec.biz.dal.entity.MusicGroup;
|
|
|
-import com.ym.mec.biz.dal.entity.StudentPaymentOrderDetail;
|
|
|
-import com.ym.mec.biz.dal.entity.StudentRegistration;
|
|
|
+import com.ym.mec.biz.dal.entity.*;
|
|
|
import com.ym.mec.biz.dal.enums.ClassGroupTypeEnum;
|
|
|
import com.ym.mec.biz.dal.page.StudentRegistrationQueryInfo;
|
|
|
import com.ym.mec.biz.service.MusicGroupSubjectPlanService;
|
|
|
@@ -33,6 +33,10 @@ public class StudentRegistrationController extends BaseController {
|
|
|
private StudentRegistrationService studentRegistrationService;
|
|
|
@Autowired
|
|
|
private MusicGroupSubjectPlanService musicGroupSubjectPlanService;
|
|
|
+ @Autowired
|
|
|
+ private MusicGroupPaymentCalenderDao musicGroupPaymentCalenderDao;
|
|
|
+ @Autowired
|
|
|
+ private MusicGroupPaymentCalenderCourseSettingsDao musicGroupPaymentCalenderCourseSettingsDao;
|
|
|
|
|
|
@ApiOperation(value = "乐团添加学员")
|
|
|
@PostMapping("/insertStudent")
|
|
|
@@ -153,11 +157,19 @@ public class StudentRegistrationController extends BaseController {
|
|
|
@PreAuthorize("@pcs.hasPermissions('studentRegistration/getSubjectGoodsAndInfo')")
|
|
|
@ApiImplicitParams({@ApiImplicitParam(name = "subjectId", value = "声部信息", required = true, dataType = "Integer"),
|
|
|
@ApiImplicitParam(name = "musicGroupId", value = "乐团编号", required = true, dataType = "String")})
|
|
|
- public HttpResponseResult<MusicGroupSubjectGoodsAndInfoDto> getSubjectGoodsAndInfo(Integer subjectId, String musicGroupId) {
|
|
|
- if (subjectId == null || StringUtils.isEmpty(musicGroupId)) {
|
|
|
+ public HttpResponseResult<MusicGroupSubjectGoodsAndInfoDto> getSubjectGoodsAndInfo(Integer subjectId, String musicGroupId, Long calenderId) {
|
|
|
+ if (subjectId == null || StringUtils.isEmpty(musicGroupId) || calenderId == null) {
|
|
|
return failed("参数校验异常");
|
|
|
}
|
|
|
- return succeed(musicGroupSubjectPlanService.getSubjectGoodsAndInfo(musicGroupId, subjectId));
|
|
|
+ MusicGroupSubjectGoodsAndInfoDto subjectGoodsAndInfo = musicGroupSubjectPlanService.getSubjectGoodsAndInfo(musicGroupId, subjectId);
|
|
|
+
|
|
|
+ MusicGroupPaymentCalender musicGroupRegCalender = musicGroupPaymentCalenderDao.get(calenderId);
|
|
|
+ if (musicGroupRegCalender != null && musicGroupRegCalender.getPayUserType().equals(MusicGroupPaymentCalender.PayUserType.STUDENT)) {
|
|
|
+ List<MusicGroupPaymentCalenderCourseSettings> courseSettings = musicGroupPaymentCalenderCourseSettingsDao.getWithPaymentCalender(musicGroupRegCalender.getId());
|
|
|
+ musicGroupRegCalender.setMusicGroupPaymentCalenderCourseSettingsList(courseSettings);
|
|
|
+ subjectGoodsAndInfo.setMusicGroupPaymentCalender(musicGroupRegCalender);
|
|
|
+ }
|
|
|
+ return succeed(subjectGoodsAndInfo);
|
|
|
}
|
|
|
|
|
|
@ApiOperation(value = "获取班级课程的价值")
|