From fc75cc723ff473fe4a5972d68f54b6a60d4ce60e Mon Sep 17 00:00:00 2001
From: weipengfei <2187978347@qq.com>
Date: Thu, 21 Mar 2024 10:11:41 +0800
Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
components/Authorize.vue | 26 ++++++++++++++++++--------
libs/login.js | 2 +-
main.js | 4 +++-
manifest.json | 4 ++--
pages/goods_details/index.vue | 5 ++++-
pages/order_addcart/order_addcart.vue | 7 +++++--
6 files changed, 33 insertions(+), 15 deletions(-)
diff --git a/components/Authorize.vue b/components/Authorize.vue
index cfb0ef7..352f3b6 100644
--- a/components/Authorize.vue
+++ b/components/Authorize.vue
@@ -6,7 +6,7 @@
-->
- 授权提醒
+ {{isPay?'付款提醒':'授权提醒'}}
{{title}}
@@ -16,7 +16,7 @@
{{title}}
- 请授权头像等信息,以便为您提供更好的服务!
+ {{ isPay ? payInfo : '请授权头像等信息,以便为您提供更好的服务!'}}
{{info}}
@@ -26,7 +26,8 @@
{{info}}
- 随便逛逛
+ 取消
+ 随便逛逛
@@ -38,7 +39,7 @@
@@ -89,7 +90,11 @@
isShowAuth: {
type: Boolean,
default: false
- }
+ },
+ isPay:{
+ type: Boolean,
+ default: false
+ },
},
components: {
// #ifdef MP
@@ -102,11 +107,13 @@
info: '请登录,将为您提供更好的服务!',
//#ifdef H5
isWeixin: this.$wechat.isWeixin(),
+ // isWeixin: false, // 关闭微信公众号授权登录
//#endif
//#ifdef MP
title: '授权提醒',
info: '请授权头像等信息,以便为您提供更好的服务!',
//#endif
+ payInfo: '',
canUseGetUserProfile: false,
code: null,
top: 0,
@@ -145,6 +152,9 @@
this.editModal = false
},
// #endif
+ setPayInfo(e){
+ this.payInfo = e;
+ },
setAuthStatus() {
//#ifdef MP
Routine.authorize().then(res => {
@@ -192,7 +202,7 @@
url: '/pages/users/login/login_copy'
})
// console.log(22);
- return
+ return;
let self = this;
Routine.getUserProfile()
.then(res => {
@@ -232,7 +242,6 @@
title: res.message,
icon: 'none',
duration: 2000,
-
});
});
})
@@ -316,6 +325,7 @@
}
.Popup .bottom .item {
+ flex: 1;
width: 250rpx;
height: 80rpx;
background-color: #eeeeee;
@@ -342,7 +352,7 @@
.Popup .bottom .item.grant {
font-weight: bold;
- background-color: #E93323;
+ background-color: #40ae36;
/* background-color: var(--view-theme); */
border-radius: 0;
padding: 0;
diff --git a/libs/login.js b/libs/login.js
index 7de70ab..d1dc270 100644
--- a/libs/login.js
+++ b/libs/login.js
@@ -48,7 +48,7 @@ export function toLogin(push, pathLogin) {
// #endif
if (!pathLogin)
pathLogin = '/page/users/login/login_copy'
- Cache.set('login_back_url', path);
+ Cache.set('login_back_url', path);
// #ifdef H5
if (isWeixin()) {
if (Cache.get('WECHAT_APPID')) {
diff --git a/main.js b/main.js
index 75c75f9..8f8bb03 100644
--- a/main.js
+++ b/main.js
@@ -19,12 +19,14 @@ import skeleton from './components/skeleton/index.vue'
import BaseMoney from './components/BaseMoney.vue';
import loadmore from './components/loadmore';
import Loading from './components/Loading.vue';
-import barcode from "@/components/barcode.vue"
+import barcode from "@/components/barcode.vue";
+import Authorize from "@/components/Authorize.vue";
Vue.component('skeleton', skeleton)
Vue.component('BaseMoney', BaseMoney)
Vue.component('loadmore', loadmore)
Vue.component('Loading', Loading)
Vue.component('barcode', barcode)
+Vue.component('Authorize', Authorize)
Vue.prototype.$util = util;
Vue.prototype.$Cache = Cache;
Vue.prototype.$eventHub = new Vue();
diff --git a/manifest.json b/manifest.json
index 9c647ac..838bca6 100644
--- a/manifest.json
+++ b/manifest.json
@@ -2,8 +2,8 @@
"name" : "惠农生活",
"appid" : "__UNI__3A527D1",
"description" : "",
- "versionName" : "2.0.02",
- "versionCode" : 2002,
+ "versionName" : "2.0.03",
+ "versionCode" : 2003,
"transformPx" : false,
/* 5+App特有相关 */
"app-plus" : {
diff --git a/pages/goods_details/index.vue b/pages/goods_details/index.vue
index 37c59bf..0a425df 100644
--- a/pages/goods_details/index.vue
+++ b/pages/goods_details/index.vue
@@ -416,6 +416,7 @@
+
@@ -590,6 +591,7 @@
currentPage: false,
homeTop: 59,
sale_type: 1, //1-普通商品, 2-批发商品
+ isShowAuth: false,
selectNavList: [{
name: '首页',
icon: 'icon-shouye8',
@@ -1473,7 +1475,8 @@
*/
goBuy: function(e) {
if (this.isLogin === false) {
- toLogin()
+ // toLogin()
+ this.isShowAuth = true;
} else {
this.goCat(true);
}
diff --git a/pages/order_addcart/order_addcart.vue b/pages/order_addcart/order_addcart.vue
index 8e31737..8a539dd 100644
--- a/pages/order_addcart/order_addcart.vue
+++ b/pages/order_addcart/order_addcart.vue
@@ -171,6 +171,7 @@
+
@@ -293,7 +294,8 @@
userInfo: {},
mer_info: {
mer_settlement_agree_status: 0
- }
+ },
+ isShowAuth: false
};
},
computed: configMap({
@@ -334,7 +336,8 @@
})
} else {
setTimeout(() => {
- toLogin()
+ // toLogin()
+ this.isShowAuth = true;
}, 300);
}
},