feat(order): wappay/index 越南地区追加 USDT(Epay) 支付选项
- Order::wappay/index: area_id=3 时合并 pay_list['epay']['type'] 到 payMethod, 每个选项带 pay_routes 映射到对应 online_order_fac - wappay.html: select 的 option 加 data-url,JS 按选中项查路由 - 兼容旧行为:未设置 pay_routes 时 fallback 到原 online_order_fac
This commit is contained in:
@@ -204,7 +204,7 @@
|
||||
<i class="icon"></i>
|
||||
<select class="select" name="pay_type" id="pay_type">
|
||||
<?php foreach($payMethod as $key=>$method): ?>
|
||||
<option value ="<?=$key?>"><?=$method?></option>
|
||||
<option value ="<?=$key?>" data-url="/order/<?=isset($pay_routes[$key])?$pay_routes[$key]:$online_order_fac?>"><?=$method?></option>
|
||||
<?php endForeach; ?>
|
||||
</select>
|
||||
</div>
|
||||
@@ -233,7 +233,8 @@
|
||||
query.price = price;
|
||||
query.username = username;
|
||||
query.pay_type = pay_type;
|
||||
url = '/order/<?=$online_order_fac ?>';
|
||||
// 每种支付方式对应的 online_order 路由可能不同
|
||||
url = $('#pay_type option:selected').data('url') || '/order/<?=$online_order_fac ?>';
|
||||
//var winRef = window.open("","_blank");
|
||||
$.ajax({
|
||||
url:url,
|
||||
|
||||
Reference in New Issue
Block a user