提交 3d282b63 authored 作者: jiashixiong's avatar jiashixiong

前台公共资源接口添加查询专家

上级 1bcd13ac
......@@ -66,8 +66,8 @@ public class ExamPaperLibraryController {
*/
@ApiOperation(value = "获取分类下试卷列表")
@GetMapping("/get/exampaper/list")
public CallBack<PageInfo<BgExampaperLibraryVo>> getExampaperList(PageParam pageParam, List<Integer> dtid ,String resourcId){
return CallBack.success(service.getExampaperList(pageParam,dtid,resourcId));
public CallBack<PageInfo<BgExampaperLibraryVo>> getExampaperList(PageParam pageParam, QueryDiyExampaperForm form){
return CallBack.success(service.getExampaperList(pageParam,form));
}
/**
......
......@@ -35,7 +35,7 @@ public interface ExamPaperLibraryService extends BaseService<ExamPaperLibrary, I
* @author: Jsx
* @date: 2020/12/8 17:11
*/
PageInfo<BgExampaperLibraryVo> getExampaperList(PageParam pageParam, List<Integer> dtid,String resourcId);
PageInfo<BgExampaperLibraryVo> getExampaperList(PageParam pageParam, QueryDiyExampaperForm form);
/**
* 课程下添加试卷
......
......@@ -114,10 +114,10 @@ public class ExamPaperLibraryServiceImpl extends BaseServiceImpl<ExamPaperLibrar
* @return
*/
@Override
public PageInfo<BgExampaperLibraryVo> getExampaperList(PageParam pageParam, List<Integer> dtid,String resourcId){
public PageInfo<BgExampaperLibraryVo> getExampaperList(PageParam pageParam,QueryDiyExampaperForm form){
startPage(pageParam);
List<BgExampaperLibraryVo> list = mapper.getExampaperList(dtid);
List<Integer> ids = diyTypeManage.getCourseExampaperIds(resourcId);
List<BgExampaperLibraryVo> list = mapper.getExampaperList(form.getDtid());
List<Integer> ids = diyTypeManage.getCourseExampaperIds(form.getResourcId());
List<BgExampaperLibraryVo> list1 = list.stream().filter(s -> !ids.contains(s.getId())).collect(Collectors.toList());
list1.forEach(this::fmtExamPaperLibrary);
return new PageInfo<BgExampaperLibraryVo>(list1);
......
package com.zrqx.resource.commons.form.bg.questionlibrary;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.List;
/**
* @author Jsx
* @version 1.0
* @date 2020/12/30 16:53
*/
@Data
public class QueryDiyExampaperForm {
@ApiModelProperty("分类id集合")
private List<Integer> dtid;
@ApiModelProperty("资源id")
private String resourcId;
}
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论