|
|
@ -507,6 +507,7 @@ public class ThirdLoginServiceImpl implements ThirdLoginService { |
|
|
|
public PaCustomerDTO getCustomerInfo(String appId){ |
|
|
|
JSONObject jsonObject = new JSONObject(); |
|
|
|
String data = HttpClientManager.getInstance().sendPostByJSON(AuthHttpUrlConstant.CUSTOMER_MSG_URL + appId, JSON.toJSONString(jsonObject)).getData(); |
|
|
|
logger.info("httpclient->url:"+AuthHttpUrlConstant.CUSTOMER_MSG_URL+",结果->"+data); |
|
|
|
JSONObject toResult = JSON.parseObject(data); |
|
|
|
Result mapToResult = ConvertUtils.mapToEntity(toResult, Result.class); |
|
|
|
if (!mapToResult.success()) { |
|
|
@ -517,6 +518,7 @@ public class ThirdLoginServiceImpl implements ThirdLoginService { |
|
|
|
JSONObject json = JSON.parseObject(PublicCustomerResultDTO.toString()); |
|
|
|
PublicCustomerResultDTO publicCustomerResultDTO = ConvertUtils.mapToEntity(json, PublicCustomerResultDTO.class); |
|
|
|
PaCustomerDTO customer = publicCustomerResultDTO.getCustomer(); |
|
|
|
logger.info("小程序登陆third服务获取客户用户信息PaCustomerDTO->"+customer); |
|
|
|
return customer; |
|
|
|
} |
|
|
|
|
|
|
@ -527,6 +529,7 @@ public class ThirdLoginServiceImpl implements ThirdLoginService { |
|
|
|
*/ |
|
|
|
public UserWechatDTO getUserWeChat(WxLoginFormDTO resiLoginFormDTO){ |
|
|
|
String data = HttpClientManager.getInstance().sendPostByJSON(AuthHttpUrlConstant.RESI_AND_WORK_LOGIN_URL, JSON.toJSONString(resiLoginFormDTO)).getData(); |
|
|
|
logger.info("httpclient->url:"+AuthHttpUrlConstant.RESI_AND_WORK_LOGIN_URL+",结果->"+data); |
|
|
|
JSONObject toResult = JSON.parseObject(data); |
|
|
|
Result mapToResult = ConvertUtils.mapToEntity(toResult, Result.class); |
|
|
|
if (!mapToResult.success()) { |
|
|
@ -536,6 +539,7 @@ public class ThirdLoginServiceImpl implements ThirdLoginService { |
|
|
|
Object UserWeChatDTO = mapToResult.getData(); |
|
|
|
JSONObject json = JSON.parseObject(UserWeChatDTO.toString()); |
|
|
|
UserWechatDTO userWechatDTO = ConvertUtils.mapToEntity(json, UserWechatDTO.class); |
|
|
|
logger.info("小程序登陆third服务获取微信用户信息userWechatDTO->"+userWechatDTO); |
|
|
|
return userWechatDTO; |
|
|
|
} |
|
|
|
|
|
|
|