50 lines
899 B
Java
50 lines
899 B
Java
package com.bycrm.mapper;
|
|
|
|
import com.bycrm.entity.School;
|
|
import org.apache.ibatis.annotations.Mapper;
|
|
import org.apache.ibatis.annotations.Param;
|
|
|
|
import java.util.List;
|
|
|
|
/**
|
|
* 学校Mapper
|
|
*/
|
|
@Mapper
|
|
public interface SchoolMapper {
|
|
|
|
/**
|
|
* 插入学校
|
|
*/
|
|
int insert(School school);
|
|
|
|
/**
|
|
* 批量插入学校
|
|
*/
|
|
int batchInsert(@Param("list") List<School> list);
|
|
|
|
/**
|
|
* 根据学校名称模糊查询
|
|
*/
|
|
List<School> searchByName(@Param("keyword") String keyword);
|
|
|
|
/**
|
|
* 根据学校标识码查询
|
|
*/
|
|
School findByCode(@Param("schoolCode") String schoolCode);
|
|
|
|
/**
|
|
* 查询所有学校
|
|
*/
|
|
List<School> findAll();
|
|
|
|
/**
|
|
* 分页查询学校
|
|
*/
|
|
List<School> findByPage(@Param("offset") int offset, @Param("limit") int limit);
|
|
|
|
/**
|
|
* 统计学校数量
|
|
*/
|
|
int count();
|
|
}
|