Merge remote-tracking branch 'origin/alipayplus_aps' into alipayplus_aps

master
yixian 3 years ago
commit de20562e8e

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.1 KiB

@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg width="200px" height="80px" viewBox="0 0 200 80" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>A+Partner-200X80-竖版</title>
<g id="A+Partner-200X80-竖版" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<g id="IA+Partner-200X80-竖版">
<rect id="矩形" x="0" y="0" width="200" height="80"></rect>
<g id="编组-3" transform="translate(2.500000, 2.500000)">
<path d="M97.7444542,29.1648069 C97.7444542,28.4221226 97.8929911,27.6794383 98.4880387,27.0843907 C99.4278719,26.1436573 101.259827,25.4513855 105.468371,24.4602395 L105.468371,30.7978121 C103.389755,31.9374949 102.20146,32.3831055 100.815116,32.3831055 C98.9327491,32.3831055 97.7444542,31.1452984 97.7444542,29.1648069 L97.7444542,29.1648069 Z M74.6690283,16.2412001 C77.5911534,16.2412001 79.919131,18.5682775 79.919131,23.5195061 C79.919131,29.8588792 76.5018831,32.6801792 72.6894371,32.6801792 C71.7982159,32.6801792 70.9556069,32.5811547 70.0157736,32.2840809 L70.0157736,17.9246178 C71.6496791,16.7858352 72.9865108,16.2412001 74.6690283,16.2412001 L74.6690283,16.2412001 Z M141.17033,10.7453363 L141.220742,10.6958241 L133.841611,10.6958241 L129.187456,26.8377295 L128.938995,26.8377295 L123.592568,10.6958241 L114.827993,10.6958241 L125.37411,37.3352343 L120.968417,45.4561494 L120.968417,45.6532984 L127.849724,45.6532984 L141.17033,10.7453363 Z M49.1197885,37.2362098 L56.9427297,37.2362098 L56.9427297,10.6958241 L49.1197885,10.6958241 L49.1197885,37.2362098 Z M106.410004,37.2362098 L114.233846,37.2362098 L113.292212,30.6015634 L113.292212,19.5090109 C113.292212,13.4676118 109.728228,10.1502887 103.439267,10.1502887 C99.4278719,10.1502887 96.6551839,10.8443609 91.6049308,12.3792418 L92.9912748,18.4692529 C97.5968176,16.3897369 99.6268213,15.4985158 101.754949,15.4985158 C104.330488,15.4985158 105.468371,17.3304704 105.468371,20.1535709 L105.468371,20.3507198 C96.5066471,22.0341375 93.7348593,22.9757712 92.001029,24.707801 C90.7128094,25.9960206 90.1690745,27.8279752 90.1690745,29.9570035 C90.1690745,35.056769 94.1300573,37.7799447 97.8434788,37.7799447 C100.616167,37.7799447 102.84422,36.7410869 105.865369,34.4635217 L106.410004,37.2362098 Z M74.5718042,37.5827958 C81.5530365,37.5827958 87.841997,32.4326178 87.841997,23.2719447 C87.841997,15.052005 83.2859665,10.1502887 77.6406657,10.1502887 C74.7698533,10.1502887 72.5409002,11.239559 70.0157736,13.3199752 L70.0157736,10.6958241 L62.1919322,10.6958241 L62.1919322,45.6532984 L70.0157736,45.6532984 L70.0157736,36.9886483 C71.5020424,37.3838464 72.8874862,37.5827958 74.5718042,37.5827958 L74.5718042,37.5827958 Z M10.8440908,24.707801 L15.4991459,8.61540782 L15.6962949,8.61540782 L20.1037885,24.707801 L10.8440908,24.707801 Z M0,37.2362098 L7.22969397,37.2362098 L9.20928518,30.4026141 L21.6386694,30.4026141 L23.519236,37.2362098 L32.7789337,37.2362098 L22.2319166,2.32644728 L11.735312,2.32644728 L0,37.2362098 Z M35.9486203,37.2362098 L43.7715614,37.2362098 L43.7715614,1.08954036 L35.9486203,1.08954036 L35.9486203,37.2362098 Z" id="Fill-7726" fill="#3F3A39"></path>
<path d="M48.5258211,4.30756888 C48.5258211,6.88220774 50.4081882,8.61513775 53.0323394,8.61513775 C55.6564905,8.61513775 57.5370572,6.88220774 57.5370572,4.30756888 C57.5370572,1.78244229 55.6564905,0 53.0323394,0 C50.4081882,0 48.5258211,1.78244229 48.5258211,4.30756888" id="Fill-7728" fill="#0075FF"></path>
<path d="M194.630095,27.7094158 L176.867788,27.7094158 C171.976874,27.7094158 168.014091,23.744832 168.014091,18.8566191 L190.356735,18.8566191 C192.717121,18.8566191 194.630095,20.7695937 194.630095,23.1299794 L194.630095,27.7094158 Z" id="Fill-7730" fill="#0075FF"></path>
<path d="M163.709583,27.7094158 L154.524604,27.7094158 C152.164218,27.7094158 150.251243,25.7955409 150.251243,23.4351552 L150.251243,18.8566191 L163.709583,18.8566191 L163.709583,27.7094158 Z" id="Fill-7732" fill="#00B7FF"></path>
<path d="M168.013731,18.856169 L168.013731,1.09296121 L172.594067,1.09296121 C174.954453,1.09296121 176.866527,3.00683611 176.866527,5.36632159 L176.866527,27.7089657 C171.977414,27.7089657 168.013731,23.7452821 168.013731,18.856169" id="Fill-7734" fill="#0075FF"></path>
<path d="M168.013731,41.198723 L168.013731,32.0524535 L176.866527,32.0524535 L176.866527,45.4720834 L172.287091,45.4720834 C169.926705,45.4720834 168.013731,43.5591087 168.013731,41.198723" id="Fill-7736" fill="#00B7FF"></path>
<path d="M6.71287573,58.5978804 L6.71287573,66.1399519 L11.5911862,66.1399519 C12.7812815,66.1399519 13.7454208,65.8257739 14.4836039,65.1947173 C15.2190864,64.5636608 15.5890783,63.617526 15.5890783,62.3554128 C15.5890783,61.0941999 15.2190864,60.1534664 14.4836039,59.5296116 C13.7454208,58.9084575 12.7812815,58.5978804 11.5911862,58.5978804 L6.71287573,58.5978804 Z M11.751426,56.7857308 C12.6030373,56.7857308 13.3889323,56.9180636 14.109111,57.1854299 C14.8301899,57.4518961 15.4504439,57.8245885 15.9752741,58.3044076 C16.4992041,58.7851269 16.9034044,59.3666712 17.187875,60.050841 C17.4723456,60.7350107 17.6145809,61.5038015 17.6145809,62.3554128 C17.6145809,63.2088246 17.4723456,63.9776153 17.187875,64.6617851 C16.9034044,65.3459549 16.4992041,65.9320003 15.9752741,66.4208216 C15.4504439,66.9096429 14.8301899,67.2868365 14.109111,67.5533026 C13.3889323,67.8197687 12.6030373,67.9530018 11.751426,67.9530018 L6.71287573,67.9530018 L6.71287573,75.7624396 L4.6864729,75.7624396 L4.6864729,56.7857308 L11.751426,56.7857308 Z" id="Fill-7738" fill="#3F3A39"></path>
<path d="M34.2733946,69.7126684 L41.3365472,69.7126684 L37.817574,59.6634748 L34.2733946,69.7126684 Z M45.6270118,75.7621695 L43.4691764,75.7621695 L41.9495993,71.4726051 L33.6594422,71.4726051 L32.1407654,75.7621695 L29.9820297,75.7621695 L36.9650625,56.7863609 L38.6709858,56.7863609 L45.6270118,75.7621695 Z" id="Fill-7740" fill="#3F3A39"></path>
<path d="M62.9786375,58.5978804 L62.9786375,65.5548067 L68.0432942,65.5548067 C69.1622719,65.5548067 70.0732979,65.2712363 70.7754722,64.7013949 C71.4767462,64.1324538 71.8269331,63.2619378 71.8269331,62.0889467 C71.8269331,60.9159556 71.4767462,60.0409385 70.7754722,59.4638953 C70.0732979,58.8868521 69.1622719,58.5978804 68.0432942,58.5978804 L62.9786375,58.5978804 Z M68.2287402,56.7857308 C69.0470433,56.7857308 69.8023307,56.9045602 70.4955027,57.1458201 C71.1886747,57.3852795 71.7828221,57.7318655 72.2815459,58.1846779 C72.7784692,58.6383905 73.164665,59.1938283 73.4401334,59.8509914 C73.7165019,60.5081544 73.8533359,61.2454374 73.8533359,62.0628402 C73.8533359,63.4491842 73.470741,64.580765 72.7073515,65.4611835 C71.9430619,66.3407017 70.948315,66.9051418 69.7222108,67.1536034 L74.2260284,75.7624396 L71.85484,75.7624396 L67.5364684,67.3408499 L62.9786375,67.3408499 L62.9786375,75.7624396 L60.9531348,75.7624396 L60.9531348,56.7857308 L68.2287402,56.7857308 Z" id="Fill-7742" fill="#3F3A39"></path>
<polygon id="Fill-7744" fill="#3F3A39" points="101.120292 58.5978804 95.6289293 58.5978804 95.6289293 75.7624396 93.6043269 75.7624396 93.6043269 58.5978804 88.1129643 58.5978804 88.1129643 56.7857308 101.120292 56.7857308"></polygon>
<polygon id="Fill-7746" fill="#3F3A39" points="130.945503 75.7623496 129.026226 75.7623496 118.951827 60.5431731 118.951827 75.7623496 116.926324 75.7623496 116.926324 56.7856407 118.8456 56.7856407 128.92 71.951704 128.92 56.7856407 130.945503 56.7856407"></polygon>
<polygon id="Fill-7748" fill="#3F3A39" points="160.477871 58.5978804 150.72215 58.5978804 150.72215 65.2883406 159.038414 65.2883406 159.038414 67.09959 150.72215 67.09959 150.72215 73.9502899 160.477871 73.9502899 160.477871 75.7624396 148.696647 75.7624396 148.696647 56.7857308 160.477871 56.7857308"></polygon>
<path d="M178.974671,58.5978804 L178.974671,65.5548067 L184.039327,65.5548067 C185.158305,65.5548067 186.069331,65.2712363 186.771505,64.7013949 C187.472779,64.1324538 187.823866,63.2619378 187.823866,62.0889467 C187.823866,60.9159556 187.472779,60.0409385 186.771505,59.4638953 C186.069331,58.8868521 185.158305,58.5978804 184.039327,58.5978804 L178.974671,58.5978804 Z M184.225674,56.7857308 C185.043076,56.7857308 185.798364,56.9045602 186.491536,57.1458201 C187.184708,57.3852795 187.779755,57.7318655 188.277579,58.1846779 C188.774502,58.6383905 189.160698,59.1938283 189.436166,59.8509914 C189.712535,60.5081544 189.849369,61.2454374 189.849369,62.0628402 C189.849369,63.4491842 189.466774,64.580765 188.703385,65.4611835 C187.939095,66.3407017 186.944348,66.9051418 185.718244,67.1536034 L190.222062,75.7624396 L187.850873,75.7624396 L183.532502,67.3408499 L178.974671,67.3408499 L178.974671,75.7624396 L176.949168,75.7624396 L176.949168,56.7857308 L184.225674,56.7857308 Z" id="Fill-7750" fill="#3F3A39"></path>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 8.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.1 KiB

@ -37,6 +37,14 @@ $(document).ready(function () {
location.href = window.redirect; location.href = window.redirect;
return; return;
} }
if (pay.web_url) {
location.href = pay.web_url;
return;
}
if (pay.mweb_url) {
location.href = pay.mweb_url;
return;
}
if (window.AlipayJSBridge) { if (window.AlipayJSBridge) {
callPayment(); callPayment();
} else { } else {

@ -9,9 +9,18 @@ $(document).ready(function () {
if(window.openmobilefun == 'wechat'|| window.openmobilefun == 'other'){ if(window.openmobilefun == 'wechat'|| window.openmobilefun == 'other'){
paymentFun = 'Wechat' paymentFun = 'Wechat'
}else{ }
else if(window.openmobilefun == 'alipayaps'|| window.openmobilefun == 'alipayaps_cn'){
paymentFun = 'AlipayAps'
$(".select_wechat").empty();
$(".select_alipay_aps").append(selectPaymentHTML);
$(".select_alipay").empty();
$(".select_bank").empty();
}
else{
paymentFun = 'Alipay' paymentFun = 'Alipay'
$(".select_wechat").empty(); $(".select_wechat").empty();
$(".select_alipay_aps").empty();
$(".select_alipay").append(selectPaymentHTML); $(".select_alipay").append(selectPaymentHTML);
$(".select_bank").empty(); $(".select_bank").empty();
} }
@ -35,6 +44,8 @@ $(document).ready(function () {
paymentFun = 'Wechat' paymentFun = 'Wechat'
$(".select_wechat").append(selectPaymentHTML); $(".select_wechat").append(selectPaymentHTML);
$(".select_alipay").empty(); $(".select_alipay").empty();
$(".select_alipay_aps").empty();
$(".select_bank").empty(); $(".select_bank").empty();
} }
}) })
@ -42,15 +53,28 @@ $(document).ready(function () {
if(paymentFun != 'Alipay'){ if(paymentFun != 'Alipay'){
paymentFun = 'Alipay' paymentFun = 'Alipay'
$(".select_wechat").empty(); $(".select_wechat").empty();
$(".select_alipay_aps").empty();
$(".select_alipay").append(selectPaymentHTML); $(".select_alipay").append(selectPaymentHTML);
$(".select_bank").empty(); $(".select_bank").empty();
} }
}) })
$("#select_alipay_aps").click(function(){
if(paymentFun != 'AlipayAps'){
paymentFun = 'AlipayAps'
$(".select_wechat").empty();
$(".select_alipay").empty();
$(".select_alipay_aps").append(selectPaymentHTML);
$(".select_bank").empty();
}
})
$("#select_bank").click(function(){ $("#select_bank").click(function(){
if(paymentFun != 'Bank'){ if(paymentFun != 'Bank'){
paymentFun = 'Bank' paymentFun = 'Bank'
$(".select_wechat").empty(); $(".select_wechat").empty();
$(".select_alipay").empty(); $(".select_alipay").empty();
$(".select_alipay_aps").empty();
$(".select_bank").append(selectPaymentHTML); $(".select_bank").append(selectPaymentHTML);
} }
}) })
@ -81,6 +105,13 @@ $(document).ready(function () {
redirectH5Payment(res.partner_order_id,res.client_moniker) redirectH5Payment(res.partner_order_id,res.client_moniker)
} }
} }
if(paymentFun == 'AlipayAps'){
if(window.openmobilefun == 'alipayaps'){
callPayment(res);
}else{
redirectH5PaymentForAps(res.partner_order_id,res.client_moniker)
}
}
if(paymentFun == 'Alipay'){ if(paymentFun == 'Alipay'){
if(window.openmobilefun == 'alipay'){ if(window.openmobilefun == 'alipay'){
callPayment(res); callPayment(res);
@ -108,6 +139,9 @@ $(document).ready(function () {
function redirectH5Payment(orderId,clientMoniker){ function redirectH5Payment(orderId,clientMoniker){
window.location.href='/api/v1.0/share_code/business/bills/'+clientMoniker+'/orders/'+orderId+'/pay'; window.location.href='/api/v1.0/share_code/business/bills/'+clientMoniker+'/orders/'+orderId+'/pay';
} }
function redirectH5PaymentForAps(orderId,clientMoniker){
window.location.href='/api/v1.0/share_code/business/bills/'+clientMoniker+'/orders/'+orderId+'/alipayaps_pay';
}
function getShareLink(){ function getShareLink(){
var paymentLink = '' var paymentLink = ''
@ -127,6 +161,13 @@ $(document).ready(function () {
paymentLink = '/api/v1.0/share_code/business/bills/'+window.billInfo.bill_code_id+'/alipay/mobile/redirectApp?priorityChannel=Alipay'; paymentLink = '/api/v1.0/share_code/business/bills/'+window.billInfo.bill_code_id+'/alipay/mobile/redirectApp?priorityChannel=Alipay';
} }
} }
if(paymentFun == 'AlipayAps'){
if(window.openmobilefun == 'alipayaps'|| window.openmobilefun == 'alipayaps_cn'){
paymentLink = '/api/v1.0/share_code/business/bills/'+window.billInfo.bill_code_id+'/alipay_aps/mobile';
}else{
paymentLink = '/api/v1.0/share_code/business/bills/'+window.billInfo.bill_code_id+'/alipay_aps/mobile/redirectApp?priorityChannel=AlipayAps';
}
}
if(paymentFun == 'Bank'){ if(paymentFun == 'Bank'){
paymentLink = '/api/v1.0/share_code/business/bills/'+window.billInfo.bill_code_id+'/cbbank/mobile?partner_moniker='+window.clientmoniker; paymentLink = '/api/v1.0/share_code/business/bills/'+window.billInfo.bill_code_id+'/cbbank/mobile?partner_moniker='+window.clientmoniker;
} }
@ -147,6 +188,14 @@ $(document).ready(function () {
} }
} }
if(paymentFun == 'AlipayAps'){
if(window.openmobilefun == 'alipayaps'|| window.openmobilefun == 'alipayaps_cn'){
paymentLink = '/api/v1.0/share_code/bills/payment/orders/'+window.billInfo.bill_code_id+'/alipay_aps/share_link'
}else{
paymentLink = '/api/v1.0/share_code/bills/payment/'+window.billInfo.bill_code_id+'/alipay_aps/mobile/redirectApp?priorityChannel=AlipayAps';
}
}
if(paymentFun == 'Bank'){ if(paymentFun == 'Bank'){
paymentLink = '/api/v1.0/share_code/bills/payment/orders/'+window.billInfo.bill_code_id+'/cbbank/share_link?partner_moniker='+window.clientmoniker; paymentLink = '/api/v1.0/share_code/bills/payment/orders/'+window.billInfo.bill_code_id+'/cbbank/share_link?partner_moniker='+window.clientmoniker;
} }
@ -187,7 +236,11 @@ $(document).ready(function () {
function callPayment(paydata) { function callPayment(paydata) {
try { try {
if(typeof paydata.trade_no == 'undefined'){ if(typeof paydata.trade_no == 'undefined'){
if(paydata.mweb_url!=null){
window.location.href = paydata.mweb_url window.location.href = paydata.mweb_url
}else{
window.location.href = paydata.web_url
}
}else { }else {
AlipayJSBridge.call('tradePay', { AlipayJSBridge.call('tradePay', {
tradeNO: paydata.trade_no tradeNO: paydata.trade_no

@ -19,6 +19,9 @@ $(document).ready(function () {
}else if(window.clientInfo.enable_cb_bankpay){ }else if(window.clientInfo.enable_cb_bankpay){
var paymentFun = 'Bank'; var paymentFun = 'Bank';
showQRcode(); showQRcode();
}else if(window.clientInfo.enable_alipayaps){
var paymentFun = 'AlipayAps';
showQRcode();
} }
startCheckOrder(); startCheckOrder();
@ -43,6 +46,8 @@ $(document).ready(function () {
$("#select_wechat").removeClass("no-select-pay-fun").addClass("select-pay-fun"); $("#select_wechat").removeClass("no-select-pay-fun").addClass("select-pay-fun");
$("#select_alipay").removeClass("select-pay-fun").addClass("no-select-pay-fun"); $("#select_alipay").removeClass("select-pay-fun").addClass("no-select-pay-fun");
$("#select_bank").removeClass("select-pay-fun").addClass("no-select-pay-fun"); $("#select_bank").removeClass("select-pay-fun").addClass("no-select-pay-fun");
$("#select_alipay_aps").removeClass("select-pay-fun").addClass("no-select-pay-fun");
showQRcode(); showQRcode();
} }
}) })
@ -52,6 +57,18 @@ $(document).ready(function () {
$("#select_wechat").removeClass("select-pay-fun").addClass("no-select-pay-fun"); $("#select_wechat").removeClass("select-pay-fun").addClass("no-select-pay-fun");
$("#select_alipay").removeClass("no-select-pay-fun").addClass("select-pay-fun"); $("#select_alipay").removeClass("no-select-pay-fun").addClass("select-pay-fun");
$("#select_bank").removeClass("select-pay-fun").addClass("no-select-pay-fun"); $("#select_bank").removeClass("select-pay-fun").addClass("no-select-pay-fun");
$("#select_alipay_aps").removeClass("select-pay-fun").addClass("no-select-pay-fun");
showQRcode();
}
})
$("#select_alipay_aps").click(function(){
if(paymentFun != 'AlipayAps'){
paymentFun = 'AlipayAps'
$("#select_wechat").removeClass("select-pay-fun").addClass("no-select-pay-fun");
$("#select_alipay").removeClass("select-pay-fun").addClass("no-select-pay-fun");
$("#select_bank").removeClass("select-pay-fun").addClass("no-select-pay-fun");
$("#select_alipay_aps").removeClass("no-select-pay-fun").addClass("select-pay-fun");
showQRcode(); showQRcode();
} }
}) })
@ -61,6 +78,7 @@ $(document).ready(function () {
$("#select_wechat").removeClass("select-pay-fun").addClass("no-select-pay-fun"); $("#select_wechat").removeClass("select-pay-fun").addClass("no-select-pay-fun");
$("#select_alipay").removeClass("select-pay-fun").addClass("no-select-pay-fun"); $("#select_alipay").removeClass("select-pay-fun").addClass("no-select-pay-fun");
$("#select_bank").removeClass("no-select-pay-fun").addClass("select-pay-fun"); $("#select_bank").removeClass("no-select-pay-fun").addClass("select-pay-fun");
$("#select_alipay_aps").removeClass("select-pay-fun").addClass("no-select-pay-fun");
showQRcode(); showQRcode();
} }
}) })
@ -85,7 +103,15 @@ $(document).ready(function () {
"<p style='font-size: 20px;font-weight: 800'>请使用" + channelName + "客户端扫码支付</p>" + "<p style='font-size: 20px;font-weight: 800'>请使用" + channelName + "客户端扫码支付</p>" +
"<img src='" + window.alipayqrcode + "'>"; "<img src='" + window.alipayqrcode + "'>";
$('#qrImg').append(selectPaymentHTML) $('#qrImg').append(selectPaymentHTML)
} else if (paymentFun == 'Bank') { }
else if (paymentFun == 'AlipayAps') {
$('#qrImg').empty();
document.getElementById("qrImg").style.display = 'block';
var selectPaymentHTML =
"<p style='font-size: 20px;font-weight: 800'>请使用" + channelName + "客户端扫码支付</p>" +
"<img src='" + window.alipayapsqrcode + "'>";
$('#qrImg').append(selectPaymentHTML)
}else if (paymentFun == 'Bank') {
$('#qrImg').empty(); $('#qrImg').empty();
document.getElementById("qrImg").style.display = 'block'; document.getElementById("qrImg").style.display = 'block';
if( hasPayment){ if( hasPayment){

@ -59,6 +59,15 @@ body {
background-size: contain; background-size: contain;
} }
.result-alipayaps-logo {
width: 80px;
height: 80px;
margin: auto;
background-image: url(/static/images/alipay_aps_big.svg);
background-repeat: no-repeat;
background-size: contain;
}
.result-royalpay-logo { .result-royalpay-logo {
width: 70px; width: 70px;
height: 98px; height: 98px;

Loading…
Cancel
Save