日照智慧社区接口服务
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

301 lines
11 KiB

package com.epmet.feign;
import com.epmet.commons.tools.annotation.LoginUser;
import com.epmet.commons.tools.constant.ServiceConstant;
import com.epmet.commons.tools.security.dto.TokenDto;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.CustomerStaffDTO;
import com.epmet.dto.GovStaffRoleDTO;
import com.epmet.dto.UserBaseInfoDTO;
import com.epmet.dto.UserDTO;
import com.epmet.dto.form.*;
import com.epmet.dto.result.*;
import com.epmet.feign.fallback.EpmetUserOpenFeignClientFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.*;
import java.util.List;
/**
* 本服务对外开放的API,其他服务通过引用此client调用该服务
*
* @author yinzuomei@elink-cn.com
* @date 2020/6/4 13:09
*/
//@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallback = EpmetUserOpenFeignClientFallback.class, url = "localhost:8087")
@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallback = EpmetUserOpenFeignClientFallback.class)
public interface EpmetUserOpenFeignClient {
/**
* 从缓存中查询已登录用户的基本信息以及角色等相关信息
*
* @return
*/
@PostMapping(value = "/epmetuser/user/loginuserdetails", consumes = MediaType.APPLICATION_JSON_UTF8_VALUE)
Result<LoginUserDetailsResultDTO> getLoginUserDetails(@RequestBody LoginUserDetailsFormDTO dto);
/**
* @param formDTO
* @return
* @Author sun
* @Description 根据客户Id和staffId查询一个员工在指定客户下的角色列表
**/
@PostMapping(value = "/epmetuser/staffrole/getcustomerstaffrolelist", consumes = MediaType.APPLICATION_JSON_UTF8_VALUE)
Result<List<CustomerStaffRoleListResultDTO>> getCustomerStaffRoleList(@RequestBody CustomerStaffRoleListFormDTO formDTO);
/**
* 根据staffId查询人员拥有的所有角色信息
*
* @param staffId
* @return com.epmet.commons.tools.utils.Result<java.util.List < com.epmet.dto.result.CustomerStaffRoleResultDTO>>
* @author zhaoqifeng
* @date 2020/6/2 16:11
*/
@PostMapping("/epmetuser/staffrole/staffroles/{staffId}")
Result<List<CustomerStaffRoleResultDTO>> getStaffRoles(@PathVariable String staffId);
/**
* @param staffId
* @return
* @Author sun
* @Description 根据staffId查询工作人员基本信息
**/
@PostMapping("/epmetuser/customerstaff/getcustomerstaff/{staffId}")
Result<CustomerStaffDTO> getCustomerStaff(@PathVariable("staffId") String staffId);
/**
* @param formDTO
* @Description 根据userId获取customerId
* @author zxc
*/
@PostMapping(value = "/epmetuser/user/getcustomeridbyuserid", consumes = MediaType.APPLICATION_JSON_UTF8_VALUE)
Result<TagCustomerResultDTO> getCustomerIdByUserId(@RequestBody TagCustomerFormDTO formDTO);
/**
* 根据角色id列表批量查询角色信息
* @param form
* @return
*/
@PostMapping(value = "/epmetuser/govstaffrole/getbyids", consumes = MediaType.APPLICATION_JSON_UTF8_VALUE)
Result<List<GovStaffRoleResultDTO>> getByIds(@RequestBody GovStaffRoleFormDTO form);
/**
* @return com.epmet.commons.tools.utils.Result
* @param staffResetPwFormDTO
* @author yinzuomei
* @description 工作端,修改工作人员密码
* @Date 2020/7/1 10:37
**/
@PostMapping(value = "/epmetuser/customerstaff/resetstaffpassword", consumes = MediaType.APPLICATION_JSON_UTF8_VALUE)
Result resetStaffPassword(@RequestBody StaffResetPwFormDTO staffResetPwFormDTO);
/**
* 根据客户ID和角色key查询角色信息
* @param form
* @return
*/
@PostMapping("/epmetuser/staffrole/roleofcustomer")
Result<GovStaffRoleDTO> getRoleOfCustomer(@RequestBody CustomerRoleFormDTO form);
/**
* 小程序登陆新增或更新微信用户信息
* @author sun
*/
@PostMapping(value = "epmetuser/user/savewxuser")
Result<UserDTO> saveWxUser(@RequestBody WxUserFormDTO wxUserFormDTO);
/**
* @param openId
* @return com.epmet.commons.tools.utils.Result<com.epmet.dto.result.LatestStaffWechatLoginDTO>
* @Author sun
* @Description 获取当前微信上次登录的账号信息
**/
@GetMapping(value = "epmetuser/staffagencyvisited/getlatest/{openId}")
Result<StaffLatestAgencyResultDTO> getLatestStaffWechatLoginRecord(@PathVariable("openId") String openId);
/**
* @param staffWechatFormDTO
* @return com.epmet.commons.tools.utils.Result
* @Author sun
* @Description 手机验证码登录时记录微信openId与当前用户的关系
**/
@PostMapping(value = "epmetuser/staffwechat/savestaffwechat", consumes = MediaType.APPLICATION_JSON_VALUE)
Result saveStaffWechat(@RequestBody StaffWechatFormDTO staffWechatFormDTO);
/**
* @param staffLoginHistoryFormDTO
* @return com.epmet.commons.tools.utils.Result
* @Author sun
* @Description 保存登录日志
**/
@PostMapping(value = "epmetuser/staffagencyvisited/saveStaffLoginRecord", consumes = MediaType.APPLICATION_JSON_VALUE)
Result saveStaffLoginRecord(StaffLoginAgencyRecordFormDTO staffLoginHistoryFormDTO);
/**
* @Author sun
* @Description 保存登录日志
*/
@PostMapping("/epmetuser/staffrole/staffroles")
Result<List<GovStaffRoleDTO>> getRolesOfStaff(StaffRoleFormDTO staffRoleFormDTO);
/**
* @param customerStaffFormDTO
* @return
* @Author sun
* @Description 根据手机号+客户id获取工作人员基本信息
**/
@PostMapping(value = "epmetuser/customerstaff/getcustomerstaffinfo", consumes = MediaType.APPLICATION_JSON_VALUE)
Result<CustomerStaffDTO> getCustomerStaffInfo(@RequestBody CustomerStaffFormDTO customerStaffFormDTO);
/**
* @param userIdList
* @return com.epmet.commons.tools.utils.Result<java.util.List < com.epmet.dto.result.UserBaseInfoResultDTO>>
* @author yinzuomei
* @description 传入用户id集合,返回用户的基本信息(包含微信基本信息)
* @Date 2020/7/22 9:30
**/
@PostMapping("/epmetuser/userbaseinfo/queryuserbaseinfo")
Result<List<UserBaseInfoResultDTO>> queryUserBaseInfo(@RequestBody List<String> userIdList);
/**
* 根据用户ID,查询用户所属角色: 多种身份
*
* @param userId
* @return com.epmet.commons.tools.utils.Result<java.util.List<com.epmet.dto.result.UserRoleResultDTO>>
* @Author zhangyong
* @Date 14:13 2020-07-23
**/
@GetMapping(value = "epmetuser/userrole/getuserroleinfobyuserid/{userId}")
Result<List<UserRoleResultDTO>> getUserRoleInfoByUserId(@PathVariable("userId") String userId);
/**
* 同步-居民基础信息、用户微信信息
*
* @param formDTO
* @return com.epmet.commons.tools.utils.Result
* @Author zhangyong
* @Date 14:37 2020-07-23
**/
@PostMapping("epmetuser/user/updateUserBaseAndWxUserInfo")
Result updateUserBaseAndWxUserInfo(@RequestBody WxUserInfoFormDTO formDTO);
/**
* @Description 新增或保存用户基本信息
* @param baseInfo
* @return
* @author wangc
* @date 2020.07.23 13:31
**/
@PostMapping("/epmetuser/userbaseinfo/saveuserbaseinfo")
Result saveUserBaseInfo(@RequestBody UserBaseInfoDTO baseInfo);
/**
* @Description 查询客户下所有用户包括陌生人
* @param param
* @return
* @author wangc
* @date 2020.07.25 16:15
**/
@PostMapping("/epmetuser/gridlatest/customeruserlist")
Result<List<CustomerUser4PointResultDTO>> customerUserList(@RequestBody CustomerUserFormDTO param);
/**
* @Description 查询用户详情信息
* @param param
* @return
* @author wangc
* @date 2020.07.27 01:34
**/
@PostMapping("/epmetuser/userbaseinfo/customeruserdetail")
Result<CustomerUserDetailResultDTO> customerUserDetail(@RequestBody IssueInitiatorFormDTO param);
/**
* @Description 得到工组人员的头像、名称、所属机关名称
* @param userId
* @return
* @author wangc
* @date 2020.07.27 14:45
**/
@PostMapping("/epmetuser/customerstaff/staffmsg")
Result<StaffEtAgencyResultDTO> staffMsg(@RequestBody IssueInitiatorFormDTO userId);
/**
* @param formDTO
* @return
* @Author sun
* @Description 根据客户ID、手机号查询政府端工作人员基本信息,校验用户是否存在
**/
@GetMapping(value = "epmetuser/customerstaff/getCustsomerStaffByIdAndPhone")
Result<List<CustomerStaffDTO>> getCustsomerStaffByIdAndPhone(@RequestBody ThirdCustomerStaffFormDTO formDTO);
/**
* 获取用户基础信息
*
* @param tokenDTO
* @return com.epmet.commons.tools.utils.Result<com.epmet.dto.result.ResiUserBaseInfoResultDTO>
* @Author zhangyong
* @Date 14:10 2020-07-30
**/
@PostMapping("/epmetuser/userbaseinfo/selectuserbaseinfo")
Result<ResiUserBaseInfoResultDTO> selectUserBaseInfo(@RequestBody TokenDto tokenDTO);
/**
* @Description 认证志愿者时保存/修改用户基础信息
* @param param
* @return
* @author wangc
* @date 2020.07.31 09:38
**/
@PostMapping("/epmetuser/userbaseinfo/volunteerbaseinfo")
Result volunteerBaseInfo(@RequestBody ResiVolunteerAuthenticateFormDTO param);
/**
* @return
* @param formDTO
* @Author sun
* @Description 单客户-获取用户最近访问网格
* @Date 2020/8/3
**/
@PostMapping(value = "epmetuser/gridlatest/latestgridinfo")
Result<LatestGridInfoResultDTO> latestGridInfo(@RequestBody LatestGridInfoFormDTO formDTO);
/**
* @Description 查询工作人员的信息
* @param formDTO
* @author zxc
* @date 2020/8/13 1:37 下午
*/
@PostMapping("epmetuser/customerstaff/getstaffinfolist")
Result<List<StaffSinGridResultDTO>> getStaffInfoList(@RequestBody UserIdsFormDTO formDTO);
/**
* @Description 根绝staffId查询最近一次(既当前)登录到的AgencyId
* @param staffId
* @return
* @author wangc
* @date 2020.08.17 17:45
**/
@GetMapping("/epmetuser/staffagencyvisited/latestagency/{staffId}")
Result<String> latestAgency(@PathVariable("staffId") String staffId);
/**
* 修改根管理员信息
* @author zhaoqifeng
* @date 2020/8/19 14:31
* @param formDTO
* @return com.epmet.commons.tools.utils.Result
*/
@PostMapping("epmetuser/customerstaff/updaterootmanage")
Result updateRootManage(@RequestBody UpdateRootManageFormDTO formDTO);
/**
* @Description 查找工作人员的信息 - 对外开放接口
* @param staffParam
* @return
* @author wangc
* @date 2020.08.17 10:30
**/
@PostMapping("epmetuser/customerstaff/extstaffinfo")
Result<ExtStaffInfoResultDTO> extStaffInfo(@RequestBody CommonStaffIdFormDTO staffParam);
}