mirror of
https://gitee.com/hhyykk/ipms-sjy.git
synced 2025-07-17 12:35:07 +08:00
修改code review
This commit is contained in:
@ -84,22 +84,21 @@ public class PayOrderController {
|
||||
public String notifyAliPayWapPayOrder(@PathVariable("channelId") Long channelId,
|
||||
@RequestParam Map<String, String> params,
|
||||
@RequestBody String originData) throws Exception {
|
||||
//TODO @jason 校验 是否支付宝调用。 使用 支付宝publickey payclient 或许加一个校验方法
|
||||
//TODO @jason 校验 是否支付宝调用。 payclient 中加一个校验方法
|
||||
payOrderCoreService.notifyPayOrder(channelId, PayChannelEnum.ALIPAY_WAP.getCode(), PayNotifyDataDTO.builder().params(params).body(originData).build());
|
||||
return "success";
|
||||
}
|
||||
|
||||
// TODO @jason 如果有些字段不注释,可以删除哈。不然 IDEA 会报警
|
||||
|
||||
/**
|
||||
* https://opendocs.alipay.com/open/203/105285#%E5%89%8D%E5%8F%B0%E5%9B%9E%E8%B7%B3%E5%8F%82%E6%95%B0%E8%AF%B4%E6%98%8E
|
||||
* @param channelId
|
||||
* @return
|
||||
* @throws Exception
|
||||
* @param channelId 渠道id
|
||||
* @return 返回跳转页面
|
||||
*/
|
||||
@GetMapping(value = "/return/alipay-wap/{channelId}")
|
||||
@ApiOperation("支付宝wap页面回跳")
|
||||
public String returnAliPayWapPayOrder(@PathVariable("channelId") Long channelId){
|
||||
//TODO @jason 校验 是否支付宝调用。 支付宝publickey 可以根据 appId 跳转不同的页面
|
||||
//TODO 校验 是否支付宝调用。 可以根据 appId 跳转不同的页面
|
||||
return "支付成功";
|
||||
}
|
||||
|
||||
|
@ -155,4 +155,4 @@ yudao:
|
||||
pay:
|
||||
pay-notify-url: http://jg6rde.natappfree.cc/api/pay/order/notify
|
||||
refund-notify-url: http://jg6rde.natappfree.cc/api/pay/refund/notify
|
||||
return-url: http://jg6rde.natappfree.cc/api/pay/order/return
|
||||
pay-return-url: http://jg6rde.natappfree.cc/api/pay/order/return
|
||||
|
@ -9,18 +9,17 @@
|
||||
<body>
|
||||
<div>点击如下按钮,发起支付的测试</div>
|
||||
<div>
|
||||
<button id="alipay_wap">支付宝h5</button>
|
||||
<button id="alipay_wap">支付宝手机网站支付</button>
|
||||
</div>
|
||||
<div id="dynamic_form"></div>
|
||||
</body>
|
||||
<script>
|
||||
// TODO @jason:copy 过来后,有些注释要改过来哈
|
||||
|
||||
let shopOrderId = undefined;
|
||||
let payOrderId = undefined;
|
||||
let server = 'http://127.0.0.1:28080';
|
||||
//let server = 'http://niubi.natapp1.cc';
|
||||
// TODO openid
|
||||
//let openid = "ockUAwIZ-0OeMZl9ogcZ4ILrGba0";
|
||||
|
||||
$(function() {
|
||||
// 自动发起商城订单编号
|
||||
$.ajax({
|
||||
@ -38,7 +37,7 @@
|
||||
}
|
||||
})
|
||||
});
|
||||
// 微信公众号
|
||||
|
||||
$( "#alipay_wap").on( "click", function() {
|
||||
// 提交支付
|
||||
$.ajax({
|
||||
@ -56,7 +55,7 @@
|
||||
return;
|
||||
}
|
||||
alert('点击确定,开始支付');
|
||||
// 开始调用微信支付
|
||||
//支付宝 手机WAP 返回表单,自动跳到支付宝支付页面
|
||||
let data = result.data.invokeResponse;
|
||||
$("#dynamic_form").html(data.body);
|
||||
}
|
||||
|
Reference in New Issue
Block a user