package com.mindskip.xzs.repository;
|
|
import com.mindskip.xzs.domain.KnowledgePoint;
|
import com.mindskip.xzs.domain.other.KnowledgePointPage;
|
import com.mindskip.xzs.viewmodel.admin.knowledge.KnowledgePageRequestVM;
|
import org.apache.ibatis.annotations.Mapper;
|
import org.apache.ibatis.annotations.Param;
|
|
import java.util.List;
|
|
/**
|
* @version 2.2.0
|
* @description: 知识点
|
* Copyright (C), 2020-2021, 武汉思维跳跃科技有限公司
|
* @date 2021 /9/7 9:45
|
*/
|
@Mapper
|
public interface KnowledgePointMapper extends BaseMapper<KnowledgePoint> {
|
int deleteByPrimaryKey(Integer id);
|
|
int insert(KnowledgePoint record);
|
|
int insertSelective(KnowledgePoint record);
|
|
KnowledgePoint selectByPrimaryKey(Integer id);
|
|
int updateByPrimaryKeySelective(KnowledgePoint record);
|
|
int updateByPrimaryKey(KnowledgePoint record);
|
|
/**
|
* 根据学科获取知识点
|
*
|
* @param id the id
|
* @return the knowledge point by subject id
|
*/
|
List<KnowledgePoint> getKnowledgePointBySubjectId(Integer id);
|
|
/**
|
* 根据上级节点,获取知识点
|
*
|
* @param id the id
|
* @return the knowledge point by parent id
|
*/
|
List<KnowledgePoint> getKnowledgePointByParentId(Integer id);
|
|
/**
|
* 知识点分页信息
|
*
|
* @param requestVM the request vm
|
* @return the list
|
*/
|
List<KnowledgePointPage> page(KnowledgePageRequestVM requestVM);
|
|
/**
|
* 根据年级、学科、名称获取知识点
|
*
|
* @param name the name
|
* @param subjectId the subject id
|
* @param levelId the level id
|
* @return the knowledge point
|
*/
|
KnowledgePoint getKnowledgePoint(@Param("name") String name, @Param("subjectId") Integer subjectId, @Param("levelId") Integer levelId);
|
}
|