|
|
@ -307,9 +307,10 @@ public class StrangerAccessRecordServiceImpl extends BaseServiceImpl<StrangerAcc |
|
|
|
* @param appId |
|
|
|
* @author zxc |
|
|
|
*/ |
|
|
|
public PaCustomerDTO getCustomerInfo(String appId){ |
|
|
|
public PaCustomerDTO getCustomerInfo(String appId) { |
|
|
|
JSONObject jsonObject = new JSONObject(); |
|
|
|
String data = HttpClientManager.getInstance().sendPostByJSON(GuideHttpUrlConstant.CUSTOMER_MSG_URL + appId, JSON.toJSONString(jsonObject)).getData(); |
|
|
|
logger.info("ThirdLoginServiceImpl.getCustomerInfo:httpclient->url:" + GuideHttpUrlConstant.CUSTOMER_MSG_URL + ",结果->" + data); |
|
|
|
JSONObject toResult = JSON.parseObject(data); |
|
|
|
Result mapToResult = ConvertUtils.mapToEntity(toResult, Result.class); |
|
|
|
if (!mapToResult.success()) { |
|
|
@ -318,8 +319,9 @@ public class StrangerAccessRecordServiceImpl extends BaseServiceImpl<StrangerAcc |
|
|
|
} |
|
|
|
Object PublicCustomerResultDTO = mapToResult.getData(); |
|
|
|
JSONObject json = JSON.parseObject(PublicCustomerResultDTO.toString()); |
|
|
|
PublicCustomerResultDTO publicCustomerResultDTO = ConvertUtils.mapToEntity(json, PublicCustomerResultDTO.class); |
|
|
|
PaCustomerDTO customer = publicCustomerResultDTO.getCustomer(); |
|
|
|
Map<String, Object> map = (Map) json.get("customer"); |
|
|
|
PaCustomerDTO customer = ConvertUtils.mapToEntity(map, PaCustomerDTO.class); |
|
|
|
logger.info("小程序登陆third服务获取客户用户信息PaCustomerDTO->" + customer); |
|
|
|
return customer; |
|
|
|
} |
|
|
|
|
|
|
|