diff --git a/models/user.js b/models/user.js index 8ba4376..49b4680 100644 --- a/models/user.js +++ b/models/user.js @@ -26,7 +26,7 @@ class UserModel extends HTTP { } - updateUserInfo(avatarUrl, nickName, phone, company, position, success){ + updateUserInfo(avatarUrl, nickName, success){ let params = { url: UserConst.user_updateUserInfo_url, method: Method.POST, @@ -34,9 +34,6 @@ class UserModel extends HTTP { isRegister: 2, //1.注册 2.修改用户信息 avatar: avatarUrl, realName: nickName, - phone: phone, - company: company, - position, position }, success: success } diff --git a/pages/topics/goodIdea/cell/index.wxml b/pages/topics/goodIdea/cell/index.wxml index d935294..6b7177c 100644 --- a/pages/topics/goodIdea/cell/index.wxml +++ b/pages/topics/goodIdea/cell/index.wxml @@ -8,9 +8,6 @@ {{itemData.commentName}} {{itemData.commentTime}} - - - {{itemData.praiseNum}} diff --git a/pages/topics/goodIdea/cell/index.wxss b/pages/topics/goodIdea/cell/index.wxss index 5ad1789..2bba21e 100644 --- a/pages/topics/goodIdea/cell/index.wxss +++ b/pages/topics/goodIdea/cell/index.wxss @@ -49,11 +49,7 @@ image{ color: #66708B; font-size: 14px; } -.goodIdeaIcon{ - width: 30px; - height: 15px; - line-height: 10px; -} + .comment-time{ margin: 0 5px 0 5px; font-size: 12px; diff --git a/pages/topics/goodIdea/index.js b/pages/topics/goodIdea/index.js index 37b3221..788b31f 100644 --- a/pages/topics/goodIdea/index.js +++ b/pages/topics/goodIdea/index.js @@ -26,8 +26,6 @@ Component({ methods: { onClickPraise(e){ const itemData = e.detail.itemData; - // console.log(itemData); - // this.fetchGoodIdeaPraise(itemData.commentId) this.triggerEvent('tapGoodIdeaPraise', { commentId: itemData.commentId }) } } diff --git a/pages/topics/index.js b/pages/topics/index.js index 3a51990..df013a9 100644 --- a/pages/topics/index.js +++ b/pages/topics/index.js @@ -52,6 +52,12 @@ Page({ topicModel.getTopicList(page, res => { console.log('议题列表') console.log(res) + if (res.result.list.length == 0) { + wx.showToast({ + title: '暂无数据', + icon: 'none' + }) + } const datas = res.result.list let tempDatas = [] diff --git a/pages/topics/interactive/submitTopic/index.js b/pages/topics/interactive/submitTopic/index.js index 8877645..dd45137 100644 --- a/pages/topics/interactive/submitTopic/index.js +++ b/pages/topics/interactive/submitTopic/index.js @@ -64,7 +64,16 @@ Page({ }) }) }, + deleteFile(e){ + console.log(e) + let tempImages = this.data.files + const index = e.detail.index + tempImages.splice(index, 1); + this.setData({ + files:tempImages + }) + }, submit(){ if (this.data.topicTitle === ""){ wx.showToast({ @@ -73,13 +82,13 @@ Page({ }) return } - // if (this.data.topicDetail === "") { - // wx.showToast({ - // title: '请输入议题内容', - // icon: 'none' - // }) - // return - // } + if (this.data.topicDetail === "") { + wx.showToast({ + title: '请输入议题内容', + icon: 'none' + }) + return + } const tempImages = [] this.data.files.forEach(item=>{ tempImages.push(item.url) diff --git a/pages/topics/interactive/submitTopic/index.wxml b/pages/topics/interactive/submitTopic/index.wxml index 1e0897f..eddd7d6 100644 --- a/pages/topics/interactive/submitTopic/index.wxml +++ b/pages/topics/interactive/submitTopic/index.wxml @@ -1,8 +1,16 @@ - + + + + + -