package com.unis.crk.basic.mapper;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.unis.crk.basic.entity.UserInfo;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.unis.crk.basic.entity.vo.UserAndRoleInfo;
import com.unis.crk.basic.entity.vo.UserInfoVo;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * <p>
 * 用户信息表 Mapper 接口
 * </p>
 *
 * @author ghh
 * @since 2021-09-26
 */
@Repository
public interface UserInfoMapper extends BaseMapper<UserInfo> {
    IPage<Map<String,Object>> queryAll(Page<UserAndRoleInfo> p,  @Param(Constants.WRAPPER) QueryWrapper<UserAndRoleInfo> userAndRoleInfoQueryWrapper);

    List<Map<Object, Object>> queryAuditUser(Map<Object, Object> map);

    IPage<Map<String,Object>> queryAllByOrgClass(Page<UserInfo> objectPage,@Param(Constants.WRAPPER) QueryWrapper<UserInfo> userInfoQueryWrapper);

    List<UserInfoVo> selectUserInfoVo(HashMap hashMap);

    List<UserInfoVo> selectUserInfoVoById (HashMap hashMap);
}
