yonge 5 năm trước cách đây
mục cha
commit
fc4b4d0b7d

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

@@ -14,7 +14,7 @@ public interface TeacherDefaultVipGroupSalaryDao extends BaseDAO<Long, TeacherDe
      * 根据教师和课程类型获取老师vip课默认薪酬
      */
     TeacherDefaultVipGroupSalary findByTeacherAndCategory(@Param("userId") Integer userId,
-                                                          @Param("categoryId") Long categoryId);
+                                                          @Param("categoryId") Integer categoryId);
 
     /**
      * 根据教师编号删除vip课课酬设置

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

@@ -22,7 +22,7 @@ public interface VipGroupDefaultClassesUnitPriceDao extends BaseDAO<Integer, Vip
      * @return com.ym.mec.biz.dal.entity.VipGroupDefaultClassesUnitPrice
      * @describe 根据vip课类型获取课时收费设置
      */
-    VipGroupDefaultClassesUnitPrice getByVipGroupCategory(@Param("vipGroupCategoryId") Long vipGroupCategoryId,
+    VipGroupDefaultClassesUnitPrice getByVipGroupCategory(@Param("vipGroupCategoryId") Integer vipGroupCategoryId,
                                                           @Param("organId") Integer organId);
 
 

+ 3 - 3
mec-biz/src/main/java/com/ym/mec/biz/dal/dto/VipGroupCostCountParamsDto.java

@@ -9,7 +9,7 @@ import io.swagger.annotations.ApiModelProperty;
 public class VipGroupCostCountParamsDto {
 
     @ApiModelProperty("vip课程类型编号")
-    private Long vipGroupCategoryId;
+    private Integer vipGroupCategoryId;
 
     @ApiModelProperty("vip课默认课程单价编号")
     private Long vipGroupDefaultClassesUnitPriceId;
@@ -23,11 +23,11 @@ public class VipGroupCostCountParamsDto {
     @ApiModelProperty(value = "线下课课时数", required = false)
     private Integer offlineClassesNum;
 
-    public Long getVipGroupCategoryId() {
+    public Integer getVipGroupCategoryId() {
         return vipGroupCategoryId;
     }
 
-    public void setVipGroupCategoryId(Long vipGroupCategoryId) {
+    public void setVipGroupCategoryId(Integer vipGroupCategoryId) {
         this.vipGroupCategoryId = vipGroupCategoryId;
     }
 

+ 3 - 3
mec-biz/src/main/java/com/ym/mec/biz/dal/entity/TeacherDefaultVipGroupSalary.java

@@ -17,7 +17,7 @@ public class TeacherDefaultVipGroupSalary {
 	
 	/** 课程类型 */
 	@ApiModelProperty(value = "课程类型编号", required = false)
-	private String vipGroupCategoryId;
+	private Integer vipGroupCategoryId;
 
 	/** 课程类型 */
 	@ApiModelProperty(value = "课程类型名称(1v1,1v2)", required = false)
@@ -61,11 +61,11 @@ public class TeacherDefaultVipGroupSalary {
 		return this.userId;
 	}
 			
-	public void setVipGroupCategoryId(String vipGroupCategoryId){
+	public void setVipGroupCategoryId(Integer vipGroupCategoryId){
 		this.vipGroupCategoryId = vipGroupCategoryId;
 	}
 	
-	public String getVipGroupCategoryId(){
+	public Integer getVipGroupCategoryId(){
 		return this.vipGroupCategoryId;
 	}
 			

+ 3 - 3
mec-biz/src/main/java/com/ym/mec/biz/dal/entity/VipGroup.java

@@ -79,7 +79,7 @@ public class VipGroup {
 	private AuditStatusEnum auditStatus;
 
 	@ApiModelProperty(value = "课程类型ID",required = false)
-	private Long vipGroupCategoryId;
+	private Integer vipGroupCategoryId;
 	
 	@ApiModelProperty(value = "所属分部列表",required = false)
 	private String organIdList;
@@ -236,11 +236,11 @@ public class VipGroup {
 		this.auditStatus = auditStatus;
 	}
 
-	public Long getVipGroupCategoryId() {
+	public Integer getVipGroupCategoryId() {
 		return vipGroupCategoryId;
 	}
 
-	public void setVipGroupCategoryId(Long vipGroupCategoryId) {
+	public void setVipGroupCategoryId(Integer vipGroupCategoryId) {
 		this.vipGroupCategoryId = vipGroupCategoryId;
 	}
 

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

@@ -15,7 +15,7 @@ public interface TeacherDefaultVipGroupSalaryService extends BaseService<Long, T
      * @return com.ym.mec.biz.dal.entity.TeacherDefaultVipGroupSalary
      * @describe 根据用户及课程类型获取教师默认vip课酬
      */
-    TeacherDefaultVipGroupSalary findByTeacherAndCategory(Integer userId, Long categoryId);
+    TeacherDefaultVipGroupSalary findByTeacherAndCategory(Integer userId, Integer categoryId);
 
     /**
      * 批量新增修改教师vip课酬设置

+ 98 - 22
mec-biz/src/main/java/com/ym/mec/biz/service/impl/CourseScheduleServiceImpl.java

@@ -1,19 +1,112 @@
 package com.ym.mec.biz.service.impl;
 
+import java.math.BigDecimal;
+import java.text.SimpleDateFormat;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Calendar;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Objects;
+import java.util.Set;
+import java.util.TreeSet;
+import java.util.stream.Collectors;
+import java.util.stream.Stream;
+
+import org.apache.commons.collections.ListUtils;
+import org.apache.commons.lang3.StringUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.BeanUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Propagation;
+import org.springframework.transaction.annotation.Transactional;
+import org.springframework.util.CollectionUtils;
+
 import com.alibaba.fastjson.JSON;
 import com.alibaba.fastjson.JSONObject;
 import com.ym.mec.auth.api.client.SysUserFeignService;
 import com.ym.mec.auth.api.entity.SysUser;
 import com.ym.mec.auth.api.entity.SysUserRole;
-import com.ym.mec.biz.dal.dao.*;
-import com.ym.mec.biz.dal.dto.*;
-import com.ym.mec.biz.dal.entity.*;
-import com.ym.mec.biz.dal.enums.*;
+import com.ym.mec.biz.dal.dao.ClassGroupDao;
+import com.ym.mec.biz.dal.dao.ClassGroupStudentMapperDao;
+import com.ym.mec.biz.dal.dao.ClassGroupTeacherSalaryDao;
+import com.ym.mec.biz.dal.dao.CourseScheduleComplaintsDao;
+import com.ym.mec.biz.dal.dao.CourseScheduleDao;
+import com.ym.mec.biz.dal.dao.CourseScheduleStudentPaymentDao;
+import com.ym.mec.biz.dal.dao.CourseScheduleTeacherSalaryDao;
+import com.ym.mec.biz.dal.dao.GroupDao;
+import com.ym.mec.biz.dal.dao.MusicGroupDao;
+import com.ym.mec.biz.dal.dao.StudentAttendanceDao;
+import com.ym.mec.biz.dal.dao.SubjectDao;
+import com.ym.mec.biz.dal.dao.SysConfigDao;
+import com.ym.mec.biz.dal.dao.TeacherAttendanceDao;
+import com.ym.mec.biz.dal.dao.TeacherDao;
+import com.ym.mec.biz.dal.dao.TeacherDefaultVipGroupSalaryDao;
+import com.ym.mec.biz.dal.dao.VipGroupDao;
+import com.ym.mec.biz.dal.dto.ClassDateAdjustDto;
+import com.ym.mec.biz.dal.dto.CourseAttendanceDetailHeadInfoDto;
+import com.ym.mec.biz.dal.dto.CoursePostponeDto;
+import com.ym.mec.biz.dal.dto.CourseScheduleDto;
+import com.ym.mec.biz.dal.dto.CourseScheduleEndDto;
+import com.ym.mec.biz.dal.dto.CourseScheduleStudentDto;
+import com.ym.mec.biz.dal.dto.CourseTimeDto;
+import com.ym.mec.biz.dal.dto.CreateCourseScheduleDto;
+import com.ym.mec.biz.dal.dto.IntegerAndIntegerListDto;
+import com.ym.mec.biz.dal.dto.Mapper;
+import com.ym.mec.biz.dal.dto.TeacherAttendanceDto;
+import com.ym.mec.biz.dal.dto.TeacherBasicDto;
+import com.ym.mec.biz.dal.dto.TeacherClassCourseSchudeleDto;
+import com.ym.mec.biz.dal.dto.VipGroupApplyBaseInfoDto;
+import com.ym.mec.biz.dal.dto.VipGroupApplyDto;
+import com.ym.mec.biz.dal.dto.VipGroupCourseAdjustInfoDto;
+import com.ym.mec.biz.dal.entity.ClassGroup;
+import com.ym.mec.biz.dal.entity.ClassGroupStudentMapper;
+import com.ym.mec.biz.dal.entity.ClassGroupTeacherSalary;
+import com.ym.mec.biz.dal.entity.CourseGenerateDto;
+import com.ym.mec.biz.dal.entity.CourseSchedule;
+import com.ym.mec.biz.dal.entity.CourseScheduleComplaints;
+import com.ym.mec.biz.dal.entity.CourseScheduleStudentPayment;
+import com.ym.mec.biz.dal.entity.CourseScheduleTeacherSalary;
+import com.ym.mec.biz.dal.entity.Group;
+import com.ym.mec.biz.dal.entity.MusicGroup;
+import com.ym.mec.biz.dal.entity.StudentCourseScheduleRecordDto;
+import com.ym.mec.biz.dal.entity.SysConfig;
+import com.ym.mec.biz.dal.entity.TeacherAttendance;
+import com.ym.mec.biz.dal.entity.TeacherDefaultVipGroupSalary;
+import com.ym.mec.biz.dal.entity.VipGroup;
+import com.ym.mec.biz.dal.enums.AuditStatusEnum;
+import com.ym.mec.biz.dal.enums.ClassGroupStudentStatusEnum;
+import com.ym.mec.biz.dal.enums.ClassGroupTypeEnum;
+import com.ym.mec.biz.dal.enums.CourseStatusEnum;
+import com.ym.mec.biz.dal.enums.GroupType;
+import com.ym.mec.biz.dal.enums.MessageTypeEnum;
+import com.ym.mec.biz.dal.enums.MusicGroupStatusEnum;
+import com.ym.mec.biz.dal.enums.ParamEnum;
+import com.ym.mec.biz.dal.enums.TeachModeEnum;
+import com.ym.mec.biz.dal.enums.TeachTypeEnum;
+import com.ym.mec.biz.dal.enums.VipGroupStatusEnum;
+import com.ym.mec.biz.dal.enums.YesOrNoEnum;
 import com.ym.mec.biz.dal.page.CourseScheduleQueryInfo;
 import com.ym.mec.biz.dal.page.EndCourseScheduleQueryInfo;
 import com.ym.mec.biz.dal.page.StudentCourseScheduleRecordQueryInfo;
 import com.ym.mec.biz.dal.page.VipGroupQueryInfo;
-import com.ym.mec.biz.service.*;
+import com.ym.mec.biz.service.ClassGroupService;
+import com.ym.mec.biz.service.ClassGroupTeacherMapperService;
+import com.ym.mec.biz.service.CourseScheduleService;
+import com.ym.mec.biz.service.CourseScheduleStudentPaymentService;
+import com.ym.mec.biz.service.CourseScheduleTeacherSalaryService;
+import com.ym.mec.biz.service.MusicGroupService;
+import com.ym.mec.biz.service.SysConfigService;
+import com.ym.mec.biz.service.SysMessageService;
+import com.ym.mec.biz.service.VipGroupService;
 import com.ym.mec.common.dal.BaseDAO;
 import com.ym.mec.common.exception.BizException;
 import com.ym.mec.common.page.PageInfo;
@@ -25,23 +118,6 @@ import com.ym.mec.util.date.DateUtil;
 
 import feign.codec.DecodeException;
 
-import org.apache.commons.collections.ListUtils;
-import org.apache.commons.lang3.StringUtils;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.beans.BeanUtils;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.annotation.Propagation;
-import org.springframework.transaction.annotation.Transactional;
-import org.springframework.util.CollectionUtils;
-
-import java.math.BigDecimal;
-import java.text.SimpleDateFormat;
-import java.util.*;
-import java.util.stream.Collectors;
-import java.util.stream.Stream;
-
 @Service
 public class CourseScheduleServiceImpl extends BaseServiceImpl<Long, CourseSchedule> implements CourseScheduleService {
 

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

@@ -53,7 +53,7 @@ public class TeacherDefaultVipGroupSalaryServiceImpl extends BaseServiceImpl<Lon
 	}
 
 	@Override
-	public TeacherDefaultVipGroupSalary findByTeacherAndCategory(Integer userId, Long categoryId) {
+	public TeacherDefaultVipGroupSalary findByTeacherAndCategory(Integer userId, Integer categoryId) {
 		TeacherDefaultVipGroupSalary byTeacherAndCategory = teacherDefaultVipGroupSalaryDao.findByTeacherAndCategory(userId, categoryId);
 		if (Objects.isNull(byTeacherAndCategory)) {
 			byTeacherAndCategory.setOfflineClassesSalary(new BigDecimal(0));
@@ -72,14 +72,14 @@ public class TeacherDefaultVipGroupSalaryServiceImpl extends BaseServiceImpl<Lon
 			// 获取老师默认VIP课课酬
 			List<TeacherDefaultVipGroupSalary> origSalaryList = teacherDefaultVipGroupSalaryDao.queryByUserId(userId);
 
-			Map<String, TeacherDefaultVipGroupSalary> map = new HashMap<String, TeacherDefaultVipGroupSalary>();
+			Map<Integer, TeacherDefaultVipGroupSalary> map = new HashMap<Integer, TeacherDefaultVipGroupSalary>();
 			if (origSalaryList != null && origSalaryList.size() > 0) {
 				for (TeacherDefaultVipGroupSalary ms : origSalaryList) {
 					map.put(ms.getVipGroupCategoryId(), ms);
 				}
 			}
 
-			Map<String, TeacherDefaultVipGroupSalary> salaryMap = new HashMap<String, TeacherDefaultVipGroupSalary>();
+			Map<Integer, TeacherDefaultVipGroupSalary> salaryMap = new HashMap<Integer, TeacherDefaultVipGroupSalary>();
 			for (TeacherDefaultVipGroupSalary ms : teacherDefaultVipGroupSalaries) {
 				// 修改了哪些课酬
 				TeacherDefaultVipGroupSalary oldMS = map.get(ms.getVipGroupCategoryId());
@@ -123,7 +123,7 @@ public class TeacherDefaultVipGroupSalaryServiceImpl extends BaseServiceImpl<Lon
 					List<CourseScheduleTeacherSalary> list = new ArrayList<CourseScheduleTeacherSalary>();
 
 					for (CourseScheduleTeacherSalary ts : updateTeacherSalaryList) {
-						VipGroup vipGroup = vipGroupMap.get(ts.getMusicGroupId());
+						VipGroup vipGroup = vipGroupMap.get(Long.parseLong(ts.getMusicGroupId()));
 						// 课酬结算标准
 						if (vipGroup != null) {
 

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

@@ -28,7 +28,7 @@ public class VipGroupDefaultClassesUnitPriceServiceImpl extends BaseServiceImpl<
 		if(Objects.isNull(bean.getOrganId())){
 			throw new BizException("请选择分部");
 		}
-		VipGroupDefaultClassesUnitPrice byVipGroupCategory = vipGroupDefaultClassesUnitPriceDao.getByVipGroupCategory( bean.getVipGroupCategoryId().longValue(),bean.getOrganId());
+		VipGroupDefaultClassesUnitPrice byVipGroupCategory = vipGroupDefaultClassesUnitPriceDao.getByVipGroupCategory( bean.getVipGroupCategoryId(),bean.getOrganId());
 		if(null!=byVipGroupCategory){
 			return vipGroupDefaultClassesUnitPriceDao.updateByVipGroupCategory(bean);
 		}else{

+ 8 - 7
mec-teacher/src/main/java/com/ym/mec/teacher/controller/TeacherDefaultVipGroupSalaryController.java

@@ -1,19 +1,20 @@
 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.service.TeacherDefaultVipGroupSalaryService;
-import com.ym.mec.common.controller.BaseController;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
+
+import java.util.Objects;
+
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.http.HttpStatus;
-import org.springframework.security.access.prepost.PreAuthorize;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RestController;
 
-import java.util.Objects;
+import com.ym.mec.auth.api.client.SysUserFeignService;
+import com.ym.mec.auth.api.entity.SysUser;
+import com.ym.mec.biz.service.TeacherDefaultVipGroupSalaryService;
+import com.ym.mec.common.controller.BaseController;
 
 /**
  * @Author Joburgess
@@ -32,7 +33,7 @@ public class TeacherDefaultVipGroupSalaryController extends BaseController {
 
     @ApiOperation(value = "根据老师编号及课程类型编号获取默认课酬")
     @GetMapping("/findByTeacherAndCategory")
-    public Object findByTeacherAndCategory(Long categoryId){
+    public Object findByTeacherAndCategory(Integer categoryId){
         SysUser user = sysUserFeignService.queryUserInfo();
         if (Objects.isNull(user)) {
             return failed(HttpStatus.FORBIDDEN, "请登录");

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

@@ -34,7 +34,7 @@ public class TeacherDefaultVipGroupSalaryController extends BaseController {
     @ApiOperation(value = "根据老师编号及课程类型编号获取默认课酬")
     @GetMapping("/findByTeacherAndCategory")
     @PreAuthorize("@pcs.hasPermissions('teacherDefaultVipGroupSalary/findByTeacherAndCategory')")
-    public Object findByTeacherAndCategory(Integer userId, Long categoryId){
+    public Object findByTeacherAndCategory(Integer userId, Integer categoryId){
         return succeed(teacherDefaultVipGroupSalaryService.findByTeacherAndCategory(userId,categoryId));
     }