课程学习的ES处理

This commit is contained in:
daihh
2023-01-07 11:43:02 +08:00
parent 2a04db03c8
commit 2347d50414

View File

@@ -1,5 +1,8 @@
package com.xboe.module.course.service;
import java.io.IOException;
import com.xboe.common.PageList;
import com.xboe.module.course.dto.CourseStudyDto;
/**
@@ -11,15 +14,15 @@ import com.xboe.module.course.dto.CourseStudyDto;
public interface ICourseStudySearch {
/**
* 索引名称
* 索引名称,固定的值
*/
public static final String IndexName="";
public static final String IndexName="new_study_resource";
/**
* 创建索引
* @param indexName
*/
void createIndex();
void createIndex() throws Exception;
/**
* 删除索引
@@ -28,10 +31,21 @@ public interface ICourseStudySearch {
void deleteIndex();
/**
* 发布学习课程
* 发布学习课程,如果存在就更新,不存在就添加
* @param dto
* @param docId
*/
void publish(CourseStudyDto dto);
String publishOrUpdate(CourseStudyDto dto,String docId) throws IOException;
/**
* 分页查询
* @param startRow
* @param pageSize
* @param dto
* @return
* @throws Exception
*/
PageList<CourseStudyDto> search(int startRow, int pageSize, CourseStudyDto dto) throws Exception;
/**
* 更新字段