package ink.wgink.login.oauth2.client.remote.position;

import ink.wgink.annotation.rpc.rest.RemoteService;
import ink.wgink.annotation.rpc.rest.method.RemoteGetMethod;
import ink.wgink.annotation.rpc.rest.method.RemotePostMethod;
import ink.wgink.annotation.rpc.rest.params.*;
import ink.wgink.pojo.dtos.position.PositionUserDTO;
import ink.wgink.pojo.pos.PositionPO;
import ink.wgink.pojo.result.SuccessResultList;
import ink.wgink.pojo.vos.IdsVO;

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

/**
 * @ClassName: IPositionUserRemoteService
 * @Description: 职位用户调用
 * @Author: wanggeng
 * @Date: 2021/9/22 10:44 下午
 * @Version: 1.0
 */
@RemoteService("/resource/position/user")
public interface IPositionUserRemoteService {

    @RemoteGetMethod("/list-userid/{positionId}")
    List<String> listUserId(@RemoteServerParams String userCenter, @RemotePathParams("positionId") String positionId, @RemoteQueryParams("access_token") String accessToken);

    @RemotePostMethod("/list-userid/position-ids")
    List<String> listUserIdByPositionIds(@RemoteServerParams String userCenter, @RemoteQueryParams("access_token") String accessToken, @RemoteJsonBodyParams IdsVO idsVO);

    @RemoteGetMethod("/listpage/{positionId}")
    SuccessResultList<List<PositionUserDTO>> listPage(@RemoteServerParams String userCenter, @RemotePathParams("positionId") String positionId, @RemoteQueryParams("access_token") String accessToken, @RemoteQueryParams("page") int page, @RemoteQueryParams("rows") int rows, @RemoteQueryParamsMap Map<String, Object> params);

    @RemoteGetMethod("/list-position-po/userid/{userId}")
    List<PositionPO> listPositionPOByUserId(@RemoteServerParams String userCenter, @RemotePathParams("userId") String userId, @RemoteQueryParams("access_token") String accessToken);

    @RemotePostMethod("/list-position-po/user-ids")
    List<PositionPO> listPositionPOByUserIds(@RemoteServerParams String userCenter, @RemoteQueryParams("access_token") String accessToken, @RemoteJsonBodyParams IdsVO idsVO);

    @RemotePostMethod("/list-user-id/position-id/{positionId}/user-ids")
    List<String> listUserIdByPositionIdAndUserIds(@RemoteServerParams String userCenter, @RemotePathParams("positionId") String positionId, @RemoteQueryParams("access_token") String accessToken, @RemoteJsonBodyParams IdsVO idsVO);

    @RemotePostMethod("/list-user-id/position-ids/user-ids")
    List<String> listUserIdByPositionIdsAndUserIds(@RemoteServerParams String userCenter, @RemoteQueryParams("access_token") String accessToken, @RemoteJsonBodyParams IdsVO idsVO);

    @RemoteGetMethod("/list-position-id/user-id/{userId}")
    List<String> listPositionIdByUserId(@RemoteServerParams String userCenter, @RemotePathParams("userId") String userId, @RemoteQueryParams("access_token") String accessToken);

    @RemotePostMethod("/list-position-id/user-ids")
    List<String> listPositionIdByUserIds(@RemoteServerParams String userCenter, @RemoteQueryParams("access_token") String accessToken, @RemoteJsonBodyParams IdsVO idsVO);

}
