Authored by Lixiaodi

Merge branch 'dev_pay_million' into test6.8.8

@@ -243,7 +243,13 @@ public abstract class AlipayServiceAbstract extends AbstractPayService { @@ -243,7 +243,13 @@ public abstract class AlipayServiceAbstract extends AbstractPayService {
243 243
244 private String sendMApiRequestWithException(String orderCode, Map<String, String> paramMap) throws Exception { 244 private String sendMApiRequestWithException(String orderCode, Map<String, String> paramMap) throws Exception {
245 logger.info("[{}] send openapi request: {}", orderCode, paramMap); 245 logger.info("[{}] send openapi request: {}", orderCode, paramMap);
246 - String response = httpClient.postFormData(AlipayConfig.MAPI_URL, paramMap); 246 + StringBuilder paramStr = new StringBuilder();
  247 + for(Map.Entry<String, String> entry : paramMap.entrySet()) {
  248 + paramStr.append("&").append(entry.getKey()).append("=").append(URLEncoder.encode(entry.getValue(),AlipayConfig.input_charset));
  249 + }
  250 + String url = AlipayConfig.MAPI_URL +"?"+paramStr.substring(1);
  251 + logger.info("[{}] send openapi requestUrl is: {}", orderCode, url);
  252 + String response = httpClient.get(url);
247 logger.info("[{}] trade openapi resp: {}", orderCode, response); 253 logger.info("[{}] trade openapi resp: {}", orderCode, response);
248 return response; 254 return response;
249 } 255 }