public string pay(AlipayTradePagePayModel para) { try { AlipayTradePagePayRequest request = new AlipayTradePagePayRequest(); // 设置同步回调地址 request.SetReturnUrl(""); // 设置异步通知接收地址 request.SetNotifyUrl(""); // 将业务model载入到request para.QrPayMode = "2"; request.SetBizModel(para); AlipayTradePagePayResponse response = client.PageExecute(request, null, "post"); return(response.Body); } catch (Exception e) { Logger.Error("失败", e); return("支付失败"); } }
public T PageExecute <T>(IAopRequest <T> request) where T : AopResponse { return(_aopClient.PageExecute(request)); }