From 7dc1536bca1fadc837028c65720e54872691a626 Mon Sep 17 00:00:00 2001 From: meo <18801474720@163.com> Date: Thu, 26 Sep 2019 16:07:37 +0800 Subject: [PATCH] =?UTF-8?q?[=E8=90=A5=E9=94=80=E7=89=A9=E6=96=99][?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0]:[=E5=A2=9E=E5=8A=A0=E8=90=A5=E9=94=80?= =?UTF-8?q?=E7=89=A9=E6=96=99=E7=9A=84=E8=B7=AF=E5=BE=84]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/index/index.js | 33 +++++++++++++++++++++++---------- 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/pages/index/index.js b/pages/index/index.js index b55d8da..fe1f296 100644 --- a/pages/index/index.js +++ b/pages/index/index.js @@ -131,11 +131,11 @@ Page({ checkuserstatus(options) { let that = this; Http.get({ - url: config.api.checkUserStatus, - data: { - token:app.globalData.token - } - }) + url: config.api.checkUserStatus, + data: { + token: app.globalData.token + } + }) .then(res => { //参与拼团 if (options && options.orderGroupId) { @@ -160,7 +160,7 @@ Page({ }) }) } else if (options && options.couponChannelId && !options.spellGroup && app.globalData.type != 'sd') { - + // 转赠判断 if (options.cuserId) { wx.redirectTo({ @@ -174,7 +174,7 @@ Page({ } } // 拼团详情页(只有通过扫码进入才可能进入拼团详情页面,只有这一个入口) - else if ((options && options.couponChannelId && app.globalData.type == 'sd') || (options && options.couponChannelId && options.spellGroup) ){ + else if ((options && options.couponChannelId && app.globalData.type == 'sd') || (options && options.couponChannelId && options.spellGroup)) { wx.redirectTo({ url: `/pages/spellGroup/mySpellGroup/index?couponChannelId=${options.couponChannelId}`, }) @@ -214,7 +214,7 @@ Page({ wx.redirectTo({ url: `/pages/topicDetail/index?id=${options.id}` }); - } + } // 门店详情 else if (options && options.id && app.globalData.type == 'md') { wx.redirectTo({ @@ -310,6 +310,7 @@ Page({ } // 我的拼团 else if (app.globalData.type == 'ms') { + // 我的拼团 wx.redirectTo({ url: '/pages/spellGroup/spellGroup?from=myhtml' }) @@ -326,13 +327,19 @@ Page({ wx.switchTab({ url: '/index/searchbar' }) - } + } + // 兑换 + else if (app.globalData.type == 'ec') { + wx.redirectTo({ + url: '/pages/exchange/exchange' + }) + } // 通过分享进入的门店详情 else if (options && options.id && options.frommd == 'md') { wx.redirectTo({ url: `/pages/index/searchbar/detail/index?id=${options.id}` }); - }else { + } else { // 主页 wx.switchTab({ url: '/index/index' @@ -476,6 +483,12 @@ Page({ url: '/pages/discountCardList/discountCardList' }) } + // 兑换 + else if (app.globalData.type == 'ec') { + wx.redirectTo({ + url: '/pages/exchange/exchange' + }) + } // 门店 else if (app.globalData.type == 'ml') { wx.switchTab({