|
@@ -1,8 +1,12 @@
|
|
|
package com.zhongzheng.controller.course;
|
|
|
|
|
|
+import java.util.HashMap;
|
|
|
import java.util.List;
|
|
|
import java.util.Arrays;
|
|
|
+import java.util.Map;
|
|
|
|
|
|
+import cn.hutool.http.HttpStatus;
|
|
|
+import com.github.pagehelper.PageInfo;
|
|
|
import com.zhongzheng.modules.course.bo.CourseChapterSectionAddBo;
|
|
|
import com.zhongzheng.modules.course.bo.CourseChapterSectionEditBo;
|
|
|
import com.zhongzheng.modules.course.bo.CourseChapterSectionQueryBo;
|
|
@@ -48,10 +52,16 @@ public class CourseChapterSectionController extends BaseController {
|
|
|
@ApiOperation("查询章与节关系列表")
|
|
|
@PreAuthorize("@ss.hasPermi('system:section:list')")
|
|
|
@GetMapping("/list/{id}")
|
|
|
- public TableDataInfo<CourseChapterSectionVo> list(@PathVariable("id" ) Long id) {
|
|
|
+ public AjaxResult list(@PathVariable("id" ) Long id) {
|
|
|
startPage();
|
|
|
List<CourseChapterSectionVo> list = iCourseChapterSectionService.getListById(id);
|
|
|
- return getDataTable(list);
|
|
|
+ Map<String, Object> result = new HashMap<>();
|
|
|
+ result.put("total",new PageInfo(list).getTotal());
|
|
|
+ result.put("code", HttpStatus.HTTP_OK);
|
|
|
+ result.put("list",list);
|
|
|
+ result.put("msg","查询成功");
|
|
|
+ result.put("sectionTotal",new PageInfo(list).getTotal());
|
|
|
+ return AjaxResult.success(result);
|
|
|
}
|
|
|
|
|
|
/**
|