瀏覽代碼

Merge remote-tracking branch 'origin/master'

Joburgess 4 年之前
父節點
當前提交
acfddf2730
共有 33 個文件被更改,包括 1170 次插入74 次删除
  1. 1 1
      codegen/src/main/resources/generateConfigration.xml
  2. 63 33
      mec-biz/src/main/java/com/ym/mec/biz/dal/dao/CourseScheduleStudentPaymentDao.java
  3. 8 0
      mec-biz/src/main/java/com/ym/mec/biz/dal/dao/MusicGroupPaymentCalenderDetailDao.java
  4. 47 0
      mec-biz/src/main/java/com/ym/mec/biz/dal/dao/SysExamSongAccompanimentDao.java
  5. 10 0
      mec-biz/src/main/java/com/ym/mec/biz/dal/dao/SysMusicScoreCategoriesDao.java
  6. 43 0
      mec-biz/src/main/java/com/ym/mec/biz/dal/dto/ExamSongDto.java
  7. 157 0
      mec-biz/src/main/java/com/ym/mec/biz/dal/entity/SysExamSongAccompaniment.java
  8. 92 0
      mec-biz/src/main/java/com/ym/mec/biz/dal/entity/SysMusicScoreCategories.java
  9. 10 0
      mec-biz/src/main/java/com/ym/mec/biz/dal/page/SysExamSongQueryInfo.java
  10. 8 0
      mec-biz/src/main/java/com/ym/mec/biz/service/MusicGroupPaymentCalenderDetailService.java
  11. 18 0
      mec-biz/src/main/java/com/ym/mec/biz/service/SysExamSongAccompanimentService.java
  12. 7 0
      mec-biz/src/main/java/com/ym/mec/biz/service/SysExamSongService.java
  13. 8 0
      mec-biz/src/main/java/com/ym/mec/biz/service/SysMusicScoreCategoriesService.java
  14. 1 1
      mec-biz/src/main/java/com/ym/mec/biz/service/UploadFileService.java
  15. 4 1
      mec-biz/src/main/java/com/ym/mec/biz/service/impl/CourseScheduleServiceImpl.java
  16. 26 1
      mec-biz/src/main/java/com/ym/mec/biz/service/impl/MusicGroupPaymentCalenderDetailServiceImpl.java
  17. 63 0
      mec-biz/src/main/java/com/ym/mec/biz/service/impl/SysExamSongAccompanimentServiceImpl.java
  18. 75 1
      mec-biz/src/main/java/com/ym/mec/biz/service/impl/SysExamSongServiceImpl.java
  19. 23 0
      mec-biz/src/main/java/com/ym/mec/biz/service/impl/SysMusicScoreCategoriesServiceImpl.java
  20. 7 0
      mec-biz/src/main/resources/config/mybatis/CourseScheduleStudentPaymentMapper.xml
  21. 7 0
      mec-biz/src/main/resources/config/mybatis/MusicGroupPaymentCalenderDetailMapper.xml
  22. 198 0
      mec-biz/src/main/resources/config/mybatis/SysExamSongAccompanimentMapper.xml
  23. 5 6
      mec-biz/src/main/resources/config/mybatis/SysExamSongMapper.xml
  24. 73 0
      mec-biz/src/main/resources/config/mybatis/SysMusicScoreCategoriesMapper.xml
  25. 33 0
      mec-student/src/main/java/com/ym/mec/student/controller/SysExamSongAccompanimentController.java
  26. 63 0
      mec-teacher/src/main/java/com/ym/mec/teacher/controller/SysExamSongAccompanimentController.java
  27. 4 15
      mec-teacher/src/main/java/com/ym/mec/teacher/controller/SysExamSongController.java
  28. 47 0
      mec-teacher/src/main/java/com/ym/mec/teacher/controller/SysMusicScoreCategoriesController.java
  29. 2 2
      mec-web/src/main/java/com/ym/mec/web/controller/ExportController.java
  30. 8 0
      mec-web/src/main/java/com/ym/mec/web/controller/MusicGroupPaymentCalenderDetailController.java
  31. 8 1
      mec-web/src/main/java/com/ym/mec/web/controller/StudentRegistrationController.java
  32. 45 0
      mec-web/src/main/java/com/ym/mec/web/controller/SysExamSongAccompanimentController.java
  33. 6 12
      mec-web/src/main/java/com/ym/mec/web/controller/SysExamSongController.java

+ 1 - 1
codegen/src/main/resources/generateConfigration.xml

@@ -8,7 +8,7 @@
 		<catalog>mec_dev</catalog>
 		<schema>mec_dev</schema>
 	</dbConfiguration>
-	<srcBase>/Users/zouxuan/Documents/javabean</srcBase>
+	<srcBase>/Users/chenxiaoyu/Documents/javabean</srcBase>
 	<pojoPackageName>com.ym.mec.biz.dal.entity</pojoPackageName>
 	<daoPackageName>com.ym.mec.biz.dal.dao</daoPackageName>
 	<servicePackageName>com.ym.mec.biz.service</servicePackageName>

+ 63 - 33
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/CourseScheduleStudentPaymentDao.java

@@ -26,11 +26,11 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
     int batchInsert(List<CourseScheduleStudentPayment> courseScheduleStudentPayments);
 
     /**
+     * @param courseScheduleStudentPayments:
+     * @return int
      * @describe 批量更新
      * @author Joburgess
      * @date 2020/1/10
-     * @param courseScheduleStudentPayments:
-     * @return int
      */
     int batchUpdate(@Param("courseScheduleStudentPayments") List<CourseScheduleStudentPayment> courseScheduleStudentPayments);
 
@@ -117,15 +117,15 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
                                                                               @Param("userId") Integer userId);
 
     /**
-     * @describe 统计团体下为开始课程学生数量
-     * @author Joburgess
-     * @date 2020.09.27
      * @param groupId:
      * @param groupType:
      * @return int
      * @describe 统计团体下为开始课程学生数量
      * @author Joburgess
      * @date 2020.09.27
+     * @describe 统计团体下为开始课程学生数量
+     * @author Joburgess
+     * @date 2020.09.27
      */
     int countNotStartCourseStudentNumWithGroup(@Param("groupId") String groupId,
                                                @Param("groupType") GroupType groupType);
@@ -145,6 +145,7 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 根据乐团编号删除记录
+     *
      * @param musicGroupId
      * @return
      */
@@ -152,6 +153,7 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 根据乐团编号,和groupTYpe获取学员剩余课程数
+     *
      * @param musicGroupIds
      * @param userId
      * @param groupType
@@ -172,21 +174,24 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 根据乐团,vip状态获取编号
+     *
      * @return
      */
     Set<Integer> queryMusicStudentPer();
+
     /**
      * 根据乐团,vip状态获取编号
+     *
      * @return
      */
     Set<Integer> queryVipStudentPer();
 
     /**
+     * @param courseIds: 统计课程上的学生人数
+     * @return java.util.List<java.util.Map < java.lang.Integer, java.lang.Integer>>
      * @describe
      * @author Joburgess
      * @date 2020/1/8
-     * @param courseIds: 统计课程上的学生人数
-     * @return java.util.List<java.util.Map<java.lang.Integer,java.lang.Integer>>
      */
     List<Map<Integer, Integer>> countCourseStudentNum(@Param("courseIds") List<Long> courseIds);
 
@@ -211,11 +216,11 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
     List<CourseScheduleStudentPayment> findByCourseSchedule(@Param("courseScheduleId") Long courseScheduleId);
 
     /**
+     * @param mainMergeCourseId:
+     * @return java.util.List<com.ym.mec.biz.dal.entity.CourseScheduleStudentPayment>
      * @describe 获取合并课程的学员缴费记录
      * @author Joburgess
      * @date 2021/1/21 0021
-     * @param mainMergeCourseId:
-     * @return java.util.List<com.ym.mec.biz.dal.entity.CourseScheduleStudentPayment>
      */
     List<CourseScheduleStudentPayment> findByMainMergedCourse(@Param("mainMergeCourseId") Long mainMergeCourseId);
 
@@ -230,17 +235,18 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 获取课程学员数量
+     *
      * @param courseScheduleId
      * @return
      */
     Integer countStudentNum(Integer courseScheduleId);
 
     /**
+     * @param courseScheduleId:
+     * @return int
      * @describe 统计课程学员数量
      * @author Joburgess
      * @date 2021/2/9 0009
-     * @param courseScheduleId:
-     * @return int
      */
     int countCourseOnlyStudentNum(@Param("courseScheduleId") Long courseScheduleId);
 
@@ -257,6 +263,7 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 获取当前课程的学员列表
+     *
      * @param courseScheduleId
      * @return
      */
@@ -264,17 +271,18 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 获取课程的学员编号列表
+     *
      * @param courseScheduleIds
      * @return
      */
     List<Map<Integer, String>> getStudentIdMap(@Param("courseScheduleIds") List<Long> courseScheduleIds);
 
     /**
+     * @param monday:
+     * @return java.util.List<java.lang.Integer>
      * @describe 获取在指定时间之后不存在网管课的学员编号列表
      * @author Joburgess
      * @date 2020/4/10
-     * @param monday:
-     * @return java.util.List<java.lang.Integer>
      */
     List<Practice4ExercisesSituationDto> findNoPracticeStudentIdsOnWeek(@Param("monday") String monday,
                                                                         @Param("sunday") String sunday);
@@ -283,6 +291,7 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 从指定时间开始查询学的线上可数
+     *
      * @return
      */
     List<StudentCourseTimesDto> queryStudentNotStartCourseTimesOfOnline();
@@ -300,6 +309,7 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 获取学员指定课程类型的剩余课时数
+     *
      * @param studentId
      * @param courseScheduleType
      * @return
@@ -309,6 +319,7 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 批量操作节拍器状态
+     *
      * @param courseScheduleId
      * @param userId
      */
@@ -316,6 +327,7 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 获取用户的节拍器信息
+     *
      * @param userIds
      * @param courseScheduleId
      * @return
@@ -324,6 +336,7 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 获取用户的曲目下载信息
+     *
      * @param userIds
      * @param courseScheduleId
      * @return
@@ -332,6 +345,7 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 获取单个用户的midi
+     *
      * @param courseScheduleId
      * @param userId
      * @return
@@ -340,6 +354,7 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 获取单个用户的examDownloadJson
+     *
      * @param courseScheduleId
      * @param userId
      * @return
@@ -347,18 +362,19 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
     String getExamJsonByCourseIdAndUserId(@Param("courseScheduleId") Long courseScheduleId, @Param("userId") Integer userId);
 
     /**
+     * @param groupType:
+     * @param groupIds:
+     * @return java.util.List<java.util.Map < java.lang.String, java.math.BigDecimal>>
      * @describe 统计课程组下的课程单价
      * @author Joburgess
      * @date 2020.06.11
-     * @param groupType:
-     * @param groupIds:
-     * @return java.util.List<java.util.Map<java.lang.String,java.math.BigDecimal>>
      */
     List<Map<String, BigDecimal>> findGroupCoursesUnitPrice(@Param("groupType") GroupType groupType,
                                                             @Param("groupIds") List<String> groupIds);
 
     /**
      * 获取未进入教室的学员列表
+     *
      * @param roomId
      * @param courseScheduleId
      * @return
@@ -382,11 +398,11 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
 
     /**
+     * @param StudentIds:
+     * @return java.util.List<java.util.Map < java.lang.Integer, java.util.Date>>
      * @describe 获取指定学员的最后一节课时间
      * @author Joburgess
      * @date 2020/11/17 0017
-     * @param StudentIds:
-     * @return java.util.List<java.util.Map<java.lang.Integer,java.util.Date>>
      */
     List<Map<Integer, Date>> findStudentLastCourseSchedule(@Param("studentIds") List<Integer> StudentIds);
 
@@ -396,27 +412,28 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 修改学员曲目下载信息
-     * @author zouxuan
+     *
      * @param roomId
+     * @author zouxuan
      */
     int adjustExamSong(@Param("roomId") Long roomId, @Param("userId") Integer userId, @Param("examSongJson") String examSongJson);
 
     /**
-     * @describe 统计学员通过双十一活动排课的数量
-     * @author qnc99
-     * @date 2020/11/25 0025
      * @param userIds:
      * @param activityIds:
      * @return java.util.List<com.ym.mec.biz.dal.dto.StudentVipDouble11Dto>
+     * @describe 统计学员通过双十一活动排课的数量
+     * @author qnc99
+     * @date 2020/11/25 0025
      */
     List<StudentVipDouble11Dto> countStudentDouble11CourseTime(@Param("userIds") List<Integer> userIds,
                                                                @Param("specialActivityIds") List<Integer> specialActivityIds);
 
     /**
+     * @return java.util.List<com.ym.mec.biz.dal.entity.CourseScheduleStudentPaymentDto>
      * @describe 获取需要更新课营收的课程
      * @author qnc99
      * @date 2020/12/2 0002
-     * @return java.util.List<com.ym.mec.biz.dal.entity.CourseScheduleStudentPaymentDto>
      */
     List<CourseScheduleStudentPaymentDto> findNeedUpdateActualPriceStudentCourses(@Param("groupIds") List<String> groupIds,
                                                                                   @Param("userIds") List<Integer> userIds,
@@ -424,62 +441,75 @@ public interface CourseScheduleStudentPaymentDao extends BaseDAO<Long, CourseSch
 
     /**
      * 根据课程编号和,学员编号获取列表信息
-     * @author zouxuan
+     *
      * @param courseIds
      * @param studentId
      * @return
+     * @author zouxuan
      */
     List<CourseScheduleStudentPayment> queryCourseByIdsAndStudentId(@Param("courseIds") List<Long> courseIds, @Param("studentId") Integer studentId, @Param("courseType") String courseType);
 
     /**
      * 获取班级学员关联的编号
-     * @zouxuan
+     *
      * @param classGroupIds
      * @param studentIds
      * @return
+     * @zouxuan
      */
     List<Long> queryStudentNotStartByClassIdsAndStudentIds(@Param("classGroupIds") List<Integer> classGroupIds, @Param("studentIds") List<Integer> studentIds);
 
     /**
      * 获取指定列表中学员的费用列表
-     * @author zouxuan
+     *
      * @param studentPaymentIds
      * @param studentId
      * @return
+     * @author zouxuan
      */
     List<CourseScheduleStudentPayment> queryByIdsAndStudentId(@Param("studentPaymentIds") List<Long> studentPaymentIds, @Param("studentId") Integer studentId, @Param("courseType") String courseType);
 
     /**
-     * @describe 统计课程组已经开始的课程的应缴费用
-     * @author qnc99
-     * @date 2020/12/8 0008
      * @param groupId:
      * @param groupType:
      * @return java.math.BigDecimal
+     * @describe 统计课程组已经开始的课程的应缴费用
+     * @author qnc99
+     * @date 2020/12/8 0008
      */
     BigDecimal countFinishCoursePriceWithMusicGroup(@Param("groupId") String groupId,
                                                     @Param("groupType") GroupType groupType,
                                                     @Param("userId") Integer userId);
 
     /**
-     * @describe 获取学生指定日期之前指定类型的最后一节课
-     * @author Joburgess
-     * @date 2020/12/25 0025
      * @param studentId:
      * @param monday:
      * @return com.ym.mec.biz.dal.entity.CourseSchedule
+     * @describe 获取学生指定日期之前指定类型的最后一节课
+     * @author Joburgess
+     * @date 2020/12/25 0025
      */
     CourseSchedule getStudentHistoryLastCourse(@Param("studentId") Integer studentId,
                                                @Param("monday") String monday,
                                                @Param("groupId") String groupId,
-                                               @Param("courseType")CourseSchedule.CourseScheduleType courseType);
+                                               @Param("courseType") CourseSchedule.CourseScheduleType courseType);
 
     /**
      * 获取学员对应课程类型剩余课程价值
+     *
      * @param studentId
      * @param classGroupId
      * @param courseType
      * @return
      */
     BigDecimal querySubCoursePriceMap(@Param("studentId") Integer studentId, @Param("classGroupId") Integer classGroupId, @Param("courseType") String courseType);
+
+
+    /**
+     * 获取课程的人数
+     *
+     * @param courseIds
+     * @return
+     */
+    List<CourseSchedule> getCourseScheduleStudentNum(@Param("courseIds") List<Long> courseIds);
 }

+ 8 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/MusicGroupPaymentCalenderDetailDao.java

@@ -264,4 +264,12 @@ public interface MusicGroupPaymentCalenderDetailDao extends BaseDAO<Long, MusicG
 	 * @return java.util.List<com.ym.mec.biz.dal.entity.MusicGroup>
 	 */
 	List<MusicGroup> getNoPaymentStudentMusicGroups(@Param("organIds") Set<Integer> organIds);
+
+	/**
+	 * 获取可以缴费,并且未缴费,不是0元的学员
+	 * @param calenderId
+	 * @param studentIds
+	 * @return
+	 */
+	List<MusicGroupPaymentCalenderDetail> queryNoPaymentCanPushByCalenderId(@Param("calenderId") Long calenderId, @Param("studentIds") String studentIds);
 }

+ 47 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/SysExamSongAccompanimentDao.java

@@ -0,0 +1,47 @@
+package com.ym.mec.biz.dal.dao;
+
+
+import com.ym.mec.biz.dal.entity.SysExamSongAccompaniment;
+import com.ym.mec.common.dal.BaseDAO;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+import java.util.Map;
+
+public interface SysExamSongAccompanimentDao extends BaseDAO<Integer, SysExamSongAccompaniment> {
+
+
+    /**
+     * 批量新增
+     * @param sysExamSongAccompaniments
+     * @param sysExamSongId
+     */
+    void batchInsert(@Param("sysExamSongAccompaniments") List<SysExamSongAccompaniment> sysExamSongAccompaniments, @Param("sysExamSongId") Integer sysExamSongId);
+
+    void deleteBySongId(Integer examSongId);
+
+    void batchUpdate(@Param("sysExamSongAccompaniment") List<SysExamSongAccompaniment> sysExamSongAccompaniment);
+
+    /**
+     * 获取已存在的声部
+     * @param sysExamSongId
+     * @param examSongAccIds
+     * @return
+     */
+    List<Integer> findSubjectByExamId(@Param("sysExamSongId") Integer sysExamSongId, @Param("examSongAccIds") List<Integer> examSongAccIds);
+
+    /**
+     * 批量删除
+     * @param delExamSongAccompanimentIds
+     */
+    void batchDel(@Param("delExamSongAccompanimentIds") List<Integer> delExamSongAccompanimentIds);
+
+    /**
+     * 用于学生端,教师端分页查询伴奏列表
+     * @param params
+     * @return
+     */
+    List<SysExamSongAccompaniment> queryAccPage(Map<String, Object> params);
+
+    int findAccCount(Map<String, Object> params);
+}

+ 10 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/SysMusicScoreCategoriesDao.java

@@ -0,0 +1,10 @@
+package com.ym.mec.biz.dal.dao;
+
+
+import com.ym.mec.biz.dal.entity.SysMusicScoreCategories;
+import com.ym.mec.common.dal.BaseDAO;
+
+public interface SysMusicScoreCategoriesDao extends BaseDAO<Integer, SysMusicScoreCategories> {
+
+	
+}

+ 43 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dto/ExamSongDto.java

@@ -0,0 +1,43 @@
+package com.ym.mec.biz.dal.dto;
+
+import com.ym.mec.biz.dal.entity.SysExamSong;
+import com.ym.mec.biz.dal.entity.SysExamSongAccompaniment;
+import io.swagger.annotations.ApiModelProperty;
+
+import java.util.List;
+
+public class ExamSongDto {
+
+    @ApiModelProperty(value = "曲目",required = false)
+    private SysExamSong sysExamSong;
+
+    @ApiModelProperty(value = "伴奏",required = false)
+    private List<SysExamSongAccompaniment> sysExamSongAccompaniments;
+
+    @ApiModelProperty(value = "需要删除的id",required = false)
+    private List<Integer> delExamSongAccompanimentIds;
+
+    public List<Integer> getDelExamSongAccompanimentIds() {
+        return delExamSongAccompanimentIds;
+    }
+
+    public void setDelExamSongAccompanimentIds(List<Integer> delExamSongAccompanimentIds) {
+        this.delExamSongAccompanimentIds = delExamSongAccompanimentIds;
+    }
+
+    public SysExamSong getSysExamSong() {
+        return sysExamSong;
+    }
+
+    public void setSysExamSong(SysExamSong sysExamSong) {
+        this.sysExamSong = sysExamSong;
+    }
+
+    public List<SysExamSongAccompaniment> getSysExamSongAccompaniments() {
+        return sysExamSongAccompaniments;
+    }
+
+    public void setSysExamSongAccompaniments(List<SysExamSongAccompaniment> sysExamSongAccompaniments) {
+        this.sysExamSongAccompaniments = sysExamSongAccompaniments;
+    }
+}

+ 157 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/entity/SysExamSongAccompaniment.java

@@ -0,0 +1,157 @@
+package com.ym.mec.biz.dal.entity;
+
+import org.apache.commons.lang3.builder.ToStringBuilder;
+
+/**
+ * 对应数据库表(sys_exam_song_accompaniment):
+ */
+public class SysExamSongAccompaniment {
+
+	/**  */
+	private Integer id;
+	
+	/**  */
+	private Integer examSongId;
+	
+	/**  */
+	private Integer subjectId;
+
+	/**  */
+	private String subjectName;
+	
+	/**  */
+	private String mp3Url;
+	
+	/**  */
+	private String xmlUrl;
+
+	/**  */
+	private String examSongName;
+
+	/**  */
+	private String type;
+
+	/**  */
+	private String url;
+
+	/**  */
+	private int delFlag;
+
+	private Integer speed;
+	
+	/**  */
+	private java.util.Date createTime;
+	
+	/**  */
+	private java.util.Date updateTime;
+
+	public String getUrl() {
+		return url;
+	}
+
+	public void setUrl(String url) {
+		this.url = url;
+	}
+
+	public String getExamSongName() {
+		return examSongName;
+	}
+
+	public void setExamSongName(String examSongName) {
+		this.examSongName = examSongName;
+	}
+
+	public String getType() {
+		return type;
+	}
+
+	public void setType(String type) {
+		this.type = type;
+	}
+
+	public String getSubjectName() {
+		return subjectName;
+	}
+
+	public void setSubjectName(String subjectName) {
+		this.subjectName = subjectName;
+	}
+
+	public int getDelFlag() {
+		return delFlag;
+	}
+
+	public void setDelFlag(int delFlag) {
+		this.delFlag = delFlag;
+	}
+
+	public Integer getSpeed() {
+		return speed;
+	}
+
+	public void setSpeed(Integer speed) {
+		this.speed = speed;
+	}
+
+	public void setId(Integer id){
+		this.id = id;
+	}
+	
+	public Integer getId(){
+		return this.id;
+	}
+			
+	public void setExamSongId(Integer examSongId){
+		this.examSongId = examSongId;
+	}
+	
+	public Integer getExamSongId(){
+		return this.examSongId;
+	}
+			
+	public void setSubjectId(Integer subjectId){
+		this.subjectId = subjectId;
+	}
+	
+	public Integer getSubjectId(){
+		return this.subjectId;
+	}
+			
+	public void setMp3Url(String mp3Url){
+		this.mp3Url = mp3Url;
+	}
+	
+	public String getMp3Url(){
+		return this.mp3Url;
+	}
+			
+	public void setXmlUrl(String xmlUrl){
+		this.xmlUrl = xmlUrl;
+	}
+	
+	public String getXmlUrl(){
+		return this.xmlUrl;
+	}
+			
+	public void setCreateTime(java.util.Date createTime){
+		this.createTime = createTime;
+	}
+	
+	public java.util.Date getCreateTime(){
+		return this.createTime;
+	}
+			
+	public void setUpdateTime(java.util.Date updateTime){
+		this.updateTime = updateTime;
+	}
+	
+	public java.util.Date getUpdateTime(){
+		return this.updateTime;
+	}
+			
+	@Override
+	public String toString() {
+		return ToStringBuilder.reflectionToString(this);
+	}
+
+}

+ 92 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/entity/SysMusicScoreCategories.java

@@ -0,0 +1,92 @@
+package com.ym.mec.biz.dal.entity;
+
+import org.apache.commons.lang3.builder.ToStringBuilder;
+
+/**
+ * 对应数据库表(sys_music_score_categories):
+ */
+public class SysMusicScoreCategories {
+
+	/**  */
+	private Integer id;
+	
+	/**  */
+	private Integer parentId;
+	
+	/** 名称 */
+	private String name;
+	
+	/** 封面图片 */
+	private String coverImg;
+	
+	/** 操作人 */
+	private Integer operatorId;
+	
+	/**  */
+	private java.util.Date createTime;
+	
+	/**  */
+	private java.util.Date updateTime;
+	
+	public void setId(Integer id){
+		this.id = id;
+	}
+	
+	public Integer getId(){
+		return this.id;
+	}
+			
+	public void setParentId(Integer parentId){
+		this.parentId = parentId;
+	}
+	
+	public Integer getParentId(){
+		return this.parentId;
+	}
+			
+	public void setName(String name){
+		this.name = name;
+	}
+	
+	public String getName(){
+		return this.name;
+	}
+			
+	public void setCoverImg(String coverImg){
+		this.coverImg = coverImg;
+	}
+	
+	public String getCoverImg(){
+		return this.coverImg;
+	}
+			
+	public void setOperatorId(Integer operatorId){
+		this.operatorId = operatorId;
+	}
+	
+	public Integer getOperatorId(){
+		return this.operatorId;
+	}
+			
+	public void setCreateTime(java.util.Date createTime){
+		this.createTime = createTime;
+	}
+	
+	public java.util.Date getCreateTime(){
+		return this.createTime;
+	}
+			
+	public void setUpdateTime(java.util.Date updateTime){
+		this.updateTime = updateTime;
+	}
+	
+	public java.util.Date getUpdateTime(){
+		return this.updateTime;
+	}
+			
+	@Override
+	public String toString() {
+		return ToStringBuilder.reflectionToString(this);
+	}
+
+}

+ 10 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/page/SysExamSongQueryInfo.java

@@ -14,6 +14,16 @@ public class SysExamSongQueryInfo extends QueryInfo {
     @ApiModelProperty(value = "类型",required = true)
     private String type;
 
+    private Integer sysExamSongId;
+
+    public Integer getSysExamSongId() {
+        return sysExamSongId;
+    }
+
+    public void setSysExamSongId(Integer sysExamSongId) {
+        this.sysExamSongId = sysExamSongId;
+    }
+
     public Integer getCreateUserId() {
         return createUserId;
     }

+ 8 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/MusicGroupPaymentCalenderDetailService.java

@@ -104,4 +104,12 @@ public interface MusicGroupPaymentCalenderDetailService extends BaseService<Long
      * @return java.util.List<com.ym.mec.biz.dal.entity.MusicGroup>
      */
     List<MusicGroup> getNoPaymentStudentMusicGroups(String organIds);
+
+    /**
+     * 主动发送学员待续费通知
+     * @param calenderDetailId
+     * @param studentIds
+     * @return
+     */
+    void pushWaitRenewMessage(Long calenderDetailId, String studentIds);
 }

+ 18 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/SysExamSongAccompanimentService.java

@@ -0,0 +1,18 @@
+package com.ym.mec.biz.service;
+
+
+import com.ym.mec.biz.dal.entity.SysExamSongAccompaniment;
+import com.ym.mec.biz.dal.page.SysExamSongQueryInfo;
+import com.ym.mec.common.page.PageInfo;
+import com.ym.mec.common.service.BaseService;
+
+import java.util.List;
+
+public interface SysExamSongAccompanimentService extends BaseService<Integer, SysExamSongAccompaniment> {
+
+    void updateAcc(SysExamSongAccompaniment sysExamSongAccompaniment);
+
+    List<SysExamSongAccompaniment> queryAll(SysExamSongQueryInfo queryInfo);
+
+    List<SysExamSongAccompaniment> queryAccPage(SysExamSongQueryInfo queryInfo);
+}

+ 7 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/SysExamSongService.java

@@ -1,9 +1,16 @@
 package com.ym.mec.biz.service;
 
 
+import com.ym.mec.biz.dal.dto.ExamSongDto;
 import com.ym.mec.biz.dal.entity.SysExamSong;
+import com.ym.mec.biz.dal.page.SysExamSongQueryInfo;
 import com.ym.mec.common.service.BaseService;
 
 public interface SysExamSongService extends BaseService<Integer, SysExamSong> {
 
+    void add(ExamSongDto examSongDto);
+
+    void del(Integer sysExamSongId);
+
+    void updateExamSong(ExamSongDto examSongDto);
 }

+ 8 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/SysMusicScoreCategoriesService.java

@@ -0,0 +1,8 @@
+package com.ym.mec.biz.service;
+
+import com.ym.mec.biz.dal.entity.SysMusicScoreCategories;
+import com.ym.mec.common.service.BaseService;
+
+public interface SysMusicScoreCategoriesService extends BaseService<Integer, SysMusicScoreCategories> {
+
+}

+ 1 - 1
mec-biz/src/main/java/com/ym/mec/biz/service/UploadFileService.java

@@ -32,7 +32,7 @@ public class UploadFileService {
 	private int maxSize;
 
 	/** 支持的扩展名 */
-	@Value("${common.upload.supportExtensions:jpg,jpeg,gif,png,mp3,mid,midi,aac,m4a,mp4}")
+	@Value("${common.upload.supportExtensions:jpg,jpeg,gif,png,mp3,mid,midi,aac,m4a,mp4,xml}")
 	private String supportExtensions;
 
 	/** 文件根目录 */

+ 4 - 1
mec-biz/src/main/java/com/ym/mec/biz/service/impl/CourseScheduleServiceImpl.java

@@ -4421,7 +4421,9 @@ public class CourseScheduleServiceImpl extends BaseServiceImpl<Long, CourseSched
 			if(!CollectionUtils.isEmpty(courseMergeCourseNum)){
 				courseMergeCourseNumMap = MapUtil.convertIntegerMap(courseMergeCourseNum);
 			}
-
+			//获取课程的预计人数
+			List<CourseSchedule> courseScheduleStudentNum = courseScheduleStudentPaymentDao.getCourseScheduleStudentNum(courseScheduleIds);
+			Map<Long, Integer> courseScheduleStudentNumMap = courseScheduleStudentNum.stream().collect(Collectors.toMap(CourseSchedule::getId, CourseSchedule::getStudentNum));
 			//获取班级声部名称
             List<Map<Integer, String>> classGroupSubjectNameMaps = classGroupDao.findClassGroupSubjectNameMaps(courseScheduleIds);
             Map<Integer, String> classGroupSubjectNameMap = MapUtil.convertIntegerMap(classGroupSubjectNameMaps);
@@ -4433,6 +4435,7 @@ public class CourseScheduleServiceImpl extends BaseServiceImpl<Long, CourseSched
 				if(courseMergeCourseNumMap.containsKey(result.getId())){
 					result.setBeMerged(courseMergeCourseNumMap.get(result.getId())>0?true:false);
 				}
+				result.setStudentNum(courseScheduleStudentNumMap.getOrDefault(result.getId(), 0));
 			}
         }
         pageInfo.setRows(results);

+ 26 - 1
mec-biz/src/main/java/com/ym/mec/biz/service/impl/MusicGroupPaymentCalenderDetailServiceImpl.java

@@ -93,6 +93,7 @@ public class MusicGroupPaymentCalenderDetailServiceImpl extends BaseServiceImpl<
 //				throw new BizException("修改失败:存在未开启缴费的学员");
 //			}
 //		}
+		//为了解决学员欠费数量的问题,只要学员没有缴费就可以修改金额
 		Set<Integer> studentIds = new HashSet<>();
 				calenderDetails.forEach(e->{
 			if(e.getPaymentStatus() == null || e.getPaymentStatus() != NON_PAYMENT){
@@ -411,7 +412,7 @@ public class MusicGroupPaymentCalenderDetailServiceImpl extends BaseServiceImpl<
 		Long musicGroupPaymentCalenderId = null;
 		for(MusicGroupPaymentCalender musicGroupPaymentCalender : musicGroupPaymentCalenderList){
 			int paymentNum = 0;
-			
+
 			musicGroupPaymentCalenderId = musicGroupPaymentCalender.getId();
 			
 			if(musicGroupPaymentCalender.getPaymentType() == MusicGroupPaymentCalender.PaymentType.MUSIC_APPLY){
@@ -594,4 +595,28 @@ public class MusicGroupPaymentCalenderDetailServiceImpl extends BaseServiceImpl<
 		}
 		return musicGroupPaymentCalenderDetailDao.getNoPaymentStudentMusicGroups(organIds);
 	}
+
+	@Override
+	public void pushWaitRenewMessage(Long calenderId, String studentIds) {
+		List<MusicGroupPaymentCalenderDetail> calenderDetails = musicGroupPaymentCalenderDetailDao.queryNoPaymentCanPushByCalenderId(calenderId,studentIds);
+		if(calenderDetails == null || calenderDetails.size() == 0){
+			throw new BizException("发送失败:没有可以发送缴费提醒的学员");
+		}
+		MusicGroupPaymentCalender paymentCalender = musicGroupPaymentCalenderDao.get(calenderId);
+		//未缴费
+		HashSet<String> strings = new HashSet<>(Arrays.asList(studentIds.split(",")));
+		Map<Integer,String> studentMaps = MapUtil.convertMybatisMap(musicGroupPaymentCalenderDetailDao.queryNoPaymentAndNotZeroStudent(calenderId,strings));
+		MusicGroup musicGroup = musicGroupDao.get(paymentCalender.getMusicGroupId());
+		String baseUrl = sysConfigDao.findConfigValue(SysConfigService.BASE_API_URL);
+		String memo = "4?" + baseUrl + "/#/musicGroupRenew?calenderId="+calenderId+"&id=" + musicGroup.getId();
+		Map<Integer, String> push = new HashMap<>();
+		for (String userId : strings) {
+			push.put(Integer.parseInt(userId), userId);
+		}
+		// 发送续费通知
+		sysMessageService.batchSendMessage(MessageSenderPluginContext.MessageSender.JIGUANG, MessageTypeEnum.STUDENT_PUSH_WAIT_RENEW_MESSAGE, push,
+				null, 0, memo, "STUDENT", musicGroup.getName());
+		sysMessageService.batchSendMessage(MessageSenderPluginContext.MessageSender.AWSMS, MessageTypeEnum.STUDENT_SMS_WAIT_RENEW_MESSAGE, studentMaps,
+				null, 0, memo, null, musicGroup.getName());
+	}
 }

+ 63 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/SysExamSongAccompanimentServiceImpl.java

@@ -0,0 +1,63 @@
+package com.ym.mec.biz.service.impl;
+
+
+import com.ym.mec.biz.dal.dao.SysExamSongAccompanimentDao;
+import com.ym.mec.biz.dal.entity.SysExamSongAccompaniment;
+import com.ym.mec.biz.dal.page.SysExamSongQueryInfo;
+import com.ym.mec.biz.service.SysExamSongAccompanimentService;
+import com.ym.mec.common.dal.BaseDAO;
+import com.ym.mec.common.exception.BizException;
+import com.ym.mec.common.page.PageInfo;
+import com.ym.mec.common.service.impl.BaseServiceImpl;
+import com.ym.mec.util.collection.MapUtil;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+
+@Service
+public class SysExamSongAccompanimentServiceImpl extends BaseServiceImpl<Integer, SysExamSongAccompaniment> implements SysExamSongAccompanimentService {
+	
+	@Autowired
+	private SysExamSongAccompanimentDao sysExamSongAccompanimentDao;
+
+	@Override
+	public BaseDAO<Integer, SysExamSongAccompaniment> getDAO() {
+		return sysExamSongAccompanimentDao;
+	}
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void updateAcc(SysExamSongAccompaniment sysExamSongAccompaniment) {
+		SysExamSongAccompaniment accompaniment = sysExamSongAccompanimentDao.get(sysExamSongAccompaniment.getId());
+		if(accompaniment == null){
+			throw new BizException("操作失败:伴奏信息不存在");
+		}
+		List<Integer> idList = new ArrayList<>();
+		idList.add(accompaniment.getId());
+		List<Integer> subjectIds = sysExamSongAccompanimentDao.findSubjectByExamId(accompaniment.getExamSongId(),idList);
+		if(subjectIds.size() > 0 && subjectIds.contains(accompaniment.getId())){
+			throw new BizException("操作失败:请勿提交重复的伴奏声部");
+		}
+		sysExamSongAccompanimentDao.update(sysExamSongAccompaniment);
+	}
+
+	@Override
+	public List<SysExamSongAccompaniment> queryAll(SysExamSongQueryInfo queryInfo) {
+		Map<String, Object> params = new HashMap<>();
+		MapUtil.populateMap(params, queryInfo);
+		return sysExamSongAccompanimentDao.queryPage(params);
+	}
+
+	@Override
+	public List<SysExamSongAccompaniment> queryAccPage(SysExamSongQueryInfo queryInfo) {
+		Map<String, Object> params = new HashMap<String, Object>();
+		MapUtil.populateMap(params, queryInfo);
+		return sysExamSongAccompanimentDao.queryAccPage(params);
+	}
+}

+ 75 - 1
mec-biz/src/main/java/com/ym/mec/biz/service/impl/SysExamSongServiceImpl.java

@@ -1,23 +1,97 @@
 package com.ym.mec.biz.service.impl;
 
 
+import com.ym.mec.auth.api.client.SysUserFeignService;
+import com.ym.mec.auth.api.entity.SysUser;
+import com.ym.mec.biz.dal.dao.SysExamSongAccompanimentDao;
 import com.ym.mec.biz.dal.dao.SysExamSongDao;
+import com.ym.mec.biz.dal.dto.ExamSongDto;
 import com.ym.mec.biz.dal.entity.SysExamSong;
+import com.ym.mec.biz.dal.entity.SysExamSongAccompaniment;
 import com.ym.mec.biz.service.SysExamSongService;
 import com.ym.mec.common.dal.BaseDAO;
+import com.ym.mec.common.exception.BizException;
 import com.ym.mec.common.service.impl.BaseServiceImpl;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.List;
+import java.util.stream.Collectors;
 
 @Service
 public class SysExamSongServiceImpl extends BaseServiceImpl<Integer, SysExamSong> implements SysExamSongService {
 	
 	@Autowired
 	private SysExamSongDao sysExamSongDao;
+	@Autowired
+	private SysExamSongAccompanimentDao sysExamSongAccompanimentDao;
+	@Autowired
+	private SysUserFeignService sysUserFeignService;
 
 	@Override
 	public BaseDAO<Integer, SysExamSong> getDAO() {
 		return sysExamSongDao;
 	}
-	
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void add(ExamSongDto examSongDto) {
+		SysUser sysUser = sysUserFeignService.queryUserInfo();
+		if(sysUser == null){
+			throw new BizException("请登录");
+		}
+		SysExamSong sysExamSong = examSongDto.getSysExamSong();
+		sysExamSong.setCreateUserId(sysUser.getId());
+		sysExamSongDao.insert(sysExamSong);
+		List<SysExamSongAccompaniment> sysExamSongAccompaniment = examSongDto.getSysExamSongAccompaniments();
+		if(sysExamSongAccompaniment != null && sysExamSongAccompaniment.size() > 0){
+			sysExamSongAccompanimentDao.batchInsert(sysExamSongAccompaniment,sysExamSong.getId());
+		}
+	}
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void del(Integer sysExamSongId) {
+		sysExamSongDao.delete(sysExamSongId);
+		sysExamSongAccompanimentDao.deleteBySongId(sysExamSongId);
+	}
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void updateExamSong(ExamSongDto examSongDto) {
+		SysExamSong sysExamSong = examSongDto.getSysExamSong();
+		sysExamSongDao.update(sysExamSong);
+		List<Integer> delExamSongAccompanimentIds = examSongDto.getDelExamSongAccompanimentIds();
+		if(delExamSongAccompanimentIds != null && delExamSongAccompanimentIds.size() > 0){
+			sysExamSongAccompanimentDao.batchDel(delExamSongAccompanimentIds);
+		}
+		List<SysExamSongAccompaniment> sysExamSongAccompaniment = examSongDto.getSysExamSongAccompaniments();
+		if(sysExamSongAccompaniment != null && sysExamSongAccompaniment.size() > 0){
+			List<Integer> subjectIdList = sysExamSongAccompaniment.stream().map(e -> e.getSubjectId()).collect(Collectors.toList());
+			subjectIdList.removeAll(Collections.singleton(null));
+			if(subjectIdList.size() > 0){
+				List<Integer> idList = sysExamSongAccompaniment.stream().map(e -> e.getId()).collect(Collectors.toList());
+				List<Integer> subjectIds = sysExamSongAccompanimentDao.findSubjectByExamId(sysExamSong.getId(),idList);
+				int subjectSize = subjectIds.size() + subjectIdList.size();
+				subjectIdList.addAll(subjectIds);
+				int size = new HashSet<>(subjectIdList).size();
+				if(size < subjectSize){
+					throw new BizException("操作失败:请勿提交重复的伴奏声部");
+				}
+			}
+			//获取需要修改的伴奏
+			List<SysExamSongAccompaniment> updateCollect = sysExamSongAccompaniment.stream().filter(e -> e.getId() != null).collect(Collectors.toList());
+			if(updateCollect.size() > 0){
+				sysExamSongAccompanimentDao.batchUpdate(updateCollect);
+			}
+			//获取需要新增的伴奏
+			List<SysExamSongAccompaniment> addCollect = sysExamSongAccompaniment.stream().filter(e -> e.getId() == null).collect(Collectors.toList());
+			if(addCollect.size() > 0){
+				sysExamSongAccompanimentDao.batchInsert(addCollect,sysExamSong.getId());
+			}
+		}
+	}
 }

+ 23 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/SysMusicScoreCategoriesServiceImpl.java

@@ -0,0 +1,23 @@
+package com.ym.mec.biz.service.impl;
+
+
+import com.ym.mec.biz.dal.dao.SysMusicScoreCategoriesDao;
+import com.ym.mec.biz.dal.entity.SysMusicScoreCategories;
+import com.ym.mec.biz.service.SysMusicScoreCategoriesService;
+import com.ym.mec.common.dal.BaseDAO;
+import com.ym.mec.common.service.impl.BaseServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class SysMusicScoreCategoriesServiceImpl extends BaseServiceImpl<Integer, SysMusicScoreCategories> implements SysMusicScoreCategoriesService {
+	
+	@Autowired
+	private SysMusicScoreCategoriesDao sysMusicScoreCategoriesDao;
+
+	@Override
+	public BaseDAO<Integer, SysMusicScoreCategories> getDAO() {
+		return sysMusicScoreCategoriesDao;
+	}
+	
+}

+ 7 - 0
mec-biz/src/main/resources/config/mybatis/CourseScheduleStudentPaymentMapper.xml

@@ -722,4 +722,11 @@
 		  AND cs.type_ = #{courseType}
 	  </if>
 	</select>
+    <select id="getCourseScheduleStudentNum" resultMap="com.ym.mec.biz.dal.dao.CourseScheduleDao.CourseSchedule">
+		SELECT course_schedule_id_ id_,COUNT(*) student_num_ FROM course_schedule_student_payment WHERE course_schedule_id_ IN
+		<foreach collection="courseIds" item="courseId" open="(" close=")" separator=",">
+			#{courseId}
+		</foreach>
+		GROUP BY course_schedule_id_
+	</select>
 </mapper>

+ 7 - 0
mec-biz/src/main/resources/config/mybatis/MusicGroupPaymentCalenderDetailMapper.xml

@@ -510,6 +510,13 @@
 				</foreach>
 			</if>
 	</select>
+	<select id="queryNoPaymentCanPushByCalenderId"
+			resultMap="MusicGroupPaymentCalenderDetail">
+		SELECT mgpcd.* FROM music_group_payment_calender_detail mgpcd
+		LEFT JOIN music_group_payment_calender mgpc ON mgpc.id_ = mgpcd.music_group_payment_calender_id_
+		WHERE (mgpc.status_ = 'OPEN' OR mgpcd.open_ = 1) AND mgpcd.payment_status_ = 'NON_PAYMENT' AND mgpcd.expect_amount_ != 0
+		AND mgpcd.music_group_payment_calender_id_ = #{calenderId} AND FIND_IN_SET(mgpcd.user_id_,#{studentIds})
+	</select>
 
     <update id="updateNoPaymentAndZeroPaymentStatus">
 		UPDATE music_group_payment_calender_detail mgpcd

+ 198 - 0
mec-biz/src/main/resources/config/mybatis/SysExamSongAccompanimentMapper.xml

@@ -0,0 +1,198 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<!--
+这个文件是自动生成的。
+不要修改此文件。所有改动将在下次重新自动生成时丢失。
+-->
+<mapper namespace="com.ym.mec.biz.dal.dao.SysExamSongAccompanimentDao">
+	
+	<resultMap type="com.ym.mec.biz.dal.entity.SysExamSongAccompaniment" id="SysExamSongAccompaniment">
+		<result column="id_" property="id" />
+		<result column="exam_song_id_" property="examSongId" />
+		<result column="subject_id_" property="subjectId" />
+		<result column="subject_name_" property="subjectName" />
+		<result column="mp3_url_" property="mp3Url" />
+		<result column="xml_url_" property="xmlUrl" />
+		<result column="name_" property="examSongName" />
+		<result column="type_" property="type" />
+		<result column="url_" property="url" />
+		<result column="del_flag_" property="delFlag" />
+		<result column="speed_" property="speed" />
+		<result column="create_time_" property="createTime" />
+		<result column="update_time_" property="updateTime" />
+	</resultMap>
+	
+	<!-- 根据主键查询一条记录 -->
+	<select id="get" resultMap="SysExamSongAccompaniment" >
+		SELECT sesa.*,ses.name_,ses.type_,ses.url_
+		FROM sys_exam_song_accompaniment sesa
+		LEFT JOIN sys_exam_song ses ON ses.id_ = sesa.exam_song_id_
+		WHERE sesa.id_ = #{id}
+	</select>
+	
+	<!-- 全查询 -->
+	<select id="findAll" resultMap="SysExamSongAccompaniment">
+		SELECT * FROM sys_exam_song_accompaniment ORDER BY id_
+	</select>
+	
+	<!-- 向数据库增加一条记录 -->
+	<insert id="insert" parameterType="com.ym.mec.biz.dal.entity.SysExamSongAccompaniment" useGeneratedKeys="true" keyColumn="id" keyProperty="id">
+		INSERT INTO sys_exam_song_accompaniment (exam_song_id_,subject_id_,mp3_url_,xml_url_,speed_,create_time_,update_time_)
+		VALUES(#{examSongId},#{subjectId},#{mp3Url},#{xmlUrl},#{speed},NOW(),NOW())
+	</insert>
+	<insert id="batchInsert">
+		INSERT INTO sys_exam_song_accompaniment (exam_song_id_,subject_id_,mp3_url_,xml_url_,speed_,create_time_,update_time_)
+		VALUES
+		<foreach collection="sysExamSongAccompaniments" item="item"  separator=",">
+			(#{sysExamSongId},#{item.subjectId},#{item.mp3Url},#{item.xmlUrl},#{item.speed},NOW(),NOW())
+		</foreach>
+	</insert>
+
+	<!-- 根据主键查询一条记录 -->
+	<update id="update" parameterType="com.ym.mec.biz.dal.entity.SysExamSongAccompaniment">
+		UPDATE sys_exam_song_accompaniment <set>
+		<if test="subjectId != null">
+		subject_id_ = #{subjectId},
+		</if>
+		<if test="speed != null">
+			speed_ = #{speed},
+		</if>
+		<if test="xmlUrl != null">
+		xml_url_ = #{xmlUrl},
+		</if>
+		<if test="examSongId != null">
+		exam_song_id_ = #{examSongId},
+		</if>
+		<if test="mp3Url != null">
+		mp3_url_ = #{mp3Url},
+		</if>
+		update_time_ = NOW()
+	</set> WHERE id_ = #{id}
+	</update>
+	
+	<!-- 根据主键删除一条记录 -->
+	<update id="delete" >
+		UPDATE sys_exam_song_accompaniment SET del_flag_ = 1,update_time_ = NOW() WHERE id_ = #{id}
+	</update>
+
+	<!-- 根据主键删除一条记录 -->
+	<update id="deleteBySongId" >
+		UPDATE sys_exam_song_accompaniment SET del_flag_ = 1,update_time_ = NOW() WHERE exam_song_id_ = #{examSongId}
+	</update>
+	<update id="batchUpdate">
+		<foreach collection="sysExamSongAccompaniment" item="item" separator=";">
+			UPDATE sys_exam_song_accompaniment
+			<set>
+			<if test="item.speed != null">
+				speed_ = #{item.speed},
+			</if>
+			<if test="item.subjectId != null">
+				subject_id_ = #{item.subjectId},
+			</if>
+			<if test="item.xmlUrl != null">
+				xml_url_ = #{item.xmlUrl},
+			</if>
+			<if test="item.examSongId != null">
+				exam_song_id_ = #{item.examSongId},
+			</if>
+			<if test="item.mp3Url != null">
+				mp3_url_ = #{item.mp3Url},
+			</if>
+			update_time_ = NOW()
+		</set> WHERE id_ = #{item.id}
+		</foreach>
+	</update>
+    <update id="batchDel">
+		UPDATE sys_exam_song_accompaniment SET del_flag_ = 1,update_time_ = NOW() WHERE id_ IN
+		<foreach collection="delExamSongAccompanimentIds" item="item" open="(" close=")" separator=",">
+			#{item}
+		</foreach>
+
+	</update>
+
+    <!-- 分页查询 -->
+	<select id="queryPage" resultMap="SysExamSongAccompaniment" parameterType="map">
+		SELECT sesa.*,s.name_ subject_name_
+		FROM sys_exam_song_accompaniment sesa
+		LEFT JOIN `subject` s ON s.id_ = sesa.subject_id_
+		<where>
+			sesa.del_flag_ = 0
+			<if test="subjectId != null">
+				AND sesa.subject_id_ = #{subjectId}
+			</if>
+			<if test="sysExamSongId != null">
+				AND sesa.exam_song_id_ = #{sysExamSongId}
+			</if>
+		</where>
+		ORDER BY sesa.id_ DESC
+		<include refid="global.limit"/>
+	</select>
+	
+	<!-- 查询当前表的总记录数 -->
+	<select id="queryCount" resultType="int">
+		SELECT COUNT(*) FROM sys_exam_song_accompaniment
+	</select>
+
+	<select id="findSubjectByExamId" resultType="java.lang.Integer">
+		SELECT subject_id_ FROM sys_exam_song_accompaniment
+		<where>
+				del_flag_ = 0
+			<if test="sysExamSongId != null">
+				AND exam_song_id_ = #{sysExamSongId}
+			</if>
+			<if test="examSongAccIds != null and examSongAccIds.size > 0">
+				AND id_ NOT IN
+				<foreach collection="examSongAccIds" open="(" close=")" item="item" separator=",">
+					#{item}
+				</foreach>
+			</if>
+		</where>
+	</select>
+	<select id="queryAccPage" resultMap="SysExamSongAccompaniment">
+		SELECT sesa.*,ses.name_,ses.type_,ses.url_,s.name_ subject_name_
+		FROM sys_exam_song_accompaniment sesa
+		LEFT JOIN sys_exam_song ses ON ses.id_ = sesa.exam_song_id_
+		LEFT JOIN subject s ON s.id_ = sesa.subject_id_
+		<include refid="queryPageSql"/>
+	</select>
+	<select id="findAccCount" resultType="java.lang.Integer">
+		SELECT COUNT(DISTINCT sesa.id_) FROM sys_exam_song_accompaniment sesa
+		LEFT JOIN sys_exam_song ses ON ses.id_ = sesa.exam_song_id_
+		<include refid="queryPageSql"/>
+	</select>
+	<sql id="queryPageSql">
+		<where>
+			sesa.del_flag_ = 0
+			<if test="search != null and search != ''">
+				AND (sesa.id_ = #{search} OR ses.name_ LIKE CONCAT('%',#{search},'%'))
+			</if>
+			<if test="sysExamSongId != null">
+				AND sesa.exam_song_id_ = #{sysExamSongId}
+			</if>
+			<if test="subjectId != null">
+				AND sesa.subject_id_ = #{subjectId}
+			</if>
+			<if test="type != null and type == 'COMMON'">
+				AND ses.type_ = #{type}
+			</if>
+			<if test="type != null and type == 'ALL'">
+				<if test="createUserId != null">
+					AND (ses.type_ = 'COMMON' OR (ses.create_user_id_ = #{createUserId} AND ses.type_ = 'PERSON'))
+				</if>
+			</if>
+			<if test="type != null and type == 'PERSON'">
+				<if test="createUserId != null">
+					AND ses.type_ = #{type} AND ses.create_user_id_ = #{createUserId}
+				</if>
+				<if test="createUserId == null">
+					AND ses.type_ = #{type}
+				</if>
+			</if>
+			<if test="type == null or type == ''">
+				<if test="createUserId != null">
+					AND ses.create_user_id_ = #{createUserId}
+				</if>
+			</if>
+		</where>
+	</sql>
+</mapper>

+ 5 - 6
mec-biz/src/main/resources/config/mybatis/SysExamSongMapper.xml

@@ -62,7 +62,9 @@
 		<if test="speed != null">
 		speed_ = #{speed},
 		</if>
-		update_time_ = NOW()
+		<if test="updateTime != null">
+			update_time_ = NOW()
+		</if>
 		</set>
 		 WHERE id_ = #{id}
 	</update>
@@ -98,16 +100,13 @@
 					AND ses.create_user_id_ = #{createUserId}
 				</if>
 			</if>
-			<if test="subjectId != null">
-				AND FIND_IN_SET(#{subjectId},ses.subject_ids_)
-			</if>
 		</where>
 	</sql>
 	<!-- 分页查询 -->
 	<select id="queryPage" resultMap="SysExamSong" parameterType="map">
-		SELECT ses.*,GROUP_CONCAT(s.name_) subject_names_,su.real_name_ create_user_name_ FROM sys_exam_song ses
+		SELECT ses.*,su.real_name_ create_user_name_
+		FROM sys_exam_song ses
 		LEFT JOIN sys_user su ON ses.create_user_id_ = su.id_
-		LEFT JOIN `subject` s ON FIND_IN_SET(s.id_,ses.subject_ids_)
 		<include refid="queryPageSql"/>
 		GROUP BY ses.id_
 		ORDER BY ses.id_ DESC

+ 73 - 0
mec-biz/src/main/resources/config/mybatis/SysMusicScoreCategoriesMapper.xml

@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<!--
+这个文件是自动生成的。
+不要修改此文件。所有改动将在下次重新自动生成时丢失。
+-->
+<mapper namespace="com.ym.mec.biz.dal.dao.SysMusicScoreCategoriesDao">
+	
+	<resultMap type="com.ym.mec.biz.dal.entity.SysMusicScoreCategories" id="SysMusicScoreCategories">
+		<result column="id_" property="id" />
+		<result column="parent_id_" property="parentId" />
+		<result column="name_" property="name" />
+		<result column="cover_img_" property="coverImg" />
+		<result column="operator_id_" property="operatorId" />
+		<result column="create_time_" property="createTime" />
+		<result column="update_time_" property="updateTime" />
+	</resultMap>
+	
+	<!-- 根据主键查询一条记录 -->
+	<select id="get" resultMap="SysMusicScoreCategories" >
+		SELECT * FROM sys_music_score_categories WHERE id_ = #{id} 
+	</select>
+	
+	<!-- 全查询 -->
+	<select id="findAll" resultMap="SysMusicScoreCategories">
+		SELECT * FROM sys_music_score_categories ORDER BY id_
+	</select>
+	
+	<!-- 向数据库增加一条记录 -->
+	<insert id="insert" parameterType="com.ym.mec.biz.dal.entity.SysMusicScoreCategories" useGeneratedKeys="true" keyColumn="id" keyProperty="id">
+		INSERT INTO sys_music_score_categories (parent_id_,name_,cover_img_,operator_id_,create_time_,update_time_)
+		VALUES(#{parentId},#{name},#{coverImg},#{operatorId},NOW(),NOW())
+	</insert>
+	
+	<!-- 根据主键查询一条记录 -->
+	<update id="update" parameterType="com.ym.mec.biz.dal.entity.SysMusicScoreCategories">
+		UPDATE sys_music_score_categories <set>
+			<if test="parentId != null">
+			parent_id_ = #{parentId},
+			</if>
+			<if test="operatorId != null">
+			operator_id_ = #{operatorId},
+			</if>
+			<if test="coverImg != null">
+			cover_img_ = #{coverImg},
+			</if>
+			<if test="id != null">
+			id_ = #{id},
+			</if>
+			<if test="updateTime != null">
+			update_time_ = #{updateTime},
+			</if>
+			<if test="name != null">
+			name_ = #{name},
+			</if>
+			</set> WHERE id_ = #{id}
+	</update>
+	
+	<!-- 根据主键删除一条记录 -->
+	<delete id="delete" >
+		DELETE FROM sys_music_score_categories WHERE id_ = #{id} 
+	</delete>
+	
+	<!-- 分页查询 -->
+	<select id="queryPage" resultMap="SysMusicScoreCategories" parameterType="map">
+		SELECT * FROM sys_music_score_categories ORDER BY id_ <include refid="global.limit"/>
+	</select>
+	
+	<!-- 查询当前表的总记录数 -->
+	<select id="queryCount" resultType="int">
+		SELECT COUNT(*) FROM sys_music_score_categories
+	</select>
+</mapper>

+ 33 - 0
mec-student/src/main/java/com/ym/mec/student/controller/SysExamSongAccompanimentController.java

@@ -0,0 +1,33 @@
+package com.ym.mec.student.controller;
+
+import com.ym.mec.biz.dal.entity.SysExamSongAccompaniment;
+import com.ym.mec.biz.dal.page.SysExamSongQueryInfo;
+import com.ym.mec.biz.service.SysExamSongAccompanimentService;
+import com.ym.mec.common.controller.BaseController;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+@RequestMapping("sysExamSongAccompaniment")
+@Api(tags = "曲库伴奏服务")
+@RestController
+public class SysExamSongAccompanimentController extends BaseController {
+
+    @Autowired
+    private SysExamSongAccompanimentService sysExamSongAccompanimentService;
+
+    @ApiOperation(value = "分页查询")
+    @GetMapping("/queryPage")
+    public Object queryPage(SysExamSongQueryInfo queryInfo) {
+        queryInfo.setType("COMMON");
+        return succeed(sysExamSongAccompanimentService.queryAccPage(queryInfo));
+    }
+
+    @ApiOperation(value = "详情")
+    @GetMapping("/getDetail")
+    public Object queryPage(Integer id) {
+        return succeed(sysExamSongAccompanimentService.get(id));
+    }
+
+}

+ 63 - 0
mec-teacher/src/main/java/com/ym/mec/teacher/controller/SysExamSongAccompanimentController.java

@@ -0,0 +1,63 @@
+package com.ym.mec.teacher.controller;
+
+import com.ym.mec.auth.api.client.SysUserFeignService;
+import com.ym.mec.auth.api.entity.SysUser;
+import com.ym.mec.biz.dal.entity.SysExamSongAccompaniment;
+import com.ym.mec.biz.dal.page.SysExamSongQueryInfo;
+import com.ym.mec.biz.service.SysExamSongAccompanimentService;
+import com.ym.mec.common.controller.BaseController;
+import com.ym.mec.common.exception.BizException;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import io.swagger.annotations.ApiParam;
+import org.apache.commons.lang3.StringUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+@RequestMapping("sysExamSongAccompaniment")
+@Api(tags = "曲库伴奏服务")
+@RestController
+public class SysExamSongAccompanimentController extends BaseController {
+
+    @Autowired
+    private SysExamSongAccompanimentService sysExamSongAccompanimentService;
+    @Autowired
+    private SysUserFeignService sysUserFeignService;
+
+    @ApiOperation(value = "修改")
+    @PostMapping("/update")
+    public Object update(@RequestBody SysExamSongAccompaniment sysExamSongAccompaniment) {
+        sysExamSongAccompanimentService.updateAcc(sysExamSongAccompaniment);
+        return succeed();
+    }
+
+    @ApiOperation(value = "删除")
+    @PostMapping("/del/{id}")
+    public Object del(@ApiParam(value = "收费类型编号", required = true) @PathVariable("id") Integer id) {
+        sysExamSongAccompanimentService.delete(id);
+        return succeed();
+    }
+
+    @ApiOperation(value = "分页查询")
+    @GetMapping("/queryPage")
+    public Object queryPage(SysExamSongQueryInfo queryInfo) {
+        String type = queryInfo.getType();
+        if(StringUtils.isEmpty(type)){
+            queryInfo.setType("ALL");
+        }
+        SysUser sysUser = sysUserFeignService.queryUserInfo();
+        if(sysUser == null){
+            throw new BizException("请登录");
+        }
+        queryInfo.setCreateUserId(sysUser.getId());
+        return succeed(sysExamSongAccompanimentService.queryAccPage(queryInfo));
+    }
+
+    @ApiOperation(value = "详情")
+    @GetMapping("/getDetail")
+    public Object getDetail(Integer id) {
+        return succeed(sysExamSongAccompanimentService.get(id));
+    }
+
+}

+ 4 - 15
mec-teacher/src/main/java/com/ym/mec/teacher/controller/SysExamSongController.java

@@ -2,6 +2,7 @@ package com.ym.mec.teacher.controller;
 
 import com.ym.mec.auth.api.client.SysUserFeignService;
 import com.ym.mec.auth.api.entity.SysUser;
+import com.ym.mec.biz.dal.dto.ExamSongDto;
 import com.ym.mec.biz.dal.entity.SysExamSong;
 import com.ym.mec.biz.dal.page.SysExamSongQueryInfo;
 import com.ym.mec.biz.service.SysExamSongService;
@@ -25,29 +26,17 @@ public class SysExamSongController extends BaseController {
     @Autowired
     private SysUserFeignService sysUserFeignService;
 
-    @ApiOperation(value = "修改")
-    @PostMapping("/update")
-    public Object update(@RequestBody SysExamSong sysExamSong) {
-        sysExamSongService.update(sysExamSong);
-        return succeed();
-    }
-
     @ApiOperation(value = "新增")
     @PostMapping("/add")
-    public Object add(@RequestBody SysExamSong sysExamSong) {
-        SysUser sysUser = sysUserFeignService.queryUserInfo();
-        if(sysUser == null){
-            throw new BizException("请登录");
-        }
-        sysExamSong.setCreateUserId(sysUser.getId());
-        sysExamSongService.insert(sysExamSong);
+    public Object add(@RequestBody ExamSongDto examSongDto) {
+        sysExamSongService.add(examSongDto);
         return succeed();
     }
 
     @ApiOperation(value = "删除")
     @PostMapping("/del")
     public Object del(Integer id) {
-        sysExamSongService.delete(id);
+        sysExamSongService.del(id);
         return succeed();
     }
 

+ 47 - 0
mec-teacher/src/main/java/com/ym/mec/teacher/controller/SysMusicScoreCategoriesController.java

@@ -0,0 +1,47 @@
+package com.ym.mec.teacher.controller;
+
+import com.ym.mec.biz.dal.entity.SysMusicScoreCategories;
+import com.ym.mec.biz.service.SysMusicScoreCategoriesService;
+import com.ym.mec.common.controller.BaseController;
+import com.ym.mec.common.page.QueryInfo;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+@RequestMapping("sysMusicScoreCategorie")
+@Api(tags = "曲库服务")
+@RestController
+public class SysMusicScoreCategoriesController extends BaseController {
+
+    @Autowired
+    private SysMusicScoreCategoriesService sysMusicScoreCategoriesService;
+
+    @ApiOperation(value = "新增")
+    @PostMapping("/add")
+    public Object add(SysMusicScoreCategories sysMusicScoreCategories) {
+        sysMusicScoreCategoriesService.insert(sysMusicScoreCategories);
+        return succeed();
+    }
+
+    @ApiOperation(value = "修改")
+    @PostMapping("/update")
+    public Object update(SysMusicScoreCategories sysMusicScoreCategories) {
+        sysMusicScoreCategoriesService.update(sysMusicScoreCategories);
+        return succeed();
+    }
+
+    @ApiOperation(value = "删除")
+    @PostMapping("/del")
+    public Object del(Integer id) {
+        sysMusicScoreCategoriesService.delete(id);
+        return succeed();
+    }
+
+    @ApiOperation(value = "分页查询")
+    @GetMapping("/queryPage")
+    public Object queryPage(QueryInfo queryInfo) {
+        return succeed(sysMusicScoreCategoriesService.queryPage(queryInfo));
+    }
+
+}

+ 2 - 2
mec-web/src/main/java/com/ym/mec/web/controller/ExportController.java

@@ -860,9 +860,9 @@ public class ExportController extends BaseController {
         try {
             HSSFWorkbook workbook = POIUtil.exportExcel(new String[]{"分部名称", "课程编号", "开始时间", "结束时间",
                     "班级名称", "班级声部", "课程名称", "课程类型", "教学模式",
-                    "教学点", "课程状态", "指导老师", "学员编号", "是否点名", "是否有考勤申诉"}, new String[]{
+                    "教学点", "课程状态", "指导老师", "学员编号", "是否点名", "是否有考勤申诉","预计上课人数"}, new String[]{
                     "organName", "id", "startClassTime", "endClassTime", "classGroupName", "subjectName", "name",
-                    "groupType.desc", "teachMode.msg", "schoolName", "status.msg", "teacherName", "studentId", "isCallNames.msg", "isComplaints"}, rows);
+                    "groupType.desc", "teachMode.msg", "schoolName", "status.msg", "teacherName", "studentId", "isCallNames.msg", "isComplaints","studentNum"}, rows);
             response.setContentType("application/octet-stream");
             response.setHeader("Content-Disposition", "attachment;filename=lender-" + DateUtil.getDate(new Date()) + ".xls");
             ouputStream = response.getOutputStream();

+ 8 - 0
mec-web/src/main/java/com/ym/mec/web/controller/MusicGroupPaymentCalenderDetailController.java

@@ -16,6 +16,7 @@ import io.swagger.annotations.ApiOperation;
 import java.math.BigDecimal;
 import java.util.Arrays;
 import java.util.List;
+import java.util.Set;
 
 import org.apache.commons.lang3.StringUtils;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -105,6 +106,13 @@ public class MusicGroupPaymentCalenderDetailController extends BaseController {
         return succeed;
     }
 
+    @ApiOperation(value = "发送学员待续费通知")
+    @PostMapping("/sendWaitRenewMessage")
+    @PreAuthorize("@pcs.hasPermissions('musicGroupPaymentCalenderDetail/sendWaitRenewMessage')")
+    public HttpResponseResult sendWaitRenewMessage(Long calenderDetailId, String studentIds) {
+        musicGroupPaymentCalenderDetailService.pushWaitRenewMessage(calenderDetailId,studentIds);
+        return succeed();
+    }
 
     @ApiOperation(value = "未缴费学员列表")
     @GetMapping("/queryArrearageStudents")

+ 8 - 1
mec-web/src/main/java/com/ym/mec/web/controller/StudentRegistrationController.java

@@ -11,6 +11,7 @@ import io.swagger.annotations.ApiImplicitParam;
 import io.swagger.annotations.ApiImplicitParams;
 import io.swagger.annotations.ApiOperation;
 
+import java.io.EOFException;
 import java.io.IOException;
 import java.io.OutputStream;
 import java.util.Date;
@@ -239,7 +240,7 @@ public class StudentRegistrationController extends BaseController {
     }
 
 
-    @ApiOperation(value = "乐团预报名列表分页查询")
+    @ApiOperation(value = "预报名导出")
     @GetMapping("/preRegisterExport")
     @PreAuthorize("@pcs.hasPermissions('studentRegistration/preRegisterExport')")
     public void queryPreApplyList(StudentPreRegistrationQueryInfo queryInfo, HttpServletResponse response) throws Exception {
@@ -260,6 +261,12 @@ public class StudentRegistrationController extends BaseController {
             } else if (row.getKitPurchaseMethod().equals("GROUP")) {
                 row.setKitPurchaseMethod("团购");
             }
+            if(row.getSubjectFirst().equals(999)){
+                row.setSubjectFirstName("听从老师安排");
+            }
+            if(row.getSubjectSecond().equals(999)){
+                row.setSubjectSecondName("听从老师安排");
+            }
             row.setCurrentGrade(row.getCurrentGrade() + row.getCurrentClass());
         }
         OutputStream outputStream = response.getOutputStream();

+ 45 - 0
mec-web/src/main/java/com/ym/mec/web/controller/SysExamSongAccompanimentController.java

@@ -0,0 +1,45 @@
+package com.ym.mec.web.controller;
+
+import com.ym.mec.biz.dal.entity.SysExamSongAccompaniment;
+import com.ym.mec.biz.dal.page.SysExamSongQueryInfo;
+import com.ym.mec.biz.service.SysExamSongAccompanimentService;
+import com.ym.mec.common.controller.BaseController;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import io.swagger.annotations.ApiParam;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+@RequestMapping("sysExamSongAccompaniment")
+@Api(tags = "曲库伴奏服务")
+@RestController
+public class SysExamSongAccompanimentController extends BaseController {
+
+    @Autowired
+    private SysExamSongAccompanimentService sysExamSongAccompanimentService;
+
+    @ApiOperation(value = "修改")
+    @PostMapping("/update")
+    @PreAuthorize("@pcs.hasPermissions('sysExamSongAccompaniment/update')")
+    public Object update(@RequestBody SysExamSongAccompaniment sysExamSongAccompaniment) {
+        sysExamSongAccompanimentService.updateAcc(sysExamSongAccompaniment);
+        return succeed();
+    }
+
+    @ApiOperation(value = "删除")
+    @PostMapping("/del/{id}")
+    @PreAuthorize("@pcs.hasPermissions('sysExamSongAccompaniment/del')")
+    public Object del(@ApiParam(value = "收费类型编号", required = true) @PathVariable("id") Integer id) {
+        sysExamSongAccompanimentService.delete(id);
+        return succeed();
+    }
+
+    @ApiOperation(value = "分页查询")
+    @GetMapping("/queryPage")
+    @PreAuthorize("@pcs.hasPermissions('sysExamSongAccompaniment/queryPage')")
+    public Object queryPage(SysExamSongQueryInfo queryInfo) {
+        return succeed(sysExamSongAccompanimentService.queryAll(queryInfo));
+    }
+
+}

+ 6 - 12
mec-web/src/main/java/com/ym/mec/web/controller/SysExamSongController.java

@@ -2,6 +2,7 @@ package com.ym.mec.web.controller;
 
 import com.ym.mec.auth.api.client.SysUserFeignService;
 import com.ym.mec.auth.api.entity.SysUser;
+import com.ym.mec.biz.dal.dto.ExamSongDto;
 import com.ym.mec.biz.dal.entity.SysExamSong;
 import com.ym.mec.biz.dal.page.SysExamSongQueryInfo;
 import com.ym.mec.biz.service.SysExamSongService;
@@ -21,27 +22,20 @@ public class SysExamSongController extends BaseController {
 
     @Autowired
     private SysExamSongService sysExamSongService;
-    @Autowired
-    private SysUserFeignService sysUserFeignService;
 
     @ApiOperation(value = "修改")
     @PostMapping("/update")
     @PreAuthorize("@pcs.hasPermissions('sysExamSong/update')")
-    public Object update(@RequestBody SysExamSong sysExamSong) {
-        sysExamSongService.update(sysExamSong);
+    public Object update(@RequestBody ExamSongDto examSongDto) {
+        sysExamSongService.updateExamSong(examSongDto);
         return succeed();
     }
 
     @ApiOperation(value = "新增")
     @PostMapping("/add")
     @PreAuthorize("@pcs.hasPermissions('sysExamSong/add')")
-    public Object add(@RequestBody SysExamSong sysExamSong) {
-        SysUser sysUser = sysUserFeignService.queryUserInfo();
-        if(sysUser == null){
-            throw new BizException("请登录");
-        }
-        sysExamSong.setCreateUserId(sysUser.getId());
-        sysExamSongService.insert(sysExamSong);
+    public Object add(@RequestBody ExamSongDto examSongDto) {
+        sysExamSongService.add(examSongDto);
         return succeed();
     }
 
@@ -49,7 +43,7 @@ public class SysExamSongController extends BaseController {
     @PostMapping("/del/{id}")
     @PreAuthorize("@pcs.hasPermissions('sysExamSong/del')")
     public Object del(@ApiParam(value = "收费类型编号", required = true) @PathVariable("id") Integer id) {
-        sysExamSongService.delete(id);
+        sysExamSongService.del(id);
         return succeed();
     }