package cn.qinys.platform.upms.api.mapper;

import cn.qinys.platform.entity.upms.Dictionary;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

/**
 * Dictionary 的Mapper接口
 *
 * @author v-lishiquan.gx@chinatelecom.cn
 * @date 2020-07-03
 */
@Repository
@Mapper
public interface DictionaryMapper extends BaseMapper<Dictionary> {

    /**
     * 字典分页
     *
     * @param page
     * @param wrapper
     * @return
     */
    @Select("SELECT * FROM upms_dictionary ${ew.customSqlSegment}")
    Page<Dictionary> selectDictionaryPage(Page<Dictionary> page, @Param(Constants.WRAPPER) Wrapper<Dictionary> wrapper);
}