Explorar el Código

完善课时和章节一些功能,修复一些bug

honorfire hace 7 meses
padre
commit
e07283248f
Se han modificado 15 ficheros con 165 adiciones y 76 borrados
  1. 74 34
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/controller/CourseChapterController.java
  2. 13 4
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/controller/CourseClassHourController.java
  3. 2 3
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/domain/Chapter.java
  4. 6 7
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/domain/ClassHour.java
  5. 2 1
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/mapper/mapping/ChapterMapper.xml
  6. 32 15
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/mapper/mapping/ClassHourMapper.xml
  7. 1 1
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/param/ChapterEditParam.java
  8. 1 1
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/param/ChapterIdParam.java
  9. 13 1
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/param/ClassHourAddParam.java
  10. 14 2
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/param/ClassHourEditParam.java
  11. 3 3
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/param/ClassHourPageParam.java
  12. 1 1
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/service/ChapterService.java
  13. 1 1
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/service/ClassHourService.java
  14. 1 1
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/service/impl/ChapterServiceImpl.java
  15. 1 1
      snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/service/impl/ClassHourServiceImpl.java

+ 74 - 34
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/controller/CourseChapterController.java

@@ -85,24 +85,44 @@ public class CourseChapterController {
         param.clear();
         param.put("chapterIdList", chapterIdList);
         List<Map<String,Object>> classHourList =classHourService.queryAllList(param);
+        // 1. 准备结果:为每个章节添加classHours字段
+        for (Map<String, Object> chapter : chapterList) {
+            if (chapter == null || chapter.get("id") == null) continue;
 
-        // 2. 按chapterId分组课程
-        Map<String, List<Map<String, Object>>> classHourByChapter = classHourList.stream()
-                .filter(Objects::nonNull)
-                .filter(classHour -> classHour.get("chapterId") != null)
-                .collect(Collectors.groupingBy(
-                        classHour -> classHour.get("chapterId").toString()
-                ));
-
-        // 3. 为每个章节添加对应的课程列表
-        chapterList.stream()
-                .filter(Objects::nonNull)
-                .filter(chapter -> chapter.get("id") != null)
-                .forEach(chapter -> {
-                    String chapterId = chapter.get("id").toString();
-                    chapter.put("classHours",
-                            classHourByChapter.getOrDefault(chapterId, Collections.emptyList()));
-                });
+            String chapterId = chapter.get("id").toString();
+            List<Map<String, Object>> chapterClassHours = new ArrayList<>();
+
+            // 2. 倒序遍历课程列表(关键点!)
+            for (int i = classHourList.size() - 1; i >= 0; i--) {
+                Map<String, Object> classHour = classHourList.get(i);
+                if (classHour == null || classHour.get("chapterId") == null) continue;
+
+                // 3. 匹配当前章节
+                if (chapterId.equals(classHour.get("chapterId").toString())) {
+                    chapterClassHours.add(classHour);  // 添加到章节
+                    classHourList.remove(i);          // 从原列表删除(安全操作)
+                }
+            }
+
+            chapter.put("classHours", chapterClassHours);
+        }
+//        //按chapterId分组课程
+//        Map<String, List<Map<String, Object>>> classHourByChapter = classHourList.stream()
+//                .filter(Objects::nonNull)
+//                .filter(classHour -> classHour.get("chapterId") != null)
+//                .collect(Collectors.groupingBy(
+//                        classHour -> classHour.get("chapterId").toString()
+//                ));
+//
+//        //为每个章节添加对应的课程列表
+//        chapterList.stream()
+//                .filter(Objects::nonNull)
+//                .filter(chapter -> chapter.get("id") != null)
+//                .forEach(chapter -> {
+//                    String chapterId = chapter.get("id").toString();
+//                    chapter.put("classHours",
+//                            classHourByChapter.getOrDefault(chapterId, Collections.emptyList()));
+//                });
 
         return CommonResult.data(chapterPage);
     }
@@ -128,24 +148,44 @@ public class CourseChapterController {
         param.clear();
         param.put("chapterIdList", chapterIdList);
         List<Map<String,Object>> classHourList =classHourService.queryAllList(param);
+        // 1. 准备结果:为每个章节添加classHours字段
+        for (Map<String, Object> chapter : chapterList) {
+            if (chapter == null || chapter.get("id") == null) continue;
+
+            String chapterId = chapter.get("id").toString();
+            List<Map<String, Object>> chapterClassHours = new ArrayList<>();
+
+            // 2. 倒序遍历课程列表(关键点!)
+            for (int i = classHourList.size() - 1; i >= 0; i--) {
+                Map<String, Object> classHour = classHourList.get(i);
+                if (classHour == null || classHour.get("chapterId") == null) continue;
+
+                // 3. 匹配当前章节
+                if (chapterId.equals(classHour.get("chapterId").toString())) {
+                    chapterClassHours.add(classHour);  // 添加到章节
+                    classHourList.remove(i);          // 从原列表删除(安全操作)
+                }
+            }
 
-        // 2. 按chapterId分组课程
-        Map<String, List<Map<String, Object>>> classHourByChapter = classHourList.stream()
-                .filter(Objects::nonNull)
-                .filter(classHour -> classHour.get("chapterId") != null)
-                .collect(Collectors.groupingBy(
-                        classHour -> classHour.get("chapterId").toString()
-                ));
-
-        // 3. 为每个章节添加对应的课程列表
-        chapterList.stream()
-                .filter(Objects::nonNull)
-                .filter(chapter -> chapter.get("id") != null)
-                .forEach(chapter -> {
-                    String chapterId = chapter.get("id").toString();
-                    chapter.put("classHours",
-                            classHourByChapter.getOrDefault(chapterId, Collections.emptyList()));
-                });
+            chapter.put("classHours", chapterClassHours);
+        }
+//        //按chapterId分组课程
+//        Map<String, List<Map<String, Object>>> classHourByChapter = classHourList.stream()
+//                .filter(Objects::nonNull)
+//                .filter(classHour -> classHour.get("chapterId") != null)
+//                .collect(Collectors.groupingBy(
+//                        classHour -> classHour.get("chapterId").toString()
+//                ));
+//
+//        //为每个章节添加对应的课程列表
+//        chapterList.stream()
+//                .filter(Objects::nonNull)
+//                .filter(chapter -> chapter.get("id") != null)
+//                .forEach(chapter -> {
+//                    String chapterId = chapter.get("id").toString();
+//                    chapter.put("classHours",
+//                            classHourByChapter.getOrDefault(chapterId, Collections.emptyList()));
+//                });
         return CommonResult.data(chapterList);
     }
 

+ 13 - 4
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/controller/CourseClassHourController.java

@@ -37,8 +37,11 @@ import vip.xiaonuo.disk.service.CourseClasshourFileRelateService;
 import vip.xiaonuo.disk.vo.classhour.ClassHourVo;
 
 import javax.annotation.Resource;
+import javax.servlet.http.HttpServletRequest;
 import javax.validation.Valid;
 import javax.validation.constraints.NotEmpty;
+import java.util.HashMap;
+import java.util.Map;
 
 /**
  * 课时表控制器
@@ -66,8 +69,11 @@ public class CourseClassHourController {
     @ApiOperationSupport(order = 1)
     @ApiOperation("获取课时表分页")
     @GetMapping("/disk/hour/page")
-    public CommonResult<Page<ClassHourVo>> page(ClassHourPageParam classHourPageParam) {
-        return CommonResult.data(classHourService.page(classHourPageParam));
+    public CommonResult<Page<Map<String,Object>>> page(ClassHourPageParam classHourPageParam, HttpServletRequest req) {
+        Map param =new HashMap();
+        param.put("chapterId", req.getParameter("chapterId"));
+        Page<Map<String,Object>> page=classHourService.queryList(param);
+        return CommonResult.data(page);
     }
 
     /**
@@ -130,8 +136,11 @@ public class CourseClassHourController {
     @ApiOperationSupport(order = 5)
     @ApiOperation("获取课时表详情")
     @GetMapping("/disk/hour/detail")
-    public CommonResult<ClassHourVo> detail(@Valid ClassHourIdParam classHourIdParam) {
-        return CommonResult.data(classHourService.detail(classHourIdParam));
+    public CommonResult<Map<String,Object>> detail(@Valid ClassHourIdParam classHourIdParam, HttpServletRequest req) {
+        Map param =new HashMap();
+        param.put("id", req.getParameter("id"));
+        Map<String,Object> result=classHourService.queryInfo(param);
+        return CommonResult.data(result);
     }
 
 }

+ 2 - 3
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/domain/Chapter.java

@@ -31,9 +31,8 @@ import java.util.Date;
 public class Chapter {
 
     /** 主键 */
-    @TableId(type = IdType.AUTO)
     @ApiModelProperty(value = "主键", position = 1)
-    private Integer id;
+    private String id;
 
     /** 父id */
     @ApiModelProperty(value = "父id", position = 2)
@@ -51,7 +50,7 @@ public class Chapter {
     @ApiModelProperty(value = "DELETE_FLAG", position = 5)
     @TableLogic
     @TableField(fill = FieldFill.INSERT)
-    private Integer deleteFlag;
+    private String deleteFlag;
 
     /** UPDATE_TIME */
     @ApiModelProperty(value = "UPDATE_TIME", position = 6)

+ 6 - 7
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/domain/ClassHour.java

@@ -31,9 +31,8 @@ import java.util.Date;
 public class ClassHour {
 
     /** 主键 */
-    @TableId(type = IdType.AUTO)
     @ApiModelProperty(value = "主键", position = 1)
-    private Integer id;
+    private String id;
 
     /** 开始时间 */
     @ApiModelProperty(value = "开始时间", position = 2)
@@ -45,11 +44,11 @@ public class ClassHour {
 
     /** 班级id */
     @ApiModelProperty(value = "班级id", position = 4)
-    private Long classId;
+    private String classId;
 
     /** 章节id */
     @ApiModelProperty(value = "章节id", position = 4)
-    private Long chapterId;
+    private String chapterId;
 
     /** 课时名称 */
     @ApiModelProperty(value = "课时名称", position = 6)
@@ -61,15 +60,15 @@ public class ClassHour {
 
     /** 视频资源 */
     @ApiModelProperty(value = "视频资源", position = 4)
-    private Long videoResource;
+    private String videoResource;
 
     /** 讲义资源 */
     @ApiModelProperty(value = "讲义资源", position = 4)
-    private Long teachmaterialsFile;
+    private String teachmaterialsFile;
 
     /** 字幕资源 */
     @ApiModelProperty(value = "字幕资源", position = 4)
-    private Long subtitleFile;
+    private String subtitleFile;
 
     /** DELETE_FLAG */
     @ApiModelProperty(value = "DELETE_FLAG", position = 7)

+ 2 - 1
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/mapper/mapping/ChapterMapper.xml

@@ -20,8 +20,9 @@
             IFNULL(cc.id,'') AS id,
             IFNULL(cc.pid,'') AS pid,
             IFNULL(cc.name,'') AS name,
-            IFNULL(cc.course_id,'') ascourseId
+            IFNULL(cc.course_id,'') AS courseId
         FROM COURSE_CHAPTER cc
+        WHERE 1=1
         <if test="id !=null and id != ''">
             and cc.id=#{id}
         </if>

+ 32 - 15
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/mapper/mapping/ClassHourMapper.xml

@@ -7,7 +7,7 @@
            a."start_time",
            a."end_time",
            a."class_id",
-           a."course_id",
+           a."chapter_id",
            a."remark",
            a.DELETE_FLAG,
            a.UPDATE_TIME,
@@ -36,7 +36,7 @@
             a."start_time",
             a."end_time",
             a."class_id",
-            a."course_id",
+            a."chapter_id",
             a."remark",
             a.DELETE_FLAG,
             a.UPDATE_TIME,
@@ -54,11 +54,12 @@
 
     <select id="queryInfo" resultType="java.util.Map">
         SELECT
-            cc.id AS id,
-            IFNULL (cc.chapter_id,'') AS chapterId,
-            IFNULL (cc.remark,'') AS remark,
+            cc.ID AS id,
+            IFNULL (cc.NAME,'') AS name,
+            IFNULL (cc.CHAPTER_ID ,'') AS chapterId,
+            IFNULL (cc.REMARK ,'') AS remark,
             IFNULL (cc.VIDEO_RESOURCE,'') AS videoResource,
-            IFNULL (cc.TEACHMATERRIALS_FILE,'') AS teachmaterialsFile,
+            IFNULL (cc.TEACHMATERIALS_FILE,'') AS teachmaterialsFile,
             IFNULL (cc.SUBTITLE_FILE,'') AS subtitleFile,
             IFNULL (ru.FILE_NAME,'') AS videoResourceName,
             IFNULL (rf.FILE_URL,'') AS videoResourceUrl,
@@ -70,23 +71,30 @@
         LEFT JOIN RESOURCE_RECORD rr ON rr.ID =cc.VIDEO_RESOURCE AND cc.DELETE_FLAG ='NOT_DELETE'
         LEFT JOIN RESOURCE_USERFILE ru ON ru.USER_FILE_ID = rr.USERFILE_ID AND ru.DELETE_FLAG ='NOT_DELETE'
         LEFT JOIN RESOURCE_FILE rf ON ru.FILE_ID= rf.FILE_ID
-        LEFT JOIN DEV_FILE df ON cc.TEACHMATERRIALS_FILE =df.ID AND df.DELETE_FLAG ='NOT_DELETE'
+        LEFT JOIN DEV_FILE df ON cc.TEACHMATERIALS_FILE =df.ID AND df.DELETE_FLAG ='NOT_DELETE'
         LEFT JOIN DEV_FILE df2 ON cc.SUBTITLE_FILE =df2.ID AND df2.DELETE_FLAG ='NOT_DELETE'
+        where 1=1
+        <if test="id !=null  and id != ''">
+            and cc.ID =#{id}
+        </if>
     </select>
     <select id="queryList" resultType="java.util.Map">
         SELECT
-            cc.id AS id,
+            cc.ID AS id,
             IFNULL (cc.NAME,'') AS name,
-            IFNULL (cc.chapter_id,'') AS chapterId,
-            IFNULL (cc.remark,'') AS remark,
+            IFNULL (cc.CHAPTER_ID ,'') AS chapterId,
+            IFNULL (cc.REMARK ,'') AS remark,
             IFNULL (cc.VIDEO_RESOURCE,'') AS videoResource,
-            IFNULL (cc.TEACHMATERRIALS_FILE,'') AS teachmaterialsFile,
+            IFNULL (cc.TEACHMATERIALS_FILE,'') AS teachmaterialsFile,
             IFNULL (cc.SUBTITLE_FILE,'') AS subtitleFile
         FROM  COURSE_CLASSHOUR cc
         where cc.DELETE_FLAG ='NOT_DELETE'
         <if test="param.chapterId !=null and param.chapterId != ''">
             and cc.chapter_id=#{param.chapterId}
         </if>
+        <if test="param.name !=null and param.name != ''">
+            and cc.NAME like CONCAT('%', #{param.name}, '%')
+        </if>
         <if test="param.chapterIdList !=null and param.chapterIdList.size()>0">
             and cc.chapter_id in
             <foreach collection=" param.chapterIdList" close=")" index="index" item="item" open="(" separator=",">
@@ -97,18 +105,27 @@
 
     <select id="queryAllList" resultType="java.util.Map">
         SELECT
-            cc.id AS id,
+            cc.ID AS id,
             IFNULL (cc.NAME,'') AS name,
-            IFNULL (cc.chapter_id,'') AS chapterId,
-            IFNULL (cc.remark,'') AS remark,
+            IFNULL (cc.CHAPTER_ID ,'') AS chapterId,
+            IFNULL (cc.REMARK ,'') AS remark,
+            IFNULL (rr.CREATE_TIME,'') AS createTime,
+            IFNULL (su.NAME,'') AS createUserName,
             IFNULL (cc.VIDEO_RESOURCE,'') AS videoResource,
-            IFNULL (cc.TEACHMATERRIALS_FILE,'') AS teachmaterialsFile,
+            IFNULL (cc.TEACHMATERIALS_FILE,'') AS teachmaterialsFile,
             IFNULL (cc.SUBTITLE_FILE,'') AS subtitleFile
         FROM  COURSE_CLASSHOUR cc
+        LEFT JOIN RESOURCE_RECORD rr ON rr.ID =cc.VIDEO_RESOURCE AND cc.DELETE_FLAG ='NOT_DELETE'
+        LEFT JOIN RESOURCE_USERFILE ru ON ru.USER_FILE_ID = rr.USERFILE_ID AND ru.DELETE_FLAG ='NOT_DELETE'
+        LEFT JOIN RESOURCE_FILE rf ON ru.FILE_ID= rf.FILE_ID
+        LEFT JOIN SYS_USER su ON rr.CREATE_USER =su.ID AND su.DELETE_FLAG ='NOT_DELETE'
         where cc.DELETE_FLAG ='NOT_DELETE'
         <if test="chapterId !=null and chapterId != ''">
             and cc.chapter_id=#{chapterId}
         </if>
+        <if test="name !=null and name != ''">
+            and cc.NAME like CONCAT('%', #{name}, '%')
+        </if>
         <if test="chapterIdList !=null and chapterIdList.size()>0">
             and cc.chapter_id in
             <foreach collection=" chapterIdList" close=")" index="index" item="item" open="(" separator=",">

+ 1 - 1
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/param/ChapterEditParam.java

@@ -34,7 +34,7 @@ public class ChapterEditParam {
     /** 主键 */
     @ApiModelProperty(value = "主键", required = true, position = 1)
     @NotNull(message = "id不能为空")
-    private Integer id;
+    private String id;
 
     /** 父id */
     @ApiModelProperty(value = "父id", position = 2)

+ 1 - 1
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/param/ChapterIdParam.java

@@ -31,5 +31,5 @@ public class ChapterIdParam {
     /** 主键 */
     @ApiModelProperty(value = "主键", required = true)
     @NotBlank(message = "id不能为空")
-    private Integer id;
+    private String id;
 }

+ 13 - 1
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/param/ClassHourAddParam.java

@@ -47,7 +47,7 @@ public class ClassHourAddParam {
     /** 章节id */
     @ApiModelProperty(value = "章节id", position = 4)
     @NotBlank(message = "章节id不能为空")
-    private Long chapterId;
+    private String chapterId;
 
     /** 课程id */
     @ApiModelProperty(value = "课程id", position = 5)
@@ -57,4 +57,16 @@ public class ClassHourAddParam {
     @ApiModelProperty(value = "备注", position = 6)
     private String remark;
 
+    /** 视频资源 */
+    @ApiModelProperty(value = "视频资源", position = 6)
+    private String videoResource;
+
+    /** 讲义资源 */
+    @ApiModelProperty(value = "讲义资源", position = 6)
+    private String teachmaterialsFile;
+
+    /** 字幕资源 */
+    @ApiModelProperty(value = "字幕资源", position = 6)
+    private String subtitleFile;
+
 }

+ 14 - 2
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/param/ClassHourEditParam.java

@@ -34,7 +34,7 @@ public class ClassHourEditParam {
     /** 主键 */
     @ApiModelProperty(value = "主键", required = true, position = 1)
     @NotNull(message = "id不能为空")
-    private Integer id;
+    private String id;
 
     /** 开始时间 */
     @ApiModelProperty(value = "开始时间", position = 2)
@@ -50,7 +50,7 @@ public class ClassHourEditParam {
 
     /** 章节id */
     @ApiModelProperty(value = "章节id", position = 4)
-    private Long chapterId;
+    private String chapterId;
 
     /** 课程id */
     @ApiModelProperty(value = "课程id", position = 5)
@@ -60,4 +60,16 @@ public class ClassHourEditParam {
     @ApiModelProperty(value = "备注", position = 6)
     private String remark;
 
+    /** 视频资源 */
+    @ApiModelProperty(value = "视频资源", position = 6)
+    private String videoResource;
+
+    /** 讲义资源 */
+    @ApiModelProperty(value = "讲义资源", position = 6)
+    private String teachmaterialsFile;
+
+    /** 字幕资源 */
+    @ApiModelProperty(value = "字幕资源", position = 6)
+    private String subtitleFile;
+
 }

+ 3 - 3
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/param/ClassHourPageParam.java

@@ -45,9 +45,9 @@ public class ClassHourPageParam {
     private String sortOrder;
 
 
-    /** 课程id */
-    @ApiModelProperty(value = "课程id", position = 5)
-    private String courseId;
+    /** 章节id */
+    @ApiModelProperty(value = "章节id", position = 5)
+    private String chapterId;
 
 
     /** 班级id */

+ 1 - 1
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/service/ChapterService.java

@@ -96,7 +96,7 @@ public interface ChapterService extends IService<Chapter> {
      * @author pans
      * @date  2025/07/02 15:34
      **/
-    Chapter queryEntity(Integer id);
+    Chapter queryEntity(String id);
 
     /**
      *  课程章节-分页列表

+ 1 - 1
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/service/ClassHourService.java

@@ -95,7 +95,7 @@ public interface ClassHourService extends IService<ClassHour> {
      * @author pans
      * @date  2025/07/02 10:36
      **/
-    ClassHour queryEntity(Integer id);
+    ClassHour queryEntity(String id);
 
     /**
      *  课程课时-分页列表

+ 1 - 1
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/service/impl/ChapterServiceImpl.java

@@ -103,7 +103,7 @@ public class ChapterServiceImpl extends ServiceImpl<ChapterMapper, Chapter> impl
     }
 
     @Override
-    public Chapter queryEntity(Integer id) {
+    public Chapter queryEntity(String id) {
         Chapter chapter = this.getById(id);
         if(ObjectUtil.isEmpty(chapter)) {
             throw new CommonException("课程章节表不存在,id值为:{}", id);

+ 1 - 1
snowy-plugin/snowy-plugin-disk/snowy-plugin-disk-func/src/main/java/vip/xiaonuo/disk/service/impl/ClassHourServiceImpl.java

@@ -97,7 +97,7 @@ public class ClassHourServiceImpl extends ServiceImpl<ClassHourMapper, ClassHour
     }
 
     @Override
-    public ClassHour queryEntity(Integer id) {
+    public ClassHour queryEntity(String id) {
         ClassHour classHour = this.getById(id);
         if(ObjectUtil.isEmpty(classHour)) {
             throw new CommonException("课时表不存在,id值为:{}", id);