From 2ead27f329300df4943da2c29e5b5c3b07cf5dc7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9B=B9=E8=BE=89?= <814457906@qq.com> Date: Mon, 20 Mar 2023 09:49:10 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/integral/integral.vue | 12 +++++++----- pages/startup/startup.vue | 6 +++--- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/pages/integral/integral.vue b/pages/integral/integral.vue index 18d2c56..09e703e 100644 --- a/pages/integral/integral.vue +++ b/pages/integral/integral.vue @@ -24,7 +24,7 @@ 积分兑换 - + @@ -43,7 +43,7 @@ - + @@ -226,7 +226,7 @@ pageNum: 1, pageSize: 10, goodstotal: 0, - goodslist: [], + goodslist: null, goodsitem: null, userid: null, updata: { @@ -542,8 +542,10 @@ e.goodsPictureUrl = baseurl + e.goodsPictureUrl e.attributePitureUrl = baseurl + e.attributePitureUrl }) - this.goodslist = res.rows - this.goodstotal = res.total + if (res.rows.length > 0) { + this.goodslist = res.rows + this.goodstotal = res.total + } } else if (res.code == 9999) { this.$refs.uToast.show({ title: '未登录,请先登录', diff --git a/pages/startup/startup.vue b/pages/startup/startup.vue index 2030f92..1593810 100644 --- a/pages/startup/startup.vue +++ b/pages/startup/startup.vue @@ -42,9 +42,9 @@ }, onShow() { var that = this - // createMobileToken().then(res => { - // uni.setStorageSync("token", res.data.token) - // }) + createMobileToken().then(res => { + uni.setStorageSync("token", res.data.token) + }) setTimeout(() => { uni.reLaunch({ url: '/pages/homepage/homepage'