package com.skr.mdm.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.skr.mdm.entity.AuAdminRoleDO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

/**
 * 管理员对应角色信息(AuAdminRole)表数据库访问层
 *
 * @author nfq
 * @since 2020-09-09 14:54:54
 */
@Repository
public interface AuAdminRoleDao extends BaseMapper<AuAdminRoleDO> {

    /**
     * 获取公司超管id
     * @param companyId
     * @param level
     * @return
     */
    Integer getSuperAdminId(@Param("companyId") Integer companyId, @Param("level") Integer level);

    /**
     * 获取公司超管
     * @param companyId
     * @param level
     * @return
     */
    String getSuperAdminName(@Param("companyId") Integer companyId, @Param("level") Integer level);

    /**
     * 获取公司超管角色id
     * @param companyId
     * @param level
     * @return
     */
    Integer getSuperRoleId(@Param("companyId") Integer companyId, @Param("level") Integer level);
}