SysDictMapper.java 1.85 KB
package com.pashanhoo.dictionary.dao;

import com.pashanhoo.dictionary.model.dto.SysDict;
import com.pashanhoo.dictionary.model.vo.GetSysDictParentVo;
import com.pashanhoo.dictionary.model.vo.SysDictVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface SysDictMapper {
    /**
     * delete by primary key
     *
     * @param dictid primaryKey
     * @return deleteCount
     */
    int deleteByPrimaryKey(String dictid);

    /**
     * insert record to table
     *
     * @param record the record
     * @return insert count
     */
    int insert(SysDict record);

    /**
     * insert record to table selective
     *
     * @param record the record
     * @return insert count
     */
    int insertSelective(SysDict record);

    /**
     * select by primary key
     *
     * @param dictid primary key
     * @return object by primary key
     */
    SysDict selectByPrimaryKey(String dictid);

    /**
     * update record selective
     *
     * @param record the updated record
     * @return update count
     */
    int updateByPrimaryKeySelective(SysDict record);

    /**
     * update record
     *
     * @param record the updated record
     * @return update count
     */
    int updateByPrimaryKey(SysDict record);

    int updateBatch(List<SysDict> list);

    int updateBatchSelective(List<SysDict> list);

    int batchInsert(@Param("list") List<SysDict> list);

    List<GetSysDictParentVo> getSysDictParent(@Param("request") SysDictVo request);

    List<SysDict> getSysDictByTypeId(@Param("typeId") String typeId);

    int deleteListByPrimaryKey(@Param("dictWithoutParent") List<SysDict> dictWithoutParent);

    List<SysDict> selectAll();

    int deleteByTypeId(@Param("typeid") String typeid);

    List<SysDict> getSysDictChildByParentCode(@Param("dcode") String dcode);
}