package com.ningdatech.pmapi.common.helper;

import com.ningdatech.pmapi.user.entity.UserInfo;
import com.ningdatech.pmapi.user.security.auth.model.UserFullInfoDTO;

import java.util.Collection;
import java.util.List;

/**
 * @author liuxinxin
 * @date 2023/2/10 下午4:38
 * @Description: 用户信息管理工具类 helper
 */

public interface UserInfoHelper {

    /**
     * 根据用户id 获取 用户所属组织code organizationCode
     *
     * @param userId
     * @return
     */
    String getOrganizationCode(Long userId);

    UserFullInfoDTO getUserFullInfo(Long userId);

    UserFullInfoDTO getUserFullInfo(UserInfo userInfo);

    List<UserFullInfoDTO> getUserFullInfos(List<UserInfo> userInfos);

    String getUserName(Long userId);

    /**
     * 判断该用户是否是区管或者超管
     *
     * @return
     */
    boolean isSuperOrRegionAdmin(Long userId);

    UserFullInfoDTO getUserFullInfoByEmployeeCode(String employeeCode);

    List<UserFullInfoDTO> getUserFullInfoByEmployeeCodes(Collection<String> employeeCodes);

    /**
     * 获取用户任职所在单位code
     *
     * @return
     */
    String getUserEmpPosUnitCode(Long userId);


}
