支付宝手机支付完结
This commit is contained in:
@@ -117,7 +117,7 @@ public class AlipayServiceImpl implements AlipayService {
|
||||
mercOrder.setReceiver(mercOrder.getReceiver());
|
||||
AlipayClient alipayClient = new DefaultAlipayClient("https://openapi.alipay.com/gateway.do", ParametersUtil.ZY_ALI_APP_ID,
|
||||
ParametersUtil.ZY_PRI, "json", "UTF-8", ParametersUtil.ZY_PUB, "RSA2");
|
||||
AlipayTradeWapPayRequest request = new AlipayTradeWapPayRequest();
|
||||
AlipayTradeAppPayRequest request = new AlipayTradeAppPayRequest();
|
||||
request.setNotifyUrl(ParametersUtil.domain+"/wap/merchant/aliCallBack");
|
||||
request.setReturnUrl("");
|
||||
JSONObject bizContent = new JSONObject();
|
||||
@@ -129,13 +129,12 @@ public class AlipayServiceImpl implements AlipayService {
|
||||
|
||||
bizContent.put("product_code", "QUICK_MSECURITY_PAY");
|
||||
request.setBizContent(bizContent.toString());
|
||||
AlipayTradeWapPayResponse response = null;
|
||||
AlipayTradeAppPayResponse response = null;
|
||||
try {
|
||||
response = response = alipayClient.sdkExecute(request);
|
||||
} catch (AlipayApiException e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
|
||||
if (response.isSuccess()) {
|
||||
System.out.println("success");
|
||||
String body = response.getBody();
|
||||
|
||||
Reference in New Issue
Block a user