package com.yeejoin.amos.boot.module.hygf.api.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yeejoin.amos.boot.module.hygf.api.config.UserEmpower;
import com.yeejoin.amos.boot.module.hygf.api.entity.RegionalCompanies;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 *  Mapper 接口
 *
 * @author system_generator
 * @date 2023-08-29
 */
public interface RegionalCompaniesMapper extends BaseMapper<RegionalCompanies> {
    List<RegionalCompanies> selectListData(@Param("regionalCompaniesName") String regionalCompaniesName,@Param("unitId")Long unitId,@Param("sequenceNbr")Long sequenceNbr);
    RegionalCompanies selectByid(@Param("sequenceNbr")Long sequenceNbr);

    RegionalCompanies selectRegionName(@Param("sequenceNbr")Long sequenceNbr);

    @UserEmpower(field ={"hygf_regional_companies.regional_companies_code"} ,dealerField ={"hygf_unit_info.amos_company_code","hygf_regional_companies.regional_companies_code"},fieldConditions ={"eq","in"} ,relationship="and")
    List<RegionalCompanies>  selectListRegionalCompanies(@Param("sequenceNbr")Long sequenceNbr);
}
