| | |
| | | package com.xiaopeng.api.feignClient.account; |
| | | |
| | | import com.xiaopeng.api.dto.account.XpOperationsUserQueryDTO; |
| | | import com.xiaopeng.api.factory.account.XpAppUserClientFallbackFactory; |
| | | import com.xiaopeng.api.factory.account.XpOperationUserClientFallbackFactory; |
| | | import com.xiaopeng.api.model.account.XpOperationsRole; |
| | | import com.xiaopeng.api.model.account.XpOperationsUser; |
| | | import com.xiaopeng.api.vo.account.XpOperationsUserWithRoleVO; |
| | | import com.xiaopeng.common.core.domain.R; |
| | | import com.xiaopeng.common.core.dto.ServiceNameConstantsEnum; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.cloud.openfeign.FeignClient; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | |
| | | */ |
| | | @FeignClient(contextId = "XpOperationUserClient", |
| | | value = ServiceNameConstantsEnum.XP_ACCOUNT_SERVICE, |
| | | fallbackFactory = XpAppUserClientFallbackFactory.class) |
| | | fallbackFactory = XpOperationUserClientFallbackFactory.class) |
| | | public interface XpOperationUserClient { |
| | | /** |
| | | * 根据ID列表批量查询运维用户信息 |
| | | * @param ids 用户ID列表 |
| | | * @return 用户列表 |
| | | */ |
| | | @PostMapping("/inner/xpOperationsUser/listByIds") |
| | | @PostMapping("/logan/inner/xpOperationsUser/listByIds") |
| | | R<List<XpOperationsUser>> listByIds(@RequestBody List<Long> ids); |
| | | |
| | | /** |
| | | * 根据ID查询运维用户信息 |
| | | * @return 用户列表 |
| | | */ |
| | | @GetMapping("/inner/xpOperationsUser/queryById") |
| | | R<XpOperationsUser> queryById(Long id); |
| | | @GetMapping("/logan/inner/xpOperationsUser/queryById") |
| | | R<XpOperationsUser> queryById(@RequestParam Long id); |
| | | |
| | | /** |
| | | * 根据昵称查询运维用户信息 |
| | | * @param nickName 昵称 |
| | | * @return 运维用户列表 |
| | | */ |
| | | @PostMapping("/inner/xpOperationsUser/listByName") |
| | | @PostMapping("/logan/inner/xpOperationsUser/listByName") |
| | | R<List<XpOperationsUser>> listByName(@RequestParam("nickName") String nickName); |
| | | |
| | | /** |
| | | * 根据用户ID列表批量查询用户及角色信息 |
| | | * @param ids 用户ID列表 |
| | | * @return 用户及角色信息列表 |
| | | */ |
| | | @PostMapping("/logan/inner/xpOperationsUser/listByIdsWithRole") |
| | | R<List<XpOperationsUserWithRoleVO>> listByIdsWithRole(@RequestBody List<Long> ids); |
| | | |
| | | /** |
| | | * 根据条件查询用户及角色信息 |
| | | * @param dto 查询条件 |
| | | * @return 用户及角色信息列表 |
| | | */ |
| | | @PostMapping("/logan/inner/xpOperationsUser/queryByConditions") |
| | | R<List<XpOperationsUserWithRoleVO>> queryByConditions(@RequestBody XpOperationsUserQueryDTO dto); |
| | | |
| | | |
| | | /** |
| | | * 查询角色对于的运维人员 |
| | | * @param roleId |
| | | * @return |
| | | */ |
| | | @GetMapping("/logan/inner/xp-operations-role/getXpOperationsRoleByRoleId") |
| | | R<List<XpOperationsRole>> getXpOperationsRoleByRoleId(@RequestParam("roleId") Long roleId); |
| | | |
| | | /** |
| | | * 获取所有启用状态的运维用户 |
| | | * @return 启用状态的用户列表 |
| | | */ |
| | | @GetMapping("/logan/inner/xpOperationsUser/listAllEnabled") |
| | | R<List<XpOperationsUser>> listAllEnabled(); |
| | | |
| | | /** |
| | | * 查询角色关联的运维人员 |
| | | * @param roleIds |
| | | * @return |
| | | */ |
| | | @PostMapping("/logan/inner/xp-operations-role/getXpOperationsRoleByRoleIds") |
| | | R<List<XpOperationsRole>> getXpOperationsRoleByRoleIds(@RequestBody List<Long> roleIds); |
| | | |
| | | /** |
| | | * 根据手机号模糊查询用户(内部接口) |
| | | * |
| | | * @param phoneNumber 手机号 |
| | | * @return 用户信息列表 |
| | | */ |
| | | @PostMapping("/logan/inner/xpOperationsUser/getByPhoneNumber") |
| | | public R<List<XpOperationsUser>> getByPhoneNumber(@RequestParam String phoneNumber); |
| | | |
| | | /** |
| | | * 根据手机号精确查询运维用户(内部接口) |
| | | * |
| | | * @param phoneNumber 手机号 |
| | | * @return 运维用户信息 |
| | | */ |
| | | @GetMapping("/logan/inner/xpOperationsUser/getByExactPhone") |
| | | R<XpOperationsUser> getByExactPhone(@RequestParam("phoneNumber") String phoneNumber); |
| | | } |