package com.skr.mdm.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.skr.mdm.bean.bo.CompanyDownLoadBO;
import com.skr.mdm.bean.vo.company.CompanyVO;
import com.skr.mdm.bean.vo.expired.CompanyFileExpireVO;
import com.skr.mdm.entity.AuCompanyDO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 公司信息(AuCompany)表数据库访问层
 *
 * @author nfq
 * @since 2020-09-08 17:39:22
 */
@Repository
public interface AuCompanyDao extends BaseMapper<AuCompanyDO> {

    /**
     * 获取sid
     * @param equipmentId
     * @param state
     * @return
     */
    Integer getSidByEquipmentId(@Param("equipmentId") Integer equipmentId, @Param("state") Integer state);

    /**
     * 公司列表
     * @param searchType
     * @param searchValue
     * @return
     */
    List<CompanyVO> listCompany(@Param("searchType") Integer searchType, @Param("searchValue") String searchValue);

    List<CompanyFileExpireVO> queryList();

    List<CompanyDownLoadBO> selectCompanyDownload();
}