Pārlūkot izejas kodu

试读报到移动端班级统计

dzx 8 mēneši atpakaļ
vecāks
revīzija
de9924c6f2

+ 2 - 1
src/main/java/com/xjrsoft/module/banding/service/impl/BandingTaskClassServiceImpl.java

@@ -35,6 +35,7 @@ import com.xjrsoft.module.base.service.IBaseMajorSetService;
 import com.xjrsoft.module.organization.entity.User;
 import com.xjrsoft.module.organization.service.IUserService;
 import com.xjrsoft.module.student.dto.StudentReportRecordPageDto;
+import com.xjrsoft.module.student.dto.StudentTryReadingReportPageDto;
 import com.xjrsoft.module.student.mapper.StudentReportRecordMapper;
 import com.xjrsoft.module.student.vo.StudentReportRecordPlanPageVo;
 import com.xjrsoft.module.system.entity.DictionaryDetail;
@@ -450,7 +451,7 @@ public class BandingTaskClassServiceImpl extends MPJBaseServiceImpl<BandingTaskC
     public BandingTaskClassReportStatisticsVo getTryReadingReportClassStatistics(Long classId) {
         BandingTaskClassReportStatisticsVo result = new BandingTaskClassReportStatisticsVo();
 
-        StudentReportRecordPageDto dto = new StudentReportRecordPageDto();
+        StudentTryReadingReportPageDto dto = new StudentTryReadingReportPageDto();
         dto.setClassId(classId);
         List<StudentReportRecordPlanPageVo> tryReadingList = reportRecordMapper.getTryReadingList(dto);
 

+ 4 - 3
src/main/java/com/xjrsoft/module/student/controller/StudentTryReadingReportController.java

@@ -34,6 +34,7 @@ import com.xjrsoft.module.student.dto.ChangeBandingStatusDto;
 import com.xjrsoft.module.student.dto.StudentReportRecordPageDto;
 import com.xjrsoft.module.student.dto.StudentReportRecordStatisticsDto;
 import com.xjrsoft.module.student.dto.StudentReportSignDto;
+import com.xjrsoft.module.student.dto.StudentTryReadingReportPageDto;
 import com.xjrsoft.module.student.entity.EnrollmentPlan;
 import com.xjrsoft.module.student.entity.StudentReportPlan;
 import com.xjrsoft.module.student.entity.StudentReportRecord;
@@ -90,7 +91,7 @@ public class StudentTryReadingReportController {
     @ApiOperation(value="试读报到(分页)")
     @SaCheckPermission("tryreadingreport:detail")
     @XjrLog(value="试读报到(分页)")
-    public RT<PageOutput<StudentReportRecordPlanPageVo>> page(@Valid StudentReportRecordPageDto dto){
+    public RT<PageOutput<StudentReportRecordPlanPageVo>> page(@Valid StudentTryReadingReportPageDto dto){
         List<String> roleList = StpUtil.getRoleList();
         if(roleList.contains("CLASSTE") && roleList.contains("TEACHER")){
             dto.setTeacherId(StpUtil.getLoginIdAsLong());
@@ -171,7 +172,7 @@ public class StudentTryReadingReportController {
     @ApiOperation(value="导出")
     @SaCheckPermission("studentreportrecord:detail")
     @XjrLog(value = "导出")
-    public ResponseEntity<byte[]> exportQuerty(@Valid @RequestBody StudentReportRecordPageDto dto){
+    public ResponseEntity<byte[]> exportQuerty(@Valid @RequestBody StudentTryReadingReportPageDto dto){
         List<StudentReportRecordExcelVo> dataList = new ArrayList<>();
 
         List<String> roleList = StpUtil.getRoleList();
@@ -281,7 +282,7 @@ public class StudentTryReadingReportController {
             return RT.ok(new StudentReportRecordStatisticsVo());
         }
 
-        StudentReportRecordPageDto recordPageDto = new StudentReportRecordPageDto();
+        StudentTryReadingReportPageDto recordPageDto = new StudentTryReadingReportPageDto();
         recordPageDto.setEnrollmentPlanId(enrollmentPlanList.get(0).getId());
 
         List<StudentReportRecordPlanPageVo> dataList = recordService.getTryReadingList(recordPageDto);

+ 73 - 0
src/main/java/com/xjrsoft/module/student/dto/StudentTryReadingReportPageDto.java

@@ -0,0 +1,73 @@
+package com.xjrsoft.module.student.dto;
+
+import com.xjrsoft.common.page.PageInput;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.time.LocalDate;
+import java.time.LocalDateTime;
+
+
+/**
+* @title: 学生报到记录表分页查询入参
+* @Author dzx
+* @Date: 2024-08-28
+* @Version 1.0
+*/
+@Data
+@EqualsAndHashCode(callSuper = false)
+public class StudentTryReadingReportPageDto extends PageInput {
+    @ApiModelProperty("学期id")
+    private Long baseSemesterId;
+
+    @ApiModelProperty("教师id")
+    private Long teacherId;
+
+
+    @ApiModelProperty("年级id")
+    private Long gradeId;
+
+    @ApiModelProperty("班级id")
+    private Long classId;
+
+    @ApiModelProperty("计划id")
+    private Long studentReportPlanId;
+
+    @ApiModelProperty("姓名")
+    private String name;
+
+    @ApiModelProperty("班级名称")
+    private String className;
+
+    @ApiModelProperty("身份证号")
+    private String credentialNumber;
+
+    @ApiModelProperty("学籍状态")
+    private String archivesStatus;
+
+    @ApiModelProperty("就读方式")
+    private String stduyStatus;
+
+    @ApiModelProperty("学生来源")
+    private String studentType;
+
+    @ApiModelProperty("是否已报到(1:是 0:否)")
+    private Integer isReport;
+
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty("报到时间开始")
+    private LocalDateTime reportTimeStart;
+
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty("报到时间结束")
+    private LocalDateTime reportTimeEnd;
+
+    @ApiModelProperty("招生计划id(enrollment_plan)")
+    private Long enrollmentPlanId;
+
+    @ApiModelProperty("是否移动端(1:是 0:否)")
+    private Integer isMoible;
+
+}

+ 3 - 2
src/main/java/com/xjrsoft/module/student/mapper/StudentReportRecordMapper.java

@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.github.yulichang.base.MPJBaseMapper;
 import com.xjrsoft.module.student.dto.StudentReportRecordPageDto;
 import com.xjrsoft.module.student.dto.StudentReportRecordStatisticsDto;
+import com.xjrsoft.module.student.dto.StudentTryReadingReportPageDto;
 import com.xjrsoft.module.student.entity.StudentReportRecord;
 import com.xjrsoft.module.student.vo.StudentReportRecordPageVo;
 import com.xjrsoft.module.student.vo.StudentReportRecordPlanPageVo;
@@ -36,8 +37,8 @@ public interface StudentReportRecordMapper extends MPJBaseMapper<StudentReportRe
 
     List<StudentReportRecordStatisticsListVo> getStatisticsPlanDataList(@Param("dto") StudentReportRecordStatisticsDto dto);
 
-    Page<StudentReportRecordPlanPageVo> getTryReadingPage(Page<StudentReportRecordPlanPageVo> page, @Param("dto") StudentReportRecordPageDto dto);
+    Page<StudentReportRecordPlanPageVo> getTryReadingPage(Page<StudentReportRecordPlanPageVo> page, @Param("dto") StudentTryReadingReportPageDto dto);
 
-    List<StudentReportRecordPlanPageVo> getTryReadingList(@Param("dto") StudentReportRecordPageDto dto);
+    List<StudentReportRecordPlanPageVo> getTryReadingList(@Param("dto") StudentTryReadingReportPageDto dto);
 
 }

+ 3 - 2
src/main/java/com/xjrsoft/module/student/service/IStudentReportRecordService.java

@@ -6,6 +6,7 @@ import com.xjrsoft.module.banding.dto.ChangeClassDto;
 import com.xjrsoft.module.student.dto.StudentReportRecordPageDto;
 import com.xjrsoft.module.student.dto.StudentReportRecordStatisticsDto;
 import com.xjrsoft.module.student.dto.StudentReportSignDto;
+import com.xjrsoft.module.student.dto.StudentTryReadingReportPageDto;
 import com.xjrsoft.module.student.entity.StudentReportRecord;
 import com.xjrsoft.module.student.vo.StudentReportRecordPageVo;
 import com.xjrsoft.module.student.vo.StudentReportRecordPlanPageVo;
@@ -49,9 +50,9 @@ public interface IStudentReportRecordService extends MPJBaseService<StudentRepor
 
     Boolean updateStduyStatusByTryReading(StudentReportSignDto dto);
 
-    Page<StudentReportRecordPlanPageVo> getTryReadingPage(Page<StudentReportRecordPlanPageVo> page, StudentReportRecordPageDto dto);
+    Page<StudentReportRecordPlanPageVo> getTryReadingPage(Page<StudentReportRecordPlanPageVo> page, StudentTryReadingReportPageDto dto);
 
-    List<StudentReportRecordPlanPageVo> getTryReadingList(StudentReportRecordPageDto dto);
+    List<StudentReportRecordPlanPageVo> getTryReadingList(StudentTryReadingReportPageDto dto);
 
     Boolean tryReadingSign(StudentReportSignDto dto);
 

+ 3 - 2
src/main/java/com/xjrsoft/module/student/service/impl/StudentReportRecordServiceImpl.java

@@ -34,6 +34,7 @@ import com.xjrsoft.module.organization.service.IUserService;
 import com.xjrsoft.module.student.dto.StudentReportRecordPageDto;
 import com.xjrsoft.module.student.dto.StudentReportRecordStatisticsDto;
 import com.xjrsoft.module.student.dto.StudentReportSignDto;
+import com.xjrsoft.module.student.dto.StudentTryReadingReportPageDto;
 import com.xjrsoft.module.student.entity.BaseNewStudent;
 import com.xjrsoft.module.student.entity.BaseStudent;
 import com.xjrsoft.module.student.entity.BaseStudentFamily;
@@ -291,12 +292,12 @@ public class StudentReportRecordServiceImpl extends MPJBaseServiceImpl<StudentRe
     }
 
     @Override
-    public Page<StudentReportRecordPlanPageVo> getTryReadingPage(Page<StudentReportRecordPlanPageVo> page, StudentReportRecordPageDto dto) {
+    public Page<StudentReportRecordPlanPageVo> getTryReadingPage(Page<StudentReportRecordPlanPageVo> page, StudentTryReadingReportPageDto dto) {
         return this.baseMapper.getTryReadingPage(page, dto);
     }
 
     @Override
-    public List<StudentReportRecordPlanPageVo> getTryReadingList(StudentReportRecordPageDto dto) {
+    public List<StudentReportRecordPlanPageVo> getTryReadingList(StudentTryReadingReportPageDto dto) {
         return this.baseMapper.getTryReadingList(dto);
     }
 

+ 7 - 7
src/main/resources/mapper/student/StudentReportRecordMapper.xml

@@ -221,7 +221,7 @@
     </select>
 
 
-    <select id="getTryReadingPage" parameterType="com.xjrsoft.module.student.dto.StudentReportRecordPageDto" resultType="com.xjrsoft.module.student.vo.StudentReportRecordPlanPageVo">
+    <select id="getTryReadingPage" parameterType="com.xjrsoft.module.student.dto.StudentTryReadingReportPageDto" resultType="com.xjrsoft.module.student.vo.StudentReportRecordPlanPageVo">
         SELECT t1.id, t1.user_id, t4.name AS grade_name,t5.name AS class_name,t6.name AS teacher_name,
         t3.name,t7.name AS gender,t3.credential_number,t3.mobile,t8.name AS student_type_cn,
         t9.name AS stduy_status_cn,t3.gender,t13.name as major_name,t14.name as class_type,
@@ -272,13 +272,13 @@
             and t3.credential_number like concat('%', #{dto.credentialNumber}, '%')
         </if>
         <if test="dto.archivesStatus != null and dto.archivesStatus != ''">
-            and t1.archives_status = #{dto.archivesStatus}
+            and t3.archives_status = #{dto.archivesStatus}
         </if>
         <if test="dto.stduyStatus != null and dto.stduyStatus != ''">
-            and t1.stduy_status = #{dto.stduyStatus}
+            and t3.stduy_status = #{dto.stduyStatus}
         </if>
         <if test="dto.studentType != null and dto.studentType != ''">
-            and t1.student_type = #{dto.studentType}
+            and t3.source = #{dto.studentType}
         </if>
         <if test="dto.isReport != null">
             <if test="dto.isReport == 1">
@@ -291,9 +291,9 @@
         <if test="dto.reportTimeStart != null and dto.reportTimeEnd != null">
             and t1.report_time between #{dto.reportTimeStart} and #{dto.reportTimeEnd}
         </if>
-        ORDER BY t1.report_time IS NULL DESC, t1.report_time DESC,t5.name
+        ORDER BY t1.report_time IS NULL DESC, t1.report_time DESC,t5.name is null desc,t5.name
     </select>
-    <select id="getTryReadingList" parameterType="com.xjrsoft.module.student.dto.StudentReportRecordPageDto" resultType="com.xjrsoft.module.student.vo.StudentReportRecordPlanPageVo">
+    <select id="getTryReadingList" parameterType="com.xjrsoft.module.student.dto.StudentTryReadingReportPageDto" resultType="com.xjrsoft.module.student.vo.StudentReportRecordPlanPageVo">
         SELECT t1.id, t1.user_id, t4.name AS grade_name,t5.name AS class_name,t6.name AS teacher_name,
         t3.name,t7.name AS gender,t3.credential_number,t3.mobile,t8.name AS student_type_cn,
         t9.name AS stduy_status_cn,t3.gender,t13.name as major_name,t14.name as class_type,
@@ -350,7 +350,7 @@
             and t3.stduy_status = #{dto.stduyStatus}
         </if>
         <if test="dto.studentType != null and dto.studentType != ''">
-            and t3.student_type = #{dto.studentType}
+            and t3.source = #{dto.studentType}
         </if>
         <if test="dto.isReport != null">
             <if test="dto.isReport == 1">