|  | @@ -1,22 +1,28 @@
 | 
	
		
			
				|  |  |  package com.ym.mec.biz.service.impl;
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -import java.math.BigDecimal;
 | 
	
		
			
				|  |  | -import java.time.DayOfWeek;
 | 
	
		
			
				|  |  | -import java.time.LocalDate;
 | 
	
		
			
				|  |  | -import java.time.LocalDateTime;
 | 
	
		
			
				|  |  | -import java.util.*;
 | 
	
		
			
				|  |  | -import java.util.stream.Collectors;
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | +import com.alibaba.fastjson.JSON;
 | 
	
		
			
				|  |  | +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.enums.CourseStatusEnum;
 | 
	
		
			
				|  |  | +import com.ym.mec.biz.dal.enums.StudentMusicGroupStatusEnum;
 | 
	
		
			
				|  |  | +import com.ym.mec.biz.dal.enums.YesOrNoEnum;
 | 
	
		
			
				|  |  |  import com.ym.mec.biz.dal.page.*;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.service.*;
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | -import com.ym.mec.common.page.QueryInfo;
 | 
	
		
			
				|  |  | +import com.ym.mec.biz.service.CloudTeacherOrderService;
 | 
	
		
			
				|  |  | +import com.ym.mec.biz.service.StudentManageService;
 | 
	
		
			
				|  |  | +import com.ym.mec.biz.service.StudentService;
 | 
	
		
			
				|  |  | +import com.ym.mec.biz.service.SysConfigService;
 | 
	
		
			
				|  |  | +import com.ym.mec.common.entity.HttpResponseResult;
 | 
	
		
			
				|  |  | +import com.ym.mec.common.entity.ImResult;
 | 
	
		
			
				|  |  | +import com.ym.mec.common.entity.ImUserModel;
 | 
	
		
			
				|  |  | +import com.ym.mec.common.exception.BizException;
 | 
	
		
			
				|  |  | +import com.ym.mec.common.page.PageInfo;
 | 
	
		
			
				|  |  | +import com.ym.mec.im.ImFeignService;
 | 
	
		
			
				|  |  |  import com.ym.mec.im.WebFeignService;
 | 
	
		
			
				|  |  | +import com.ym.mec.util.collection.MapUtil;
 | 
	
		
			
				|  |  |  import com.ym.mec.util.date.DateUtil;
 | 
	
		
			
				|  |  |  import org.apache.commons.lang3.StringUtils;
 | 
	
		
			
				|  |  |  import org.springframework.beans.factory.annotation.Autowired;
 | 
	
	
		
			
				|  | @@ -24,36 +30,12 @@ import org.springframework.stereotype.Service;
 | 
	
		
			
				|  |  |  import org.springframework.transaction.annotation.Transactional;
 | 
	
		
			
				|  |  |  import org.springframework.util.CollectionUtils;
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -import com.ym.mec.auth.api.client.SysUserFeignService;
 | 
	
		
			
				|  |  | -import com.ym.mec.auth.api.entity.SysUser;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.ClassGroupDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.CourseScheduleStudentPaymentDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.MusicGroupDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.MusicGroupPaymentCalenderDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.MusicGroupQuitDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.OrganizationDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.StudentDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.StudentExtracurricularExercisesSituationDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.StudentManageDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.StudentPaymentOrderDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.StudentRegistrationDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.SubjectChangeDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.SysUserCashAccountDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.TeacherDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.dao.VipGroupDao;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.entity.MusicGroupQuit;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.entity.Student;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.entity.StudentRegistration;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.entity.SubjectChange;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.entity.SysUserCashAccount;
 | 
	
		
			
				|  |  | -import com.ym.mec.biz.dal.entity.Teacher;
 | 
	
		
			
				|  |  | -import com.ym.mec.common.entity.HttpResponseResult;
 | 
	
		
			
				|  |  | -import com.ym.mec.common.entity.ImResult;
 | 
	
		
			
				|  |  | -import com.ym.mec.common.entity.ImUserModel;
 | 
	
		
			
				|  |  | -import com.ym.mec.common.exception.BizException;
 | 
	
		
			
				|  |  | -import com.ym.mec.common.page.PageInfo;
 | 
	
		
			
				|  |  | -import com.ym.mec.im.ImFeignService;
 | 
	
		
			
				|  |  | -import com.ym.mec.util.collection.MapUtil;
 | 
	
		
			
				|  |  | +import java.math.BigDecimal;
 | 
	
		
			
				|  |  | +import java.time.DayOfWeek;
 | 
	
		
			
				|  |  | +import java.time.LocalDate;
 | 
	
		
			
				|  |  | +import java.time.LocalDateTime;
 | 
	
		
			
				|  |  | +import java.util.*;
 | 
	
		
			
				|  |  | +import java.util.stream.Collectors;
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  /**
 | 
	
		
			
				|  |  |   * @Author Joburgess
 | 
	
	
		
			
				|  | @@ -911,4 +893,47 @@ public class StudentManageServiceImpl implements StudentManageService {
 | 
	
		
			
				|  |  |          pageInfo.setRows(dataList);
 | 
	
		
			
				|  |  |          return pageInfo;
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +    @Override
 | 
	
		
			
				|  |  | +    public PageInfo<StudentManageListDto> queryChildrenDayStudentList(StudentManageQueryInfo queryInfo) {
 | 
	
		
			
				|  |  | +        PageInfo<StudentManageListDto> pageInfo = new PageInfo<StudentManageListDto>(queryInfo.getPage(), queryInfo.getRows());
 | 
	
		
			
				|  |  | +        Map<String, Object> params = new HashMap<String, Object>();
 | 
	
		
			
				|  |  | +        MapUtil.populateMap(params, queryInfo);
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +        String[] organIds = queryInfo.getOrganId().split(",");
 | 
	
		
			
				|  |  | +        params.put("organIds", organIds);
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +        List<StudentManageListDto> dataList = null;
 | 
	
		
			
				|  |  | +        int count = studentManageDao.countStudentByOrganId(params);
 | 
	
		
			
				|  |  | +        if (count > 0) {
 | 
	
		
			
				|  |  | +            pageInfo.setTotal(count);
 | 
	
		
			
				|  |  | +            params.put("offset", pageInfo.getOffset());
 | 
	
		
			
				|  |  | +            dataList = studentManageDao.findStudentsByOrganId(params);
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +        pageInfo.setRows(dataList);
 | 
	
		
			
				|  |  | +        return pageInfo;
 | 
	
		
			
				|  |  | +    }
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  | +    @Override
 | 
	
		
			
				|  |  | +    @Transactional(rollbackFor = Exception.class)
 | 
	
		
			
				|  |  | +    public void updateChildrenDayStudent(ActivityCourseDetailDto activityCourseDetailDto) {
 | 
	
		
			
				|  |  | +        Student student = studentDao.getLocked(activityCourseDetailDto.getUserId());
 | 
	
		
			
				|  |  | +        if(student == null){
 | 
	
		
			
				|  |  | +            throw new BizException("学员信息不存在");
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +        if(!activityCourseDetailDto.getVip1().equals(0) && !activityCourseDetailDto.getVip1().equals(1)){
 | 
	
		
			
				|  |  | +            throw new BizException("修改失败:排课次数异常");
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +        if(!activityCourseDetailDto.getVip2().equals(0) && !activityCourseDetailDto.getVip2().equals(1)){
 | 
	
		
			
				|  |  | +            throw new BizException("修改失败:排课次数异常");
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +        if(!activityCourseDetailDto.getFreeVip().equals(0) && !activityCourseDetailDto.getFreeVip().equals(1)){
 | 
	
		
			
				|  |  | +            throw new BizException("修改失败:排课次数异常");
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +        if(!activityCourseDetailDto.getMusicTheory().equals(0) && !activityCourseDetailDto.getMusicTheory().equals(1)){
 | 
	
		
			
				|  |  | +            throw new BizException("修改失败:排课次数异常");
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +        student.setActivityCourseDetail(JSON.toJSONString(activityCourseDetailDto));
 | 
	
		
			
				|  |  | +        studentDao.update(student);
 | 
	
		
			
				|  |  | +    }
 | 
	
		
			
				|  |  |  }
 |