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 4bc642f..35ea94e 100644 --- a/pages/tabBar/home/home.vue +++ b/pages/tabBar/home/home.vue @@ -545,6 +545,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}}