帮助中心

Shopify支持多种支付方式

"设置"—“收款”

image.png


“手动付款方式”—“添加手动付款方式”

Settings » Payment Providers,在Manual payments区域选择Create custom payment method,然后在Name of the custom payment method中输入支付方式名称+ via LianLianPay(例如ICR via LianLianPay),注意必须以via LianLianPay结尾。


image.png

3.在shopify后台的左下角菜单中,找到Settings » Checkout(结账),在Order processingAdditional scripts(自定义脚本)中填写以下代码:

<script>

var url = window.location.href;

var checkout_reg = new RegExp("\/checkouts\/");

var is_checkout = checkout_reg.test(url);

var gateway = '{{ order.gateway }}';

var financial_status = '{{ order.financial_status }}';

if (gateway.toLowerCase().indexOf('lianlianpay') !== -1 && financial_status == 'pending') {

var checkout_url = "https://gpapi.lianlianpay.com/shopify/manual/orders?order_id={{ order_id }}&shop={{ shop.permanent_domain }}";

if (is_checkout) {

document.body.innerHTML = '<div align="center"><br/>Please wait while we redirect you ...<br/><br/>Click <a href="' + checkout_url + '">here</a> if your browser does not automatically redirect you in 5 seconds ...</div>';

window.location = checkout_url;

} else {

document.addEventListener('DOMContentLoaded', function (event) {

var elements = document.getElementsByClassName('step__footer__continue-btn btn');

if (elements) {

paynow = elements[0];

if (paynow) {

paynow.text = "Pay Now";

paynow.href = checkout_url;

}

}

});

}

}

</script>