old mode 100644
new mode 100755
| | |
| | | * @return |
| | | * @throws Exception |
| | | */ |
| | | public String confirmPayFee(String param) { |
| | | public String confirmPayFee(String param, String wId) { |
| | | String resXml = ""; |
| | | try { |
| | | Map<String, Object> map = PayUtil.getMapFromXML(param); |
| | |
| | | } else { |
| | | openId = map.get("openid").toString(); |
| | | } |
| | | |
| | | responseEntity = getUserInfoByOpenId(restTemplate, openId); |
| | | |
| | | logger.debug("查询用户信息返回报文:" + responseEntity); |
| | | if (responseEntity.getStatusCode() != HttpStatus.OK) { |
| | | throw new IllegalArgumentException("根绝openId 查询用户信息异常" + openId); |
| | | } |
| | | |
| | | JSONObject userResult = JSONObject.parseObject(responseEntity.getBody()); |
| | | JSONObject realUserInfo = userResult.getJSONArray("data").getJSONObject(0); |
| | | String useId = realUserInfo.getString("userId"); |
| | | String useId = "-1"; |
| | | if (userResult.containsKey("data") && userResult.getJSONArray("data").size() > 0) { |
| | | JSONObject realUserInfo = userResult.getJSONArray("data").getJSONObject(0); |
| | | useId = realUserInfo.getString("userId"); |
| | | } |
| | | |
| | | //查询用户ID |
| | | JSONObject paramIn = new JSONObject(); |
| | |
| | | responseEntity = new ResponseEntity<String>(e.getMessage(), HttpStatus.INTERNAL_SERVER_ERROR); |
| | | } finally { |
| | | logger.debug("请求地址为,{} 请求中心服务信息,{},中心服务返回信息,{}", url, httpEntity, responseEntity); |
| | | return responseEntity; |
| | | } |
| | | |
| | | return responseEntity; |
| | | } |
| | | |
| | | |