From ea04d1a3d0d36f0b13006ba01ad156dc5193e969 Mon Sep 17 00:00:00 2001 From: Ge Hao Date: Fri, 9 Dec 2016 18:13:40 +0800 Subject: [PATCH] =?UTF-8?q?ios=E4=B8=8A=E8=AE=BE=E4=B8=BAnull=E4=B8=8D?= =?UTF-8?q?=E8=83=BD=E7=9B=B4=E6=8E=A5=E6=94=B9=E5=8F=98=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E7=9A=84=E7=8A=B6=E6=80=81=EF=BC=88=E9=A1=B5=E9=9D=A2=E4=B8=AD?= =?UTF-8?q?=E7=9A=84{{}}=E8=A7=A3=E6=9E=90=E6=98=AF=E6=9C=89=E9=97=AE?= =?UTF-8?q?=E9=A2=98=E7=9A=84=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app.js | 1 + pages/cart/cart.js | 6 +++--- pages/mine/mine.js | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/app.js b/app.js index 7fa34bb..4da0bd4 100644 --- a/app.js +++ b/app.js @@ -60,6 +60,7 @@ App({ if (!that.globalData.token) { var token = wx.getStorageSync('userToken') if (!token) { + wx.hideToast() wx.showModal({ title: '未登录', content: '请前往 “我的” 页面绑定手机号', diff --git a/pages/cart/cart.js b/pages/cart/cart.js index 1bbc572..5430007 100644 --- a/pages/cart/cart.js +++ b/pages/cart/cart.js @@ -107,7 +107,7 @@ Page({ wx.showToast({ title: '购买中...', icon: 'loading', - duration: 10000 + duration: 5000 }) var that = this @@ -163,7 +163,7 @@ Page({ if (parseInt(result.statusCode) === 403) { wx.hideToast() if (parseInt(result.data.code) === 4001) { - that.setData({coupon: null}) + that.setData({coupon: ''}) } wx.showModal({ title: '出错', @@ -187,7 +187,7 @@ Page({ if (res.confirm) { that.setData({ cartItems: [], - coupon: null + coupon: '' }) that.changeCartAmount() } diff --git a/pages/mine/mine.js b/pages/mine/mine.js index bec4f5a..afb5843 100644 --- a/pages/mine/mine.js +++ b/pages/mine/mine.js @@ -110,7 +110,7 @@ Page({ }) that.setData({ needBindMobile: true, - baye_rank: null + baye_rank: '' }) } },