From e4774204ba55d4d1403540484d204d28384f8ac8 Mon Sep 17 00:00:00 2001 From: fanp Date: Wed, 30 Oct 2019 09:31:24 +0800 Subject: [PATCH] update topic --- images/topic/avatar.png | Bin 0 -> 2118 bytes pages/topics/index.js | 25 ++++++++++++++---- .../topics/interactive/submitTopic/index.wxss | 2 ++ pages/topics/message/index.wxss | 4 ++- pages/user/myFavorite/index.wxml | 2 +- 5 files changed, 26 insertions(+), 7 deletions(-) create mode 100644 images/topic/avatar.png diff --git a/images/topic/avatar.png b/images/topic/avatar.png new file mode 100644 index 0000000000000000000000000000000000000000..ad25d8428cdcce7a20688adcc02f9f4e49faf431 GIT binary patch literal 2118 zcmV-M2)Xx(P)LJdTNfJ(}1VILsNE_?UEKJM+DJ6;P2yZ7$0$#kaY zABNrE@BGf^p2zQZ&ud$${tSTD30nLCyZ~T-dBxX)Rz7{=n0W+FhZ9D<4kIQ#yj~9t`7MB_f?dQPz;gh8 z{>1lx6s+!9=hFyLg0bsq-obcy?umkvfKJ@qXiad?AXW()=P6GIn z5-<1z*azS@+aLcfG;#4tbSfHaG#cQr+i|n=3UqxR)7%6lx!@0A34q@G`-@Sqmhvk+ zVm6y$88c&SbOdcJ?<)=?e*jWqJx--GEh9551Qv@0=FwZA65G}+0z3iWHMxrg0?;xH z(;x^!9(f{fO(CM9qUGwAHIDWLgJEd02Q~w!ku@1WAOO;%yl8kQ;)HUM$+ zYP*Vx?>&u(dGnB*k_N+2|D2c6umX_s4?C}8|G`&qrR#>Y7M)D#gepsvB=MZ)fTYar z_F&9v!`b>qR2_Wzf6oIFz~%N1?D^?0{tqB0?!;4SsAY6|2u|0-{z=3^qEDB9bBW6*-wtZFT9n^QaJ)T@88iN5K{U!{Xteq zLOWd(7`NGR;zAvsefbdCLD@^iL9qlILefHO7>21=$Hc_G^0O+{#s@zi&;Y6K|KaU- zaOl`^#6(6mJKgR_l!lJ9P^bW;NAv{G^LdLFrsBYpm3ZXAqPsvS<_8VKID4rH2M)gm z*MvKyCq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V?d00001 diff --git a/pages/topics/index.js b/pages/topics/index.js index daeb49c..47034a5 100644 --- a/pages/topics/index.js +++ b/pages/topics/index.js @@ -25,18 +25,33 @@ Page({ */ onLoad: function () { - if (store.hasPhone()) { - console.log('已经绑定手机号码') + if (store.hasBindUserInfo()){ + console.log('已经绑定微信') + if (store.hasPhone()) { + console.log('已经绑定手机号码') + } else { + console.log('未绑定手机号码') + wx.redirectTo({ + url: '/pages/register/index', + }) + } } else { - console.log('未绑定手机号码') - wx.redirectTo({ - url: '/pages/register/index', + console.log('未绑定微信') + wx.reLaunch({ + url: '/pages/user/index', }) } + }, onShow: function () { // 页面出现在前台时执行 console.log('啦啦啦') + let segmentIndex = this.data.segmentIndex + if (segmentIndex === 0 || segmentIndex === 1){ + wx.pageScrollTo({ + scrollTop: 0, + }) + } this.setData({ currPage: 1, }) diff --git a/pages/topics/interactive/submitTopic/index.wxss b/pages/topics/interactive/submitTopic/index.wxss index 6fe0e45..bbc4f20 100644 --- a/pages/topics/interactive/submitTopic/index.wxss +++ b/pages/topics/interactive/submitTopic/index.wxss @@ -15,9 +15,11 @@ } .title{ font-size: 15px; + width: 100%; } .textArea{ font-size: 14px; + width: 100%; } .line-view{ height: 1px; diff --git a/pages/topics/message/index.wxss b/pages/topics/message/index.wxss index 2f287a2..a5f7e02 100644 --- a/pages/topics/message/index.wxss +++ b/pages/topics/message/index.wxss @@ -15,10 +15,12 @@ } .title{ font-size: 15px; + width: 100%; } .textArea{ font-size: 14px; - line-height: 10px; + width: 100%; + /* line-height: 10px; */ } .line-view{ height: 1px; diff --git a/pages/user/myFavorite/index.wxml b/pages/user/myFavorite/index.wxml index 42b0395..e0b8ad1 100644 --- a/pages/user/myFavorite/index.wxml +++ b/pages/user/myFavorite/index.wxml @@ -18,7 +18,7 @@ time="{{item.time}}" commentNum="{{item.commentNum}}" type="{{item.type}}" - userIcon="{{item.userIcon}}" + userIcon="{{item.userIcon || '/images/topic/avatar.png'}}" bind:clickListItem="clickListItem"/>