From 0dd3867064d8d308c71cb2c924ae1cdf239d6143 Mon Sep 17 00:00:00 2001 From: Wik-T <812952667@qq.com> Date: Wed, 21 Sep 2022 11:01:08 +0800 Subject: [PATCH] =?UTF-8?q?1.=E6=96=B0=E5=A2=9E=E4=BC=98=E6=83=A0=E5=88=B8?= =?UTF-8?q?=E5=8C=85=E8=82=AF=E5=BE=B7=E5=9F=BA=EF=BC=8C=E6=98=9F=E5=B7=B4?= =?UTF-8?q?=E5=85=8B=EF=BC=8C=E4=BC=9A=E5=91=98=E5=85=85=E5=80=BC=E8=B7=B3?= =?UTF-8?q?=E8=BD=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- App.vue | 206 ++++++++++-------- pages/tabBar/home/home.vue | 8 + pages/user/coupon/coupon.vue | 16 +- .../coupon-packge-details.vue | 2 +- 4 files changed, 137 insertions(+), 95 deletions(-) diff --git a/App.vue b/App.vue index 750f205..910d5d8 100644 --- a/App.vue +++ b/App.vue @@ -5,15 +5,15 @@ // brestUrl: 'http://192.168.3.4:9302/brest', // imgUrl: 'https://192.168.3.4:9301/filesystem/', //正式 - // url: 'https://hsg.dctpay.com/crest', - // imgUrl: 'https://hsg.dctpay.com/filesystem/', - // brestUrl: 'https://hsg.dctpay.com/brest', - // imageWxImg: 'https://hsg.dctpay.com/filesystem/wxApplets/', + url: 'https://hsg.dctpay.com/crest', + imgUrl: 'https://hsg.dctpay.com/filesystem/', + brestUrl: 'https://hsg.dctpay.com/brest', + imageWxImg: 'https://hsg.dctpay.com/filesystem/wxApplets/', //测试 - url: 'https://hsgcs.dctpay.com/crest', - brestUrl: 'https://hsgcs.dctpay.com/brest', - imgUrl: 'https://hsgcs.dctpay.com/filesystem/', - imageWxImg: 'https://hsgcs.dctpay.com/filesystem/wxApplets/', + // url: 'https://hsgcs.dctpay.com/crest', + // brestUrl: 'https://hsgcs.dctpay.com/brest', + // imgUrl: 'https://hsgcs.dctpay.com/filesystem/', + // imageWxImg: 'https://hsgcs.dctpay.com/filesystem/wxApplets/', userInfo: "", brestUserInfo: '', bresthighAgent: '', @@ -27,9 +27,9 @@ latitude: '', balancePrice: '', balanceCardNo: '', - identificationCode: '', - //公司id - companyId:'', + identificationCode: '', + //公司id + companyId: '', // h5获取信息 h5code: '', //门店ID @@ -58,103 +58,123 @@ pelletoilList: '' }, - onLaunch: function() { - }, - onShow: function() { + onLaunch: function() {}, + onShow: function() { + // #ifdef H5 let that = this; - uni.getStorage({ - key: 'openId', - success(e) { - if (e.data) { - that.globalData.openId = e.data; - } - } - }) - uni.getStorage({ - key: 'user', - success(e) { - if (e.data) { - that.globalData.userInfo = e.data; - } - } - }) - - uni.getStorage({ - key: 'token', - success(e) { - if (e.data) { - that.globalData.token = e.data; - } - } - }) - - - - uni.getStorage({ - key: 'accountId', - success(e) { - if (e.data) { - that.globalData.accountId = e.data; - that.globalData.accountType = e.data; - } - } - }) - uni.getStorage({ - key: 'gasKey', - success(e) { - if (e.data) { - that.globalData.gasKey = e.data; - } - } - }) - uni.getStorage({ - key: 'staffCode', - success(e) { - if (e.data) { - if (that.globalData.accountId == '000001&key' || that.globalData.accountId == - '000000&gasKey' || that.globalData.accountId == '000009&key' || that.globalData.accountId == '0000010&key') { - that.globalData.staffCode = e.data; - } else { - that.globalData.mchId = e.data; - } - } - } - }) - - uni.getStorage({ - key: 'cityId', - success(e) { - if (e.data) { - that.globalData.cityId = e.data; - } - } + uni.getStorage({ + key: 'openId', + success(e) { + if (e.data) { + that.globalData.openId = e.data; + } + } + }) + uni.getStorage({ + key: 'user', + success(e) { + if (e.data) { + that.globalData.userInfo = e.data; + } + } + }) + + uni.getStorage({ + key: 'token', + success(e) { + if (e.data) { + that.globalData.token = e.data; + } + } + }) + + + + uni.getStorage({ + key: 'accountId', + success(e) { + if (e.data) { + that.globalData.accountId = e.data; + that.globalData.accountType = e.data; + } + } + }) + uni.getStorage({ + key: 'gasKey', + success(e) { + if (e.data) { + that.globalData.gasKey = e.data; + } + } + }) + uni.getStorage({ + key: 'staffCode', + success(e) { + if (e.data) { + if (that.globalData.accountId == '000001&key' || that.globalData.accountId == + '000000&gasKey' || that.globalData.accountId == '000009&key' || that.globalData + .accountId == '0000010&key') { + that.globalData.staffCode = e.data; + } else { + that.globalData.mchId = e.data; + } + } + } + }) + + uni.getStorage({ + key: 'cityId', + success(e) { + if (e.data) { + that.globalData.cityId = e.data; + } + } }) uni.getStorage({ - key: 'companyId', + key: 'cityName', success(e) { if (e.data) { - that.globalData.companyId = e.data; + that.globalData.cityName = e.data; } } }) uni.getStorage({ - key: 'latitude', + key: 'qianzhuCityName', success(e) { if (e.data) { - that.globalData.latitude = e.data; + that.globalData.qianzhuCityName = e.data; } } - }) - uni.getStorage({ - key: 'longitude', - success(e) { - if (e.data) { - that.globalData.longitude = e.data; - } - } - }) + }) + + uni.getStorage({ + key: 'companyId', + success(e) { + if (e.data) { + that.globalData.companyId = e.data; + } + } + }) + + uni.getStorage({ + key: 'latitude', + success(e) { + if (e.data) { + that.globalData.latitude = e.data; + } + } + }) + uni.getStorage({ + key: 'longitude', + success(e) { + if (e.data) { + that.globalData.longitude = e.data; + } + } + }) + // #endif }, onHide: function() {} } diff --git a/pages/tabBar/home/home.vue b/pages/tabBar/home/home.vue index 3ca70d3..45c13c4 100644 --- a/pages/tabBar/home/home.vue +++ b/pages/tabBar/home/home.vue @@ -502,6 +502,14 @@ uni.setStorage({ key: "cityId", data: res.return_data.regionId + }) + uni.setStorage({ + key: "cityName", + data: res.return_data.provinceName + }) + uni.setStorage({ + key: "qianzhuCityName", + data: res.return_data.cityName }) uni.setStorage({ key: "companyId", diff --git a/pages/user/coupon/coupon.vue b/pages/user/coupon/coupon.vue index bbc1e71..243309a 100644 --- a/pages/user/coupon/coupon.vue +++ b/pages/user/coupon/coupon.vue @@ -248,7 +248,21 @@ uni.navigateTo({ url: '../../../subPages/recharge/recharge' }) - } else { + } else if (e.highDiscount.useScope == 4) { + app.globalData.distinguishid = 1; + uni.navigateTo({ + url: '/qianzhu-KFC/buffet-order/buffet-order' + }) + } else if (e.highDiscount.useScope == 5) { + app.globalData.distinguishid = 2; + uni.navigateTo({ + url: '/qianzhu-KFC/buffet-order/buffet-order' + }) + } else if (e.highDiscount.useScope == 6) { + uni.navigateTo({ + url: '/member-Recharge/choicepage/choicepage' + }) + } else{ uni.navigateTo({ url: '../mineCouponsDestails/mineCouponsDestails?id=' + e.id }) diff --git a/subPages/coupon-packge-details/coupon-packge-details.vue b/subPages/coupon-packge-details/coupon-packge-details.vue index f1f9991..7006c03 100644 --- a/subPages/coupon-packge-details/coupon-packge-details.vue +++ b/subPages/coupon-packge-details/coupon-packge-details.vue @@ -66,7 +66,7 @@ 优惠券包 - + {{ product.discountDetail.discountName}} 数量: x{{product.num}}