From 7a15c4a2293db17e9ca7b2392724955a19ea59df Mon Sep 17 00:00:00 2001 From: Wik-T <812952667@qq.com> Date: Sat, 20 Nov 2021 16:46:33 +0800 Subject: [PATCH] =?UTF-8?q?1.=E6=96=B0=E5=A2=9E=E4=BC=98=E9=80=89=E5=95=86?= =?UTF-8?q?=E5=93=81=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- App.vue | 16 ++-- pages.json | 22 +++++ pages/tabBar/home/home.vue | 79 ++++++------------ .../brand-classification.vue | 82 +++++++++++++++++++ subPages/preferred-goods/preferred-goods.vue | 81 ++++++++++++++++++ uni.scss | 37 ++++++++- 6 files changed, 254 insertions(+), 63 deletions(-) create mode 100644 subPages/brand-classification/brand-classification.vue create mode 100644 subPages/preferred-goods/preferred-goods.vue diff --git a/App.vue b/App.vue index 47bd48d..7a477d6 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 : '', openId: '', diff --git a/pages.json b/pages.json index f39b609..c5afe7e 100644 --- a/pages.json +++ b/pages.json @@ -467,6 +467,28 @@ "subpackages": [{ "root": "subPages", "pages": [{ + "path": "brand-classification/brand-classification", + "style": { + "enablePullDownRefresh": false, + "navigationBarTitleText": "品牌分类", + "backgroundTextStyle": "light", + "navigationBarBackgroundColor": "#0083f5", + "backgroundColorTop": "#0083f5", + "navigationBarTextStyle": "white" + } + + },{ + "path": "preferred-goods/preferred-goods", + "style": { + "enablePullDownRefresh": false, + "navigationBarTitleText": "商品分类", + "backgroundTextStyle": "light", + "navigationBarBackgroundColor": "#0083f5", + "backgroundColorTop": "#0083f5", + "navigationBarTextStyle": "white" + } + + },{ "path": "lottery/lottery", "style": { "enablePullDownRefresh": false, diff --git a/pages/tabBar/home/home.vue b/pages/tabBar/home/home.vue index 61d777a..d5e26d8 100644 --- a/pages/tabBar/home/home.vue +++ b/pages/tabBar/home/home.vue @@ -17,15 +17,6 @@ - - - - - - - @@ -160,7 +151,7 @@ homeCateList: [], //切换状态 cpStuats: 1, - jumpType:'' + jumpType: '' }; }, @@ -230,7 +221,7 @@ fail: res => {} }) // #endif - if(JSON.stringify(options.id)){ + if (JSON.stringify(options.id)) { app.globalData.identificationCode = options.id; return; } @@ -312,18 +303,18 @@ * 跳转外链 */ jumpWeb() { - if(this.jumpType == 1){ + if (this.jumpType == 1) { if (this.webUrl) { uni.navigateTo({ url: '../order/webUrl/webUrl?url=' + this.webUrl }) } - }else{ + } else { uni.navigateTo({ url: this.webUrl }) } - + this.closePopup(); }, /** @@ -605,61 +596,34 @@ //跳转菜单 toCategory(item) { + if (!app.globalData.userInfo.phone) { + uni.navigateTo({ + url: '../../userLogin/userLogin' + }) + return; + } + if (!app.globalData.userInfo) { + uni.navigateTo({ + url: '../../userLogin/userLogin' + }) + return; + } if (item.title == '在线加油') { uni.navigateTo({ url: item.ext1 }) } else if (item.title == '肯德基') { - if (!app.globalData.userInfo) { - uni.navigateTo({ - url: '../../userLogin/userLogin' - }) - return; - } - if (!app.globalData.userInfo.phone) { - uni.navigateTo({ - url: '../../userLogin/userLogin' - }) - return; - } uni.navigateTo({ url: '/pages/tabBar/order/order?id=1' }) } else if (item.title == '电影票') { - if (!app.globalData.userInfo) { - uni.navigateTo({ - url: '../../userLogin/userLogin' - }) - return; - } - if (!app.globalData.userInfo.phone) { - uni.navigateTo({ - url: '../../userLogin/userLogin' - }) - return; - } uni.navigateTo({ url: '/pages/tabBar/order/order?id=2' }) } else if (item.title == '话费充值') { - if (!app.globalData.userInfo) { - uni.navigateTo({ - url: '../../userLogin/userLogin' - }) - return; - } - if (!app.globalData.userInfo.phone) { - uni.navigateTo({ - url: '../../userLogin/userLogin' - }) - return; - } uni.navigateTo({ url: '../../../subPages/recharge/recharge' }) - // uni.navigateTo({ - // url:'../../../subPages/unionPay/unionPay' - // }) } else { uni.showToast({ title: '暂未开通', @@ -711,7 +675,8 @@ } if (item.title == '电影票') { uni.navigateTo({ - url: '/pages/tabBar/order/order?id=2' + // url: '/pages/tabBar/order/order?id=2' + url: '../../../subPages/preferred-goods/preferred-goods' }) return; } @@ -721,6 +686,12 @@ }) return; } + if (item.title == '优选商品') { + uni.navigateTo({ + url: '../../../subPages/preferred-goods/preferred-goods' + }) + return; + } }, diff --git a/subPages/brand-classification/brand-classification.vue b/subPages/brand-classification/brand-classification.vue new file mode 100644 index 0000000..ece82f2 --- /dev/null +++ b/subPages/brand-classification/brand-classification.vue @@ -0,0 +1,82 @@ + + + + + diff --git a/subPages/preferred-goods/preferred-goods.vue b/subPages/preferred-goods/preferred-goods.vue new file mode 100644 index 0000000..02592a3 --- /dev/null +++ b/subPages/preferred-goods/preferred-goods.vue @@ -0,0 +1,81 @@ + + + + + diff --git a/uni.scss b/uni.scss index cda240b..b3e09b1 100644 --- a/uni.scss +++ b/uni.scss @@ -655,4 +655,39 @@ $uni-font-size-paragraph:30upx; .font12{ font-size: 12px; -} \ No newline at end of file +} + + +.aliitem{ + align-items: center; + display: flex; +} + +.alijun{ + justify-content: flex-end; + display: flex; +} + +.alijusstart{ + justify-content: flex-start; + align-items: center; + display: flex; +} + +.alijusend{ + justify-content: flex-end; + align-items: center; + display: flex; +} + +.alicntend{ + justify-content: end; + align-items: center; + display: flex; +} + +.alijus{ + justify-content: center; + align-items: center; + display: flex; +}