Browse Source

feat:服务指标明细

Joburgess 4 năm trước cách đây
mục cha
commit
8cdd9fc2d9

+ 2 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/CourseHomeworkDao.java

@@ -42,6 +42,8 @@ public interface CourseHomeworkDao extends BaseDAO<Long, CourseHomework> {
 	 */
 	CourseHomework findByCourseSchedule(@Param("courseScheduleId") Long courseScheduleId);
 
+	List<CourseHomework> findByCourseSchedules(@Param("courseIds") List<Long> courseIds);
+
 	/**
 	 * 查询老师未回复作业的数量
 	 * @return

+ 3 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/CourseScheduleDao.java

@@ -1787,4 +1787,7 @@ public interface CourseScheduleDao extends BaseDAO<Long, CourseSchedule> {
      * @return
      */
     List<Integer> findHasCourseStudent(@Param("userIds") List<Integer> userIds, @Param("groupType") String groupType);
+
+    List<CourseSchedule> queryByCourseScheduleIds(Map<String, Object> params);
+    int countByCourseScheduleIds(Map<String, Object> params);
 }

+ 3 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/StudentDao.java

@@ -185,4 +185,7 @@ public interface StudentDao extends com.ym.mec.common.dal.BaseDAO<Integer, Stude
      * @return java.util.List<com.ym.mec.biz.dal.entity.Subject>
      */
     List<Subject> getStudentSubjects(@Param("studentIds") Set<Integer> studentIds);
+
+    List<Student> queryByIds(Map<String, Object> params);
+    int countByIds(Map<String, Object> params);
 }

+ 2 - 2
mec-biz/src/main/java/com/ym/mec/biz/dal/dao/StudentExtracurricularExercisesSituationDao.java

@@ -114,7 +114,7 @@ public interface StudentExtracurricularExercisesSituationDao extends BaseDAO<Lon
     List<StudentExtracurricularExercisesSituation> findServiceWithCourse(@Param("monday") String monday,
                                                                          @Param("courseId") Long courseId);
 
-    List<TeacherServeDto> queryTeacherServeInfo(@Param("params") Map<String, Object> params);
-    int countTeacherServeInfo(@Param("params") Map<String, Object> params);
+    List<TeacherServeDto> queryTeacherServeInfo(Map<String, Object> params);
+    int countTeacherServeInfo(Map<String, Object> params);
 
 }

+ 20 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dto/TeacherServeExtraDto.java

@@ -0,0 +1,20 @@
+package com.ym.mec.biz.dal.dto;
+
+import com.ym.mec.biz.dal.entity.Student;
+
+/**
+ * @Author Joburgess
+ * @Date 2021/3/10 0010
+ */
+public class TeacherServeExtraDto extends Student {
+
+    private int homeworkExist;
+
+    public int getHomeworkExist() {
+        return homeworkExist;
+    }
+
+    public void setHomeworkExist(int homeworkExist) {
+        this.homeworkExist = homeworkExist;
+    }
+}

+ 30 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dto/TeacherServeHomeworkDto.java

@@ -0,0 +1,30 @@
+package com.ym.mec.biz.dal.dto;
+
+import com.ym.mec.biz.dal.entity.CourseSchedule;
+
+/**
+ * @Author Joburgess
+ * @Date 2021/3/10 0010
+ */
+public class TeacherServeHomeworkDto extends CourseSchedule {
+
+    private String subjectName;
+
+    private int homeworkExist;
+
+    public String getSubjectName() {
+        return subjectName;
+    }
+
+    public void setSubjectName(String subjectName) {
+        this.subjectName = subjectName;
+    }
+
+    public int getHomeworkExist() {
+        return homeworkExist;
+    }
+
+    public void setHomeworkExist(int homeworkExist) {
+        this.homeworkExist = homeworkExist;
+    }
+}

+ 42 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/page/TeacherServeHomeworkQueryInfo.java

@@ -0,0 +1,42 @@
+package com.ym.mec.biz.dal.page;
+
+import com.ym.mec.common.page.QueryInfo;
+
+import java.util.Date;
+
+/**
+ * @Author Joburgess
+ * @Date 2021/3/10 0010
+ */
+public class TeacherServeHomeworkQueryInfo extends QueryInfo {
+
+    private Date monday;
+
+    private Date sunday;
+
+    private Integer teacherId;
+
+    public Date getMonday() {
+        return monday;
+    }
+
+    public void setMonday(Date monday) {
+        this.monday = monday;
+    }
+
+    public Date getSunday() {
+        return sunday;
+    }
+
+    public void setSunday(Date sunday) {
+        this.sunday = sunday;
+    }
+
+    public Integer getTeacherId() {
+        return teacherId;
+    }
+
+    public void setTeacherId(Integer teacherId) {
+        this.teacherId = teacherId;
+    }
+}

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

@@ -2,9 +2,12 @@ package com.ym.mec.biz.service;
 
 import com.ym.mec.biz.dal.dto.StudentExercisesSituationDto;
 import com.ym.mec.biz.dal.dto.TeacherServeDto;
+import com.ym.mec.biz.dal.dto.TeacherServeExtraDto;
+import com.ym.mec.biz.dal.dto.TeacherServeHomeworkDto;
 import com.ym.mec.biz.dal.entity.StudentExtracurricularExercisesSituation;
 import com.ym.mec.biz.dal.page.StudentExercisesSituationQueryInfo;
 import com.ym.mec.biz.dal.page.StudentServiceDetailQueryInfo;
+import com.ym.mec.biz.dal.page.TeacherServeHomeworkQueryInfo;
 import com.ym.mec.biz.dal.page.TeacherServeQueryInfo;
 import com.ym.mec.common.page.PageInfo;
 import com.ym.mec.common.service.BaseService;
@@ -53,4 +56,8 @@ public interface StudentExtracurricularExercisesSituationService extends BaseSer
      */
     void teacherServeRemindPush(List<TeacherServeDto> teacherServes, Integer operatorId, String operatorName);
 
+    PageInfo<TeacherServeHomeworkDto> queryTeacherServeHomeworkDetail(TeacherServeHomeworkQueryInfo queryInfo);
+
+    PageInfo<TeacherServeExtraDto> queryTeacherServeExtraDetail(TeacherServeHomeworkQueryInfo queryInfo);
+
 }

+ 130 - 2
mec-biz/src/main/java/com/ym/mec/biz/service/impl/StudentExtracurricularExercisesSituationServiceImpl.java

@@ -2,13 +2,13 @@ package com.ym.mec.biz.service.impl;
 
 import com.ym.mec.biz.dal.dao.*;
 import com.ym.mec.biz.dal.dto.*;
-import com.ym.mec.biz.dal.entity.StudentExtracurricularExercisesSituation;
-import com.ym.mec.biz.dal.entity.TeacherRemind;
+import com.ym.mec.biz.dal.entity.*;
 import com.ym.mec.biz.dal.enums.GroupType;
 import com.ym.mec.biz.dal.enums.MessageTypeEnum;
 import com.ym.mec.biz.dal.enums.TeacherRemindTypeEnum;
 import com.ym.mec.biz.dal.page.StudentExercisesSituationQueryInfo;
 import com.ym.mec.biz.dal.page.StudentServiceDetailQueryInfo;
+import com.ym.mec.biz.dal.page.TeacherServeHomeworkQueryInfo;
 import com.ym.mec.biz.dal.page.TeacherServeQueryInfo;
 import com.ym.mec.biz.service.StudentExtracurricularExercisesSituationService;
 import com.ym.mec.biz.service.SysMessageService;
@@ -20,6 +20,7 @@ import com.ym.mec.thirdparty.message.MessageSenderPluginContext;
 import com.ym.mec.util.collection.MapUtil;
 import com.ym.mec.util.date.DateUtil;
 import org.apache.commons.lang3.StringUtils;
+import org.springframework.beans.BeanUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
@@ -51,6 +52,12 @@ public class StudentExtracurricularExercisesSituationServiceImpl extends BaseSer
 	private TeacherRemindDao teacherRemindDao;
 	@Autowired
 	private SysMessageService sysMessageService;
+	@Autowired
+	private StudentDao studentDao;
+	@Autowired
+	private SubjectDao subjectDao;
+	@Autowired
+	private CourseHomeworkDao courseHomeworkDao;
 
 	@Override
 	public BaseDAO<Long, StudentExtracurricularExercisesSituation> getDAO() {
@@ -280,4 +287,125 @@ public class StudentExtracurricularExercisesSituationServiceImpl extends BaseSer
 			teacherRemindDao.batchInsert(reminds);
 		}
 	}
+
+	@Override
+	public PageInfo<TeacherServeHomeworkDto> queryTeacherServeHomeworkDetail(TeacherServeHomeworkQueryInfo queryInfo) {
+		if(Objects.isNull(queryInfo.getMonday())||Objects.isNull(queryInfo.getSunday())||Objects.isNull(queryInfo.getTeacherId())){
+			throw new BizException("请指定教师");
+		}
+		PageInfo<TeacherServeHomeworkDto> pageInfo = new PageInfo<>(queryInfo.getPage(), queryInfo.getRows());
+		String mondayStr = DateUtil.dateToString(queryInfo.getMonday(), "yyyy-MM-dd");
+		List<StudentExtracurricularExercisesSituation> serves = studentExtracurricularExercisesSituationDao.findWeekServiceWithStudents(mondayStr, queryInfo.getTeacherId(), null);
+		if(CollectionUtils.isEmpty(serves)){
+			return pageInfo;
+		}
+		List<StudentExtracurricularExercisesSituation> homeworkServes = serves.stream().filter(s -> "HOMEWORK".equals(s.getServeType())).collect(Collectors.toList());
+		if(CollectionUtils.isEmpty(homeworkServes)){
+			return pageInfo;
+		}
+		List<Long> courseIdsArr = new ArrayList<>();
+		for (StudentExtracurricularExercisesSituation homeworkServe : homeworkServes) {
+			if(StringUtils.isBlank(homeworkServe.getCourseIds())){
+				continue;
+			}
+			List<Long> ids = Arrays.stream(homeworkServe.getCourseIds().split(",")).map(id -> Long.valueOf(id)).collect(Collectors.toList());
+			courseIdsArr.addAll(ids);
+		}
+		if(CollectionUtils.isEmpty(courseIdsArr)){
+			return pageInfo;
+		}
+
+		Map<Long, Long> courseNumMap = courseIdsArr.stream().collect(Collectors.groupingBy(id -> id, Collectors.counting()));
+		Set<Long> courseIds = new HashSet<>(courseIdsArr);
+
+		Map<String, Object> params = new HashMap<>();
+		MapUtil.populateMap(params, queryInfo);
+		params.put("courseIds", courseIds);
+
+		List<TeacherServeHomeworkDto> dataList = new ArrayList<>();
+		int count = courseScheduleDao.countByCourseScheduleIds(params);
+		if (count > 0) {
+			pageInfo.setTotal(count);
+			params.put("offset", pageInfo.getOffset());
+			List<CourseSchedule> courseSchedules = courseScheduleDao.queryByCourseScheduleIds(params);
+			List<CourseHomework> courseHomeworks = courseHomeworkDao.findByCourseSchedules(new ArrayList<>(courseIds));
+			Map<Long, Long> courseHomeworkMap = new HashMap<>();
+			if(!CollectionUtils.isEmpty(courseHomeworks)){
+				courseHomeworkMap = courseHomeworks.stream().collect(Collectors.groupingBy(CourseHomework::getCourseScheduleId, Collectors.counting()));
+			}
+			for (CourseSchedule courseSchedule : courseSchedules) {
+				TeacherServeHomeworkDto tshd = new TeacherServeHomeworkDto();
+				BeanUtils.copyProperties(courseSchedule,tshd);
+				tshd.setStudentNum(courseNumMap.get(courseSchedule.getId()).intValue());
+				if(courseHomeworkMap.containsKey(courseSchedule.getId())){
+					tshd.setHomeworkExist(1);
+				}
+				dataList.add(tshd);
+			}
+		}
+		if (count == 0) {
+			dataList = new ArrayList<>();
+		}
+		pageInfo.setRows(dataList);
+		return pageInfo;
+	}
+
+	@Override
+	public PageInfo<TeacherServeExtraDto> queryTeacherServeExtraDetail(TeacherServeHomeworkQueryInfo queryInfo) {
+		if(Objects.isNull(queryInfo.getMonday())||Objects.isNull(queryInfo.getSunday())||Objects.isNull(queryInfo.getTeacherId())){
+			throw new BizException("请指定教师");
+		}
+		PageInfo<TeacherServeExtraDto> pageInfo = new PageInfo<>(queryInfo.getPage(), queryInfo.getRows());
+		String mondayStr = DateUtil.dateToString(queryInfo.getMonday(), "yyyy-MM-dd");
+		List<StudentExtracurricularExercisesSituation> serves = studentExtracurricularExercisesSituationDao.findWeekServiceWithStudents(mondayStr, queryInfo.getTeacherId(), null);
+		if(CollectionUtils.isEmpty(serves)){
+			return pageInfo;
+		}
+		List<StudentExtracurricularExercisesSituation> homeworkServes = serves.stream().filter(s -> "EXERCISE".equals(s.getServeType())).collect(Collectors.toList());
+		if(CollectionUtils.isEmpty(homeworkServes)){
+			return pageInfo;
+		}
+
+		Set<Integer> studentIds = homeworkServes.stream().map(StudentExtracurricularExercisesSituation::getStudentId).collect(Collectors.toSet());
+		Map<Integer, List<StudentExtracurricularExercisesSituation>> studentServeMap = homeworkServes.stream().collect(Collectors.groupingBy(StudentExtracurricularExercisesSituation::getStudentId));
+
+		Map<String, Object> params = new HashMap<>();
+		MapUtil.populateMap(params, queryInfo);
+		params.put("studentIds", studentIds);
+
+		List<TeacherServeExtraDto> dataList = new ArrayList<>();
+		int count = studentDao.countByIds(params);
+		if (count > 0) {
+			pageInfo.setTotal(count);
+			params.put("offset", pageInfo.getOffset());
+			List<Student> students = studentDao.queryByIds(params);
+			Set<Integer> subjectIds = new HashSet<>();
+			for (Student student : students) {
+				if(StringUtils.isNotBlank(student.getSubjectIdList())){
+					Set<Integer> ids = Arrays.stream(student.getSubjectIdList().split(",")).map(id -> Integer.valueOf(id)).collect(Collectors.toSet());
+					subjectIds.addAll(ids);
+				}
+				TeacherServeExtraDto tsed = new TeacherServeExtraDto();
+				BeanUtils.copyProperties(student,tsed);
+				if(studentServeMap.containsKey(student.getUserId())){
+					List<StudentExtracurricularExercisesSituation> studentServes = studentServeMap.get(student.getUserId());
+					int num = studentServes.stream().mapToInt(StudentExtracurricularExercisesSituation::getActualExercisesNum).reduce(0, Integer::sum);
+					if(num>0){
+						tsed.setHomeworkExist(1);
+					}
+				}
+				dataList.add(tsed);
+			}
+			List<Subject> subjects = subjectDao.findBySubjectIds(new ArrayList<>(subjectIds));
+			Map<Integer, Subject> idSubjectMap = new HashMap<>();
+			if(!CollectionUtils.isEmpty(subjects)){
+				idSubjectMap = subjects.stream().collect(Collectors.toMap(Subject::getId, s->s, (s1, s2)->s1));
+			}
+		}
+		if (count == 0) {
+			dataList = new ArrayList<>();
+		}
+		pageInfo.setRows(dataList);
+		return pageInfo;
+	}
 }

+ 10 - 0
mec-biz/src/main/resources/config/mybatis/CourseHomeworkMapper.xml

@@ -231,6 +231,16 @@
 			course_homework ch
 			WHERE ch.course_schedule_id_=#{courseScheduleId}
 	</select>
+	<select id="findByCourseSchedules" resultMap="CourseHomework">
+		SELECT
+			ch.*
+		FROM
+			course_homework ch
+		WHERE ch.course_schedule_id_ IN
+			<foreach collection="courseIds" item="courseId" open="(" close=")" separator=",">
+				#{courseId}
+			</foreach>
+	</select>
 	
 	<select id="queryTeacerNoReplyNum" resultMap="Mapper">
 		select cs.actual_teacher_id_ key_,count(1) value_ from student_course_homework sch

+ 23 - 0
mec-biz/src/main/resources/config/mybatis/CourseScheduleMapper.xml

@@ -3581,4 +3581,27 @@
         AND FIND_IN_SET(cs.group_type_,#{groupType})
         GROUP BY cssp.user_id_
     </select>
+
+    <select id="queryByCourseScheduleIds" resultType="com.ym.mec.biz.dal.entity.CourseSchedule">
+        SELECT
+        <include refid="resultSql" />
+        FROM course_schedule cs
+        WHERE cs.id_ IN
+        <foreach collection="courseIds" item="courseId" open="(" close=")" separator=",">
+            #{courseId}
+        </foreach>
+        ORDER BY cs.class_date_,cs.start_class_time_,cs.id_
+        <include refid="global.limit"></include>
+    </select>
+    <select id="countByCourseScheduleIds" resultType="int">
+        SELECT
+        COUNT(cs.id_)
+        FROM course_schedule cs
+        WHERE cs.id_ IN
+        <foreach collection="courseIds" item="courseId" open="(" close=")" separator=",">
+            #{courseId}
+        </foreach>
+    </select>
+
+
 </mapper>

+ 3 - 2
mec-biz/src/main/resources/config/mybatis/StudentExtracurricularExercisesSituationMapper.xml

@@ -515,7 +515,7 @@
 		</where>
 	</sql>
 
-	<select id="queryTeacherServeInfo" resultType="com.ym.mec.biz.dal.dto.TeacherServeDto">
+	<select id="queryTeacherServeInfo" resultMap="TeacherServeDto">
 		SELECT
 			organ.name_ organ_name_,
 			sees.monday_,
@@ -531,7 +531,8 @@
 			LEFT JOIN organization organ ON organ.id_=tea.organ_id_
 			LEFT JOIN sys_user su ON tea.id_=su.id_
 		<include refid="queryTeacherServeInfoCondition" />
-		GROUP BY sees.monday_,sees.sunday_,sees.teacher_id_ ORDER BY sees.monday_,sees.sunday_,sees.teacher_id_;
+		GROUP BY sees.monday_,sees.sunday_,sees.teacher_id_ ORDER BY sees.monday_,sees.sunday_,sees.teacher_id_
+		<include refid="global.limit"></include>
 	</select>
 
 	<select id="countTeacherServeInfo" resultType="int">

+ 17 - 0
mec-biz/src/main/resources/config/mybatis/StudentMapper.xml

@@ -644,4 +644,21 @@
             AND sub.id_ IS NOT NULL
         ORDER BY sub.id_ DESC
     </select>
+
+    <select id="queryByIds" resultMap="Student">
+        SELECT * FROM student
+        WHERE user_id_ IN
+        <foreach collection="studentIds" item="studentId" open="(" close=")" separator=",">
+            #{studentId}
+        </foreach>
+        ORDER BY user_id_
+        <include refid="global.limit"></include>
+    </select>
+    <select id="countByIds" resultType="int">
+        SELECT count(user_id_) FROM student
+        WHERE user_id_ IN
+        <foreach collection="studentIds" item="studentId" open="(" close=")" separator=",">
+            #{studentId}
+        </foreach>
+    </select>
 </mapper>

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

@@ -88,13 +88,13 @@
 		SELECT COUNT(*) FROM teacher_remind
 	</select>
 
-	<select id="findTeachersRemindWithType" resultType="com.ym.mec.biz.dal.entity.TeacherRemind">
+	<select id="findTeachersRemindWithType" resultMap="TeacherRemind">
 		SELECT *
 		FROM teacher_remind
 		WHERE type_=#{remindType, typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler}
 		    AND teacher_id_ IN
 			<foreach collection="teacherIds" item="teacherId" open="(" close=")" separator=",">
-				#{teacherIds}
+				#{teacherId}
 			</foreach>
 			<if test="startDate!=null and endDate!=null">
 				AND monday_ BETWEEN #{startDate} AND #{endDate}

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

@@ -53,17 +53,17 @@ public class EmployeeController extends BaseController {
         if (sysUser == null) {
             return failed("用户信息获取失败");
         }
-            Employee employee = employeeService.get(sysUser.getId());
-			if (StringUtils.isEmpty(queryInfo.getOrganId())) {
-				queryInfo.setOrganId(employee.getOrganIdList());
-			}else if(StringUtils.isEmpty(employee.getOrganIdList())){
-                return failed("用户所在分部异常");
-            }else {
-                List<String> list = Arrays.asList(employee.getOrganIdList().split(","));
-                if(!list.containsAll(Arrays.asList(queryInfo.getOrganId().split(",")))){
-                    return failed("非法请求");
-                }
+        Employee employee = employeeService.get(sysUser.getId());
+        if (StringUtils.isEmpty(queryInfo.getOrganId())) {
+            queryInfo.setOrganId(employee.getOrganIdList());
+        }else if(StringUtils.isEmpty(employee.getOrganIdList())){
+            return failed("用户所在分部异常");
+        }else {
+            List<String> list = Arrays.asList(employee.getOrganIdList().split(","));
+            if(!list.containsAll(Arrays.asList(queryInfo.getOrganId().split(",")))){
+                return failed("非法请求");
             }
+        }
         return succeed(employeeService.queryEmployByOrganId(queryInfo));
     }
 

+ 28 - 9
mec-web/src/main/java/com/ym/mec/web/controller/StudentExtracurricularExercisesSituationController.java

@@ -5,10 +5,7 @@ import com.ym.mec.auth.api.entity.SysUser;
 import com.ym.mec.biz.dal.dao.EmployeeDao;
 import com.ym.mec.biz.dal.dto.TeacherServeDto;
 import com.ym.mec.biz.dal.entity.Employee;
-import com.ym.mec.biz.dal.page.StudentCourseHomeworkReplyQueryInfo;
-import com.ym.mec.biz.dal.page.StudentExercisesSituationQueryInfo;
-import com.ym.mec.biz.dal.page.StudentServiceDetailQueryInfo;
-import com.ym.mec.biz.dal.page.TeacherServeQueryInfo;
+import com.ym.mec.biz.dal.page.*;
 import com.ym.mec.biz.service.*;
 import com.ym.mec.common.controller.BaseController;
 import com.ym.mec.common.entity.HttpResponseResult;
@@ -18,9 +15,7 @@ import io.swagger.annotations.ApiOperation;
 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.GetMapping;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
 
 import java.time.DayOfWeek;
 import java.time.LocalDate;
@@ -138,9 +133,9 @@ public class StudentExtracurricularExercisesSituationController extends BaseCont
     }
 
     @ApiOperation(value = "教师作业布置提醒")
-    @GetMapping("/teacherServeRemindPush")
+    @PostMapping("/teacherServeRemindPush")
     @PreAuthorize("@pcs.hasPermissions('exercisesSituation/teacherServeRemindPush')")
-    public HttpResponseResult teacherServeRemindPush(List<TeacherServeDto> teacherServes) {
+    public HttpResponseResult teacherServeRemindPush(@RequestBody List<TeacherServeDto> teacherServes) {
         SysUser sysUser = sysUserFeignService.queryUserInfo();
         if (sysUser == null) {
             return failed("用户信息获取失败");
@@ -149,4 +144,28 @@ public class StudentExtracurricularExercisesSituationController extends BaseCont
         return succeed();
     }
 
+    @ApiOperation(value = "教师服务课后作业")
+    @GetMapping("/queryTeacherServeHomeworkDetail")
+    @PreAuthorize("@pcs.hasPermissions('exercisesSituation/queryTeacherServeHomeworkDetail')")
+    public HttpResponseResult queryTeacherServeHomeworkDetail(TeacherServeHomeworkQueryInfo queryInfo) {
+        SysUser sysUser = sysUserFeignService.queryUserInfo();
+        if (sysUser == null) {
+            return failed("用户信息获取失败");
+        }
+        studentExtracurricularExercisesSituationService.queryTeacherServeHomeworkDetail(queryInfo);
+        return succeed();
+    }
+
+    @ApiOperation(value = "教师服务课外作业")
+    @GetMapping("/queryTeacherServeExtraDetail")
+    @PreAuthorize("@pcs.hasPermissions('exercisesSituation/queryTeacherServeExtraDetail')")
+    public HttpResponseResult queryTeacherServeExtraDetail(TeacherServeHomeworkQueryInfo queryInfo) {
+        SysUser sysUser = sysUserFeignService.queryUserInfo();
+        if (sysUser == null) {
+            return failed("用户信息获取失败");
+        }
+        studentExtracurricularExercisesSituationService.queryTeacherServeExtraDetail(queryInfo);
+        return succeed();
+    }
+
 }