隐藏微信入口

This commit is contained in:
Dragon
2023-07-27 11:58:00 +08:00
parent bcf1c3bc11
commit 3af53c876e
4 changed files with 40 additions and 33 deletions

View File

@@ -9,7 +9,7 @@ body {
position: fixed; position: fixed;
left: 0; left: 0;
top: 0; top: 0;
background: #fff; background: rgba(0, 0, 0, 0.5);
width: 100%; width: 100%;
height: 100%; height: 100%;
z-index: 999; z-index: 999;
@@ -17,14 +17,15 @@ body {
} }
.tips-tit p { .tips-tit p {
position: absolute; position: absolute;
width: 100%; right: 0.2666666667rem;
text-align: center; top: 0.1333333333rem;
width: 50%;
background: #FFF;
color: #333; color: #333;
top: 50%; border-radius: 0.2133333333rem;
left: 0; line-height: 0.5333333333rem;
transform: translateY(-50%); padding: 0.2666666667rem;
font-size: 0.4266666667rem; font-size: 0.4266666667rem;
font-weight: bold;
} }
.max { .max {

View File

@@ -15,7 +15,7 @@ body {
position: fixed; position: fixed;
left: 0; left: 0;
top: 0; top: 0;
background: #fff; background: rgba(0, 0, 0, .5);
width: 100%; width: 100%;
height: 100%; height: 100%;
z-index: 999; z-index: 999;
@@ -23,23 +23,23 @@ body {
p { p {
position: absolute; position: absolute;
width: 100%; // width: 100%;
text-align: center; // text-align: center;
color: #333;
top: 50%;
left: 0;
transform: translateY(-50%);
font-size: px2rem(32, );
font-weight: bold;
// right: px2rem(20);
// top: px2rem(10);
// width: 50%;
// background: #FFF;
// color: #333; // color: #333;
// border-radius: px2rem(16); // top: 50%;
// line-height: px2rem(40); // left: 0;
// padding: px2rem(20); // transform: translateY(-50%);
// font-size: px2rem(32); // font-size: px2rem(32, );
// font-weight: bold;
right: px2rem(20);
top: px2rem(10);
width: 50%;
background: #FFF;
color: #333;
border-radius: px2rem(16);
line-height: px2rem(40);
padding: px2rem(20);
font-size: px2rem(32);
} }
} }
@@ -694,6 +694,7 @@ body {
.type { .type {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
// justify-content: center;
div { div {
width: px2rem(330); width: px2rem(330);

View File

@@ -23,8 +23,8 @@
<body> <body>
<div id="pay"></div> <div id="pay"></div>
<div class="tips-tit"> <div class="tips-tit">
<!-- <p>点击右上角选择“在浏览器打开”或者“在Safari中打开”即可开始下一步</p> --> <p>点击右上角选择“在浏览器打开”或者“在Safari中打开”即可开始下一步</p>
<p>暂不支持</p> <!-- <p>暂不支持</p> -->
</div> </div>
<div class="max"> <div class="max">
<div class="logo"> <div class="logo">
@@ -41,11 +41,11 @@
<div class="pay-type"> <div class="pay-type">
<span class='way'>支付方式</span> <span class='way'>支付方式</span>
<div class="type"> <div class="type">
<div class="wxpay active"> <!-- <div class="wxpay active">
<img src="./images/wx.png" alt=""> <img src="./images/wx.png" alt="">
<span class="aw">微信支付</span> <span class="aw">微信支付</span>
</div> </div> -->
<div class="alipay"> <div class="alipay active">
<img src="./images/ali.png" alt=""> <img src="./images/ali.png" alt="">
<span class="aw">支付宝支付</span> <span class="aw">支付宝支付</span>
<span class="tip">高额度</span> <span class="tip">高额度</span>

View File

@@ -42,7 +42,8 @@ function mess (str) {
} }
//payType = "wx_wap" =>微信支付参数 : payType = "alipay_wap" =>支付宝支付参数 //payType = "wx_wap" =>微信支付参数 : payType = "alipay_wap" =>支付宝支付参数
//defaultPayH5 => 决定H5支付页面的payType由后台配置 //defaultPayH5 => 决定H5支付页面的payType由后台配置
let payType = "wx_wap" //默认微信选中 // let payType = "wx_wap" //默认微信选中
let payType = "alipay_wap" //默认支付宝选中
let cerruntIndex = 0 //选中的支付方式的索引 let cerruntIndex = 0 //选中的支付方式的索引
let defaultPayH5 //不再由其配置,貌似已经没用了 let defaultPayH5 //不再由其配置,貌似已经没用了
let chargeList = [] //微信充值列表 let chargeList = [] //微信充值列表
@@ -312,9 +313,13 @@ const payInOutter = (packages) => {
num.val(''); num.val('');
$pop.hide(); $pop.hide();
$('#confirm').unbind('click') $('#confirm').unbind('click')
$('#pay').html(packages.payInfo); if (payType == "wx_wap") {
document.forms['alipaysubmit'].submit(); // window.location.href = packages.payInfo.mweb_url
// window.location.href = packages.payInfo.mweb_url } else {
$('#pay').html(packages.payInfo);
document.forms['alipaysubmit'].submit();
}
}) })
} }