修复微信授权bug
This commit is contained in:
parent
0957979d20
commit
b3bdfe373a
@ -12,8 +12,8 @@ let httpApiSix
|
||||
let wsApi
|
||||
|
||||
// 在打包之前请检查当前环境是否正确
|
||||
const env = 'dev'; // 开发
|
||||
// const env = 'prod'; // 生产
|
||||
// const env = 'dev'; // 开发
|
||||
const env = 'prod'; // 生产
|
||||
// const env = 'prew'; // 预上线
|
||||
|
||||
switch (env) {
|
||||
|
@ -206,7 +206,7 @@ class AuthWechat {
|
||||
} else {
|
||||
uni.setStorageSync('auth_token', res.data.result.key);
|
||||
return uni.navigateTo({
|
||||
url: '/pages/users/login/index'
|
||||
url: '/pages/users/login/login_copy'
|
||||
})
|
||||
}
|
||||
})
|
||||
|
@ -2,8 +2,8 @@
|
||||
"name" : "惠农生活",
|
||||
"appid" : "__UNI__3A527D1",
|
||||
"description" : "",
|
||||
"versionName" : "1.9.4",
|
||||
"versionCode" : 194,
|
||||
"versionName" : "1.9.5",
|
||||
"versionCode" : 195,
|
||||
"transformPx" : false,
|
||||
/* 5+App特有相关 */
|
||||
"app-plus" : {
|
||||
|
@ -26,6 +26,7 @@
|
||||
|
||||
},
|
||||
onLoad(option) {
|
||||
console.log(option);
|
||||
let that = this
|
||||
const {
|
||||
code,
|
||||
@ -33,12 +34,13 @@
|
||||
} = option;
|
||||
wechat.auth(code, state)
|
||||
.then(() => {
|
||||
// console.log(decodeURIComponent(decodeURIComponent(option.back_url)),'back_url')
|
||||
console.log('----', decodeURIComponent(decodeURIComponent(option.back_url)),'back_url')
|
||||
const href = decodeURIComponent(decodeURIComponent(option.back_url))
|
||||
location.replace(href)
|
||||
})
|
||||
.catch((err) => {
|
||||
location.replace("/");
|
||||
console.log('----', {...err})
|
||||
location.replace("/pages/users/login/login_copy");
|
||||
});
|
||||
}
|
||||
};
|
||||
|
@ -1,56 +1,58 @@
|
||||
<template>
|
||||
<view class="container" v-if="merchantInfo && !isEmpty">
|
||||
<view class="v-navbar">
|
||||
<u-navbar title="面对面收款" :safeAreaInsetTop="false" :fixed="false" :autoBack="true" bgColor="transparent"
|
||||
leftIconColor="#fff" :titleStyle="{color:'#fff',fontWeight:'bold',fontSize:'32rpx'}">
|
||||
</u-navbar>
|
||||
</view>
|
||||
|
||||
<view class="v-desc">
|
||||
<view>
|
||||
<view class="v-desc-main">付款给商家</view>
|
||||
<view class="v-desc-sub">{{merchantInfo.merchant.mer_name}}</view>
|
||||
</view>
|
||||
<u-image :showLoading="true" :src="merchantInfo.merchant.mer_avatar" width="182rpx" height="182rpx"
|
||||
:radius="10" />
|
||||
</view>
|
||||
|
||||
<!-- 付款金额 -->
|
||||
<view class="v-con">
|
||||
<view class="v-con-text">付款金额</view>
|
||||
<view class="v-con-input">
|
||||
<text style="color: #303133;font-size:46rpx;">¥</text>
|
||||
<u--input type="number" maxlength="5" fontSize="23" v-model="cartForm.total_amount" placeholder="请输入金额"
|
||||
border="none" placeholderStyle="color:#999;font-size:30rpx">
|
||||
</u--input>
|
||||
</view>
|
||||
|
||||
<view class="v-wrap" v-if="cartForm.total_amount">
|
||||
<view class="v-wrap-money">
|
||||
<text class="icon">¥</text>
|
||||
<text class="num">{{cartForm.total_amount}}</text>
|
||||
</view>
|
||||
<view class="v-wrap-desc">
|
||||
<view class="v-wrap-desc-main">实物提货券</view>
|
||||
<view class="v-wrap-desc-sub">即买即用</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="v-btn-wrap">
|
||||
<view class="v-btn" @click="submitOrder">提交订单</view>
|
||||
</view>
|
||||
<!-- 登陆 -->
|
||||
<authorize :isAuto="isAuto" :isShowAuth="isShowAuth" @authColse="authColse" @onLoadFun="onLoadFun"></authorize>
|
||||
</view>
|
||||
|
||||
<!-- 无商户信息提示 -->
|
||||
<view v-else class="empty">
|
||||
<image src="/static/images/no_thing.png"></image>
|
||||
<text>暂未登陆~</text>
|
||||
<!-- 登陆 -->
|
||||
<authorize :isAuto="isAuto" :isShowAuth="isShowAuth" @authColse="authColse" @onLoadFun="onLoadFun"></authorize>
|
||||
</view>
|
||||
<view>
|
||||
<view class="container" v-if="merchantInfo && !isEmpty">
|
||||
<view class="v-navbar">
|
||||
<u-navbar title="面对面收款" :safeAreaInsetTop="false" :fixed="false" :autoBack="true" bgColor="transparent"
|
||||
leftIconColor="#fff" :titleStyle="{color:'#fff',fontWeight:'bold',fontSize:'32rpx'}">
|
||||
</u-navbar>
|
||||
</view>
|
||||
|
||||
<view class="v-desc">
|
||||
<view>
|
||||
<view class="v-desc-main">付款给商家</view>
|
||||
<view class="v-desc-sub">{{merchantInfo.merchant.mer_name}}</view>
|
||||
</view>
|
||||
<u-image :showLoading="true" :src="merchantInfo.merchant.mer_avatar" width="182rpx" height="182rpx"
|
||||
:radius="10" />
|
||||
</view>
|
||||
|
||||
<!-- 付款金额 -->
|
||||
<view class="v-con">
|
||||
<view class="v-con-text">付款金额</view>
|
||||
<view class="v-con-input">
|
||||
<text style="color: #303133;font-size:46rpx;">¥</text>
|
||||
<u--input type="number" maxlength="5" fontSize="23" v-model="cartForm.total_amount" placeholder="请输入金额"
|
||||
border="none" placeholderStyle="color:#999;font-size:30rpx">
|
||||
</u--input>
|
||||
</view>
|
||||
|
||||
<view class="v-wrap" v-if="cartForm.total_amount">
|
||||
<view class="v-wrap-money">
|
||||
<text class="icon">¥</text>
|
||||
<text class="num">{{cartForm.total_amount}}</text>
|
||||
</view>
|
||||
<view class="v-wrap-desc">
|
||||
<view class="v-wrap-desc-main">实物提货券</view>
|
||||
<view class="v-wrap-desc-sub">即买即用</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="v-btn-wrap">
|
||||
<view class="v-btn" @click="submitOrder">提交订单</view>
|
||||
</view>
|
||||
<!-- 登陆 -->
|
||||
<authorize :isAuto="isAuto" :isShowAuth="isShowAuth" @authColse="authColse" @onLoadFun="onLoadFun"></authorize>
|
||||
</view>
|
||||
|
||||
<!-- 无商户信息提示 -->
|
||||
<view v-else class="empty">
|
||||
<image src="/static/images/no_thing.png"></image>
|
||||
<text>暂未登陆~</text>
|
||||
<!-- 登陆 -->
|
||||
<authorize :isAuto="isAuto" :isShowAuth="isShowAuth" @authColse="authColse" @onLoadFun="onLoadFun"></authorize>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
Loading…
x
Reference in New Issue
Block a user