|
@@ -1,11 +1,10 @@
|
|
|
package com.ym.mec.teacher.controller;
|
|
package com.ym.mec.teacher.controller;
|
|
|
|
|
|
|
|
|
|
+import com.ym.mec.biz.dal.dao.CourseScheduleDao;
|
|
|
import com.ym.mec.biz.dal.dao.StudentPaymentOrderDao;
|
|
import com.ym.mec.biz.dal.dao.StudentPaymentOrderDao;
|
|
|
import com.ym.mec.biz.dal.dao.SubjectDao;
|
|
import com.ym.mec.biz.dal.dao.SubjectDao;
|
|
|
import com.ym.mec.biz.dal.dto.*;
|
|
import com.ym.mec.biz.dal.dto.*;
|
|
|
-import com.ym.mec.biz.dal.entity.StudentCourseHomework;
|
|
|
|
|
-import com.ym.mec.biz.dal.entity.Subject;
|
|
|
|
|
-import com.ym.mec.biz.dal.entity.Teacher;
|
|
|
|
|
|
|
+import com.ym.mec.biz.dal.entity.*;
|
|
|
import com.ym.mec.biz.dal.enums.ELessonTrainingType;
|
|
import com.ym.mec.biz.dal.enums.ELessonTrainingType;
|
|
|
import com.ym.mec.biz.dal.enums.im.ClientEnum;
|
|
import com.ym.mec.biz.dal.enums.im.ClientEnum;
|
|
|
import com.ym.mec.biz.dal.page.*;
|
|
import com.ym.mec.biz.dal.page.*;
|
|
@@ -14,6 +13,7 @@ import com.ym.mec.biz.service.*;
|
|
|
import com.ym.mec.biz.service.im.ImGroupCoreService;
|
|
import com.ym.mec.biz.service.im.ImGroupCoreService;
|
|
|
import com.ym.mec.common.controller.BaseController;
|
|
import com.ym.mec.common.controller.BaseController;
|
|
|
import com.ym.mec.common.entity.HttpResponseResult;
|
|
import com.ym.mec.common.entity.HttpResponseResult;
|
|
|
|
|
+import com.ym.mec.common.entity.ImGroupModel;
|
|
|
import com.ym.mec.common.exception.BizException;
|
|
import com.ym.mec.common.exception.BizException;
|
|
|
import com.ym.mec.common.page.PageInfo;
|
|
import com.ym.mec.common.page.PageInfo;
|
|
|
import com.ym.mec.common.page.QueryInfo;
|
|
import com.ym.mec.common.page.QueryInfo;
|
|
@@ -25,6 +25,7 @@ import org.springframework.util.CollectionUtils;
|
|
|
import org.springframework.validation.annotation.Validated;
|
|
import org.springframework.validation.annotation.Validated;
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
|
|
|
|
+import java.math.BigDecimal;
|
|
|
import java.util.*;
|
|
import java.util.*;
|
|
|
import java.util.stream.Collectors;
|
|
import java.util.stream.Collectors;
|
|
|
|
|
|
|
@@ -52,6 +53,8 @@ public class TeacherController extends BaseController {
|
|
|
private StudentRegistrationService studentRegistrationService;
|
|
private StudentRegistrationService studentRegistrationService;
|
|
|
@Autowired
|
|
@Autowired
|
|
|
private ImGroupCoreService imGroupCoreService;
|
|
private ImGroupCoreService imGroupCoreService;
|
|
|
|
|
+ @Autowired
|
|
|
|
|
+ private CourseScheduleDao courseScheduleDao;
|
|
|
|
|
|
|
|
@Autowired
|
|
@Autowired
|
|
|
private StudentCourseHomeworkService studentCourseHomeworkService;
|
|
private StudentCourseHomeworkService studentCourseHomeworkService;
|
|
@@ -71,9 +74,16 @@ public class TeacherController extends BaseController {
|
|
|
return succeed(teacherService.queryOrganList(sysUserService.getUserId()));
|
|
return succeed(teacherService.queryOrganList(sysUserService.getUserId()));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ @ApiOperation(value = "课程配置课件")
|
|
|
|
|
+ @GetMapping("/configCourseware")
|
|
|
|
|
+ public HttpResponseResult configCourseware(Long courseId,String coursewareDetailId) {
|
|
|
|
|
+ courseScheduleDao.configCourseware(courseId,coursewareDetailId);
|
|
|
|
|
+ return succeed();
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
@ApiOperation(value = "根据教师编号查询教师基本信息")
|
|
@ApiOperation(value = "根据教师编号查询教师基本信息")
|
|
|
@GetMapping("/queryUserInfo")
|
|
@GetMapping("/queryUserInfo")
|
|
|
- public Object queryUserInfo() {
|
|
|
|
|
|
|
+ public HttpResponseResult<Teacher> queryUserInfo() {
|
|
|
Teacher teacher = Optional.ofNullable(teacherService.get(sysUserService.getUserId())).
|
|
Teacher teacher = Optional.ofNullable(teacherService.get(sysUserService.getUserId())).
|
|
|
orElseThrow(()->new BizException("老师信息不存在"));
|
|
orElseThrow(()->new BizException("老师信息不存在"));
|
|
|
//专业技能
|
|
//专业技能
|
|
@@ -100,76 +110,88 @@ public class TeacherController extends BaseController {
|
|
|
@ApiOperation(value = "根据教师编号查询教师基本信息")
|
|
@ApiOperation(value = "根据教师编号查询教师基本信息")
|
|
|
@GetMapping("/get")
|
|
@GetMapping("/get")
|
|
|
@ApiParam(value = "教师编号", required = true)
|
|
@ApiParam(value = "教师编号", required = true)
|
|
|
- public Object get(Integer id) {
|
|
|
|
|
|
|
+ public HttpResponseResult<Teacher> get(Integer id) {
|
|
|
return succeed(teacherService.getDetail(id));
|
|
return succeed(teacherService.getDetail(id));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "根据教师编号查询教师课程班列表")
|
|
@ApiOperation(value = "根据教师编号查询教师课程班列表")
|
|
|
@GetMapping("/getClass")
|
|
@GetMapping("/getClass")
|
|
|
@ApiParam(value = "教师编号", required = true)
|
|
@ApiParam(value = "教师编号", required = true)
|
|
|
- public Object getClassGroup(Integer id) {
|
|
|
|
|
|
|
+ public HttpResponseResult<List<ClassGroup>> getClassGroup(Integer id) {
|
|
|
return succeed(classGroupService.findClassGroup4Teacher(id));
|
|
return succeed(classGroupService.findClassGroup4Teacher(id));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "获取老师乐团课程信息列表")
|
|
@ApiOperation(value = "获取老师乐团课程信息列表")
|
|
|
@GetMapping("/getTeacherMusicClass")
|
|
@GetMapping("/getTeacherMusicClass")
|
|
|
@ApiParam(value = "教师编号", required = true)
|
|
@ApiParam(value = "教师编号", required = true)
|
|
|
- public Object getTeacherMusicClass(TeacherMusicClassQueryInfo queryInfo){
|
|
|
|
|
|
|
+ public HttpResponseResult<PageInfo<TeacherMusicClassInfoDto>> getTeacherMusicClass(TeacherMusicClassQueryInfo queryInfo){
|
|
|
return succeed(classGroupService.getTeacherMusicClass(queryInfo));
|
|
return succeed(classGroupService.getTeacherMusicClass(queryInfo));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ @ApiOperation(value = "获取老师关联的乐团列表")
|
|
|
|
|
+ @GetMapping("/queryTeacherMusicGroup")
|
|
|
|
|
+ public HttpResponseResult<List<MusicGroup>> queryTeacherMusicGroup(){
|
|
|
|
|
+ return succeed(classGroupService.getDao().queryTeacherMusicGroup(sysUserService.getUserId()));
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ @ApiOperation(value = "获取老师所在乐团的班级列表")
|
|
|
|
|
+ @GetMapping("/queryTeacherMusicClass")
|
|
|
|
|
+ public HttpResponseResult<List<ClassGroup>> queryTeacherMusicClass(String musicGroupId){
|
|
|
|
|
+ return succeed(classGroupService.getDao().queryTeacherMusicClass(musicGroupId,sysUserService.getUserId()));
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
@ApiOperation(value = "获取老师VIP课程信息列表")
|
|
@ApiOperation(value = "获取老师VIP课程信息列表")
|
|
|
@GetMapping("/getTeacherVipClass")
|
|
@GetMapping("/getTeacherVipClass")
|
|
|
- public Object getTeacherVipClass(VipClassQueryInfo queryInfo){
|
|
|
|
|
|
|
+ public HttpResponseResult<PageInfo<TeacherVipClassInfoDto>> getTeacherVipClass(VipClassQueryInfo queryInfo){
|
|
|
return succeed(classGroupService.getTeacherVipClass(queryInfo));
|
|
return succeed(classGroupService.getTeacherVipClass(queryInfo));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "获取教师所有聊天群组")
|
|
@ApiOperation(value = "获取教师所有聊天群组")
|
|
|
@GetMapping("/queryTeacherGroups")
|
|
@GetMapping("/queryTeacherGroups")
|
|
|
- public Object queryTeacherGroups(String search){
|
|
|
|
|
|
|
+ public HttpResponseResult<List<ImGroupModel>> queryTeacherGroups(String search){
|
|
|
return succeed(teacherService.queryTeacherGroups(sysUserService.getUserId(),search));
|
|
return succeed(teacherService.queryTeacherGroups(sysUserService.getUserId(),search));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "获取当前教师通讯录列表")
|
|
@ApiOperation(value = "获取当前教师通讯录列表")
|
|
|
@GetMapping("/queryGroupStudents")
|
|
@GetMapping("/queryGroupStudents")
|
|
|
- public Object queryGroupStudents(String search){
|
|
|
|
|
|
|
+ public HttpResponseResult<List<BasicUserDto>> queryGroupStudents(String search){
|
|
|
return succeed(teacherService.queryGroupStudents(sysUserService.getUserId(),search));
|
|
return succeed(teacherService.queryGroupStudents(sysUserService.getUserId(),search));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "获取当前教师通讯录学员列表")
|
|
@ApiOperation(value = "获取当前教师通讯录学员列表")
|
|
|
@GetMapping("/queryGroupStudentList")
|
|
@GetMapping("/queryGroupStudentList")
|
|
|
- public Object queryGroupStudentList(String search){
|
|
|
|
|
|
|
+ public HttpResponseResult<List<BasicUserDto>> queryGroupStudentList(String search){
|
|
|
return succeed(teacherService.queryGroupStudentList(sysUserService.getUserId(),search));
|
|
return succeed(teacherService.queryGroupStudentList(sysUserService.getUserId(),search));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "分页查询群公告列表")
|
|
@ApiOperation(value = "分页查询群公告列表")
|
|
|
@GetMapping(value = "/queryNoticePage")
|
|
@GetMapping(value = "/queryNoticePage")
|
|
|
- public Object queryNoticePage(QueryInfo queryInfo){
|
|
|
|
|
|
|
+ public HttpResponseResult<PageInfo<ImGroupNotice>> queryNoticePage(QueryInfo queryInfo){
|
|
|
return succeed(imGroupNoticeService.queryPage(queryInfo));
|
|
return succeed(imGroupNoticeService.queryPage(queryInfo));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "获取教师上课结算列表")
|
|
@ApiOperation(value = "获取教师上课结算列表")
|
|
|
@GetMapping("/queryCloses")
|
|
@GetMapping("/queryCloses")
|
|
|
- public Object queryCloses(TeacherCloseQueryInfo queryInfo){
|
|
|
|
|
|
|
+ public HttpResponseResult<PageInfo<TeacherCloseDto>> queryCloses(TeacherCloseQueryInfo queryInfo){
|
|
|
return succeed(teacherService.queryCloses(queryInfo));
|
|
return succeed(teacherService.queryCloses(queryInfo));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "获取教师上课课酬未结算总额")
|
|
@ApiOperation(value = "获取教师上课课酬未结算总额")
|
|
|
@GetMapping("/sumTeacherNoPay")
|
|
@GetMapping("/sumTeacherNoPay")
|
|
|
- public Object findTeacherNoPay(Integer teacherId){
|
|
|
|
|
|
|
+ public HttpResponseResult<BigDecimal> findTeacherNoPay(Integer teacherId){
|
|
|
return succeed(teacherService.findTeacherNoPay(teacherId));
|
|
return succeed(teacherService.findTeacherNoPay(teacherId));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "获取乐团学院学员报名列表")
|
|
@ApiOperation(value = "获取乐团学院学员报名列表")
|
|
|
@GetMapping("/queryStudentApply")
|
|
@GetMapping("/queryStudentApply")
|
|
|
- public Object queryMusicGroupStudentApply(queryMusicGroupStudentQueryInfo queryInfo) {
|
|
|
|
|
|
|
+ public HttpResponseResult<PageInfo<MusicGroupStudentApplyDto>> queryMusicGroupStudentApply(queryMusicGroupStudentQueryInfo queryInfo) {
|
|
|
return succeed(teacherService.queryMusicGroupStudentApply(queryInfo));
|
|
return succeed(teacherService.queryMusicGroupStudentApply(queryInfo));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "通过乐团编号查询乐团科目规划")
|
|
@ApiOperation(value = "通过乐团编号查询乐团科目规划")
|
|
|
@GetMapping("/querySubByMusicGroupId")
|
|
@GetMapping("/querySubByMusicGroupId")
|
|
|
@ApiImplicitParams({ @ApiImplicitParam(name = "musicGroupId", value = "乐团编号", required = true, dataType = "String")})
|
|
@ApiImplicitParams({ @ApiImplicitParam(name = "musicGroupId", value = "乐团编号", required = true, dataType = "String")})
|
|
|
- public Object findSubByMusicGroupId(String musicGroupId){
|
|
|
|
|
|
|
+ public HttpResponseResult<List<Subject>> findSubByMusicGroupId(String musicGroupId){
|
|
|
return succeed(subjectService.findSubByMusicGroupId(musicGroupId));
|
|
return succeed(subjectService.findSubByMusicGroupId(musicGroupId));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -180,7 +202,7 @@ public class TeacherController extends BaseController {
|
|
|
@ApiImplicitParam(name = "idcardFrontImg", value = "身份证正面", required = true, dataType = "String"),
|
|
@ApiImplicitParam(name = "idcardFrontImg", value = "身份证正面", required = true, dataType = "String"),
|
|
|
@ApiImplicitParam(name = "idcardBackImg", value = "身份证背面", required = true, dataType = "String"),
|
|
@ApiImplicitParam(name = "idcardBackImg", value = "身份证背面", required = true, dataType = "String"),
|
|
|
@ApiImplicitParam(name = "idcardHandImg", value = "手持身份证照", required = true, dataType = "String") })
|
|
@ApiImplicitParam(name = "idcardHandImg", value = "手持身份证照", required = true, dataType = "String") })
|
|
|
- public Object realNameAuthentication(String realName, String idcardNo, String idcardFrontImg, String idcardBackImg, String idcardHandImg) {
|
|
|
|
|
|
|
+ public HttpResponseResult<Object> realNameAuthentication(String realName, String idcardNo, String idcardFrontImg, String idcardBackImg, String idcardHandImg) {
|
|
|
teacherService.realNameAuthentication(sysUserService.getUserId(), realName, idcardNo, idcardFrontImg, idcardBackImg, idcardHandImg);
|
|
teacherService.realNameAuthentication(sysUserService.getUserId(), realName, idcardNo, idcardFrontImg, idcardBackImg, idcardHandImg);
|
|
|
return succeed();
|
|
return succeed();
|
|
|
}
|
|
}
|