Browse Source

Merge branch 'master' of http://git.dayaedu.com/yonge/mec

zouxuan 5 years ago
parent
commit
a009f1a82d

+ 23 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/GroupDao.java

@@ -0,0 +1,23 @@
+package com.ym.mec.biz.dal.dao;
+
+import com.ym.mec.biz.dal.entity.Group;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+/**
+ * @Author Joburgess
+ * @Date 2019/12/30
+ */
+public interface GroupDao {
+
+    /**
+     * @describe 搜索团体
+     * @author Joburgess
+     * @date 2019/12/30
+     * @param search: 关键字
+     * @return java.util.List<com.ym.mec.biz.dal.entity.Group>
+     */
+    List<Group> searchGroups(@Param("search") String search);
+
+}

+ 1 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/VipGroupDao.java

@@ -329,4 +329,5 @@ public interface VipGroupDao extends BaseDAO<Long, VipGroup> {
     List<VipGroup> queryNormalStatusList();
 
     VipGroup findVipGroupInfo(@Param("id") Integer id, @Param("classGroupId") Integer classGroupId);
+
 }

+ 54 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/entity/Group.java

@@ -0,0 +1,54 @@
+package com.ym.mec.biz.dal.entity;
+
+import com.ym.mec.biz.dal.enums.GroupType;
+import io.swagger.annotations.ApiModelProperty;
+
+/**
+ * @Author Joburgess
+ * @Date 2019/12/30
+ */
+public class Group {
+    @ApiModelProperty(value = "编号")
+    private String id;
+
+    @ApiModelProperty(value = "名称")
+    private String groupName;
+
+    @ApiModelProperty(value = "类型")
+    private GroupType groupType;
+
+    @ApiModelProperty(value = "班级编号")
+    private Integer classGroupId;
+
+    public String getId() {
+        return id;
+    }
+
+    public void setId(String id) {
+        this.id = id;
+    }
+
+    public String getGroupName() {
+        return groupName;
+    }
+
+    public void setGroupName(String groupName) {
+        this.groupName = groupName;
+    }
+
+    public GroupType getGroupType() {
+        return groupType;
+    }
+
+    public void setGroupType(GroupType groupType) {
+        this.groupType = groupType;
+    }
+
+    public Integer getClassGroupId() {
+        return classGroupId;
+    }
+
+    public void setClassGroupId(Integer classGroupId) {
+        this.classGroupId = classGroupId;
+    }
+}

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

@@ -389,5 +389,5 @@ public interface CourseScheduleService extends BaseService<Long, CourseSchedule>
 	 * @param queryInfo: 查询条件
 	 * @return java.util.List<com.ym.mec.biz.dal.dto.CourseScheduleEndDto>
 	 */
-	List<CourseScheduleEndDto> endFindCourseSchedules(EndCourseScheduleQueryInfo queryInfo);
+	PageInfo endFindCourseSchedules(EndCourseScheduleQueryInfo queryInfo);
 }

File diff suppressed because it is too large
+ 501 - 498
mec-biz/src/main/java/com/ym/mec/biz/service/impl/CourseScheduleServiceImpl.java


+ 12 - 2
mec-biz/src/main/resources/config/mybatis/CourseScheduleMapper.xml

@@ -1272,7 +1272,7 @@
         SELECT DISTINCT cgsm.music_group_id_ FROM class_group_student_mapper cgsm
         LEFT JOIN music_group mg ON mg.id_ = cgsm.music_group_id_ AND cgsm.group_type_ = 'MUSIC'
         LEFT JOIN vip_group vg ON vg.id_ = cgsm.music_group_id_ AND cgsm.group_type_ = 'VIP'
-        WHERE cgsm.user_id_ = #{userId} AND cgsm.status_ != 'QUIT' AND (mg.status_ = 'PROGRESS' OR vg.status_ = 2)
+        WHERE cgsm.user_id_ = #{userId} AND cgsm.status_ != 'QUIT' AND (mg.status_ = 'PROGRESS' OR vg.status_ = 2 OR vg.status_=5)
         ORDER BY cgsm.music_group_id_
         <include refid="global.limit"/>
     </select>
@@ -1853,7 +1853,9 @@
 
     <sql id="endFindCourseSchedulesCondition">
         <where>
-
+            <if test="search != null">
+                AND (cs.name_ LIKE CONCAT('%',#{search},'%') OR cs.id_ = #{search})
+            </if>
         </where>
     </sql>
 
@@ -1878,4 +1880,12 @@
           ORDER BY course_start_time_
         <include refid="global.limit"/>
     </select>
+    <select id="endCountCourseSchedules" resultType="int">
+        SELECT
+            COUNT(cs.id_)
+        FROM
+          course_schedule cs
+          LEFT JOIN class_group cg ON cg.id_=cs.class_group_id_
+        <include refid="endFindCourseSchedulesCondition"/>
+    </select>
 </mapper>

+ 20 - 0
mec-biz/src/main/resources/config/mybatis/GroupMapper.xml

@@ -0,0 +1,20 @@
+<?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.GroupDao">
+
+    <resultMap type="com.ym.mec.biz.dal.entity.Group" id="Group">
+        <result column="id_" property="id"/>
+        <result column="group_name_" property="groupName"/>
+        <result column="group_type_" property="groupType" typeHandler="com.ym.mec.common.dal.CustomEnumTypeHandler"/>
+        <result column="class_group_id_" property="classGroupId"/>
+    </resultMap>
+
+    <select id="searchGroups" resultMap="Group">
+
+    </select>
+
+</mapper>

+ 1 - 1
mec-biz/src/main/resources/config/mybatis/StudentPaymentOrderMapper.xml

@@ -238,7 +238,7 @@
                           and spod.type_ =
                               #{type,typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler})
     </select>
-    <select id="queryByCondition" resultMap="StudentPaymentOrder" parameterMap="map">
+    <select id="queryByCondition" resultMap="StudentPaymentOrder" parameterType="map">
         SELECT
         spo.*
         FROM

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

@@ -12,6 +12,7 @@ import com.ym.mec.biz.dal.entity.MusicGroup;
 import com.ym.mec.biz.dal.enums.AuditStatusEnum;
 import com.ym.mec.biz.dal.enums.GroupType;
 import com.ym.mec.biz.dal.enums.TeachModeEnum;
+import com.ym.mec.biz.dal.page.EndCourseScheduleQueryInfo;
 import com.ym.mec.biz.dal.page.StudentAttendanceQueryInfo;
 import com.ym.mec.biz.dal.page.VipGroupQueryInfo;
 import com.ym.mec.biz.service.CourseScheduleComplaintsService;
@@ -168,8 +169,8 @@ public class CourseScheduleController extends BaseController {
 
     @ApiOperation(value = "课时调整-批量")
     @PreAuthorize("@pcs.hasPermissions('courseSchedule/batchClassStartDateAdjust')")
-    @PostMapping(value = "/batchClassStartDateAdjust",consumes = MediaType.APPLICATION_FORM_URLENCODED_VALUE, produces = MediaType.APPLICATION_JSON_UTF8_VALUE)
-    public Object batchClassStartDateAdjust(List<CourseSchedule> courseSchedules){
+    @PostMapping(value = "/batchClassStartDateAdjust")
+    public Object batchClassStartDateAdjust(@RequestBody List<CourseSchedule> courseSchedules){
         scheduleService.courseAdjust(courseSchedules);
         return succeed();
     }
@@ -269,4 +270,11 @@ public class CourseScheduleController extends BaseController {
         return succeed();
     }
 
+    @ApiOperation(value = "终极课表获取")
+    @GetMapping("/superFindCourseSchedules")
+    @PreAuthorize("@pcs.hasPermissions('courseSchedule/superFindCourseSchedules')")
+    public Object superFindCourseSchedules(EndCourseScheduleQueryInfo queryInfo){
+        return succeed(scheduleService.endFindCourseSchedules(queryInfo));
+    }
+
 }

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

@@ -211,7 +211,7 @@ public class ExportController extends BaseController {
                     row.setSubjectName(studentRegistration.getSubjectName());
                     row.setSchoolName(studentRegistration.getSchoolName());
                     if (row.getType().equals(OrderTypeEnum.APPLY) && studentRegistration.getKitType() != null && studentRegistration.getKitType().equals("LEASE")) {
-                        row.setLeaseFee(studentRegistration.getDepositFee());
+                        row.setLeaseFee(musicalFee);
                         row.setMusicalFee(BigDecimal.ZERO);
                     }
                 }

Some files were not shown because too many files changed in this diff