💊 fix: 修复支付宝跳转路径bug

This commit is contained in:
wangsongsole 2023-06-20 18:01:42 +08:00
parent fc514ac1ca
commit 5e4a16a691
1 changed files with 6 additions and 3 deletions

View File

@ -10,9 +10,10 @@
charset="utf-8"></script> charset="utf-8"></script>
<script type="text/javascript" src="https://lsxdemall.oss-cn-beijing.aliyuncs.com/common/axios.js?v=1367936144322"> <script type="text/javascript" src="https://lsxdemall.oss-cn-beijing.aliyuncs.com/common/axios.js?v=1367936144322">
</script> </script>
<script src="./api2_0.js"></script> <script src="https://lsxdemall.oss-cn-beijing.aliyuncs.com/MarketingSystem/js/api2_0.js"></script>
<link rel="stylesheet" href="./redPackets.css" /> <link rel="stylesheet" href="./redPackets.css" />
<script src="https://lsxdemall.oss-cn-beijing.aliyuncs.com/common/modelPop.js"></script> <script src="https://lsxdemall.oss-cn-beijing.aliyuncs.com/common/modelPop.js"></script>
<link rel="stylesheet" href="./a.scss">
<style> <style>
* { * {
margin: 0 auto; margin: 0 auto;
@ -114,15 +115,17 @@
if (code == 200) { if (code == 200) {
this.judgeEnvironment(data.order_number); this.judgeEnvironment(data.order_number);
} else { } else {
this.tip(message, 2, '关闭');
if (code == 403) { if (code == 403) {
if (this.backAble) { if (this.backAble) {
this.tip(message, 2, '关闭');
setTimeout(() => { setTimeout(() => {
window.location.href = localStorage.getItem('entryLink'); window.location.href = localStorage.getItem('entryLink');
}, 3000); }, 3000);
} else { } else {
this.tip(message, 2, '关闭'); this.tip(message, 2, '关闭');
} }
} else {
this.tip(message, 2, '关闭');
} }
} }
}) })
@ -132,7 +135,7 @@
/* 根据环境进行下一步操作 1 支付宝 2 微信 */ /* 根据环境进行下一步操作 1 支付宝 2 微信 */
judgeEnvironment (order_number, weiXinUrl) { judgeEnvironment (order_number, weiXinUrl) {
if (this.goodsInfo.entity.channel === 1) { if (this.goodsInfo.entity.channel === 1) {
const aliPaysUrl = `alipays://platformapi/startapp?appId=2021004100663111&page=pages/index/index?order_number=${order_number}`; const aliPaysUrl = `alipays://platformapi/startapp?appId=2021004100663111&page=pages/index/index?order_number=${encodeURIComponent(order_number)}`;
if ((isWx())) { if ((isWx())) {
this.tip('请点击下方[复制]按钮,复制链接到浏览器打开!', 1, '点击复制'); this.tip('请点击下方[复制]按钮,复制链接到浏览器打开!', 1, '点击复制');
this.copyLink = aliPaysUrl; this.copyLink = aliPaysUrl;