diff --git a/pages/community/info.js b/pages/community/info.js index b9b8dbb..2d21eb2 100644 --- a/pages/community/info.js +++ b/pages/community/info.js @@ -12,7 +12,7 @@ Page({ id: '', info: null, content: '', - + autoSize: {maxHeight: 300, minHeight: 60} }, /** @@ -49,10 +49,10 @@ Page({ parentId: this.data.id, rootId: this.data.id } - console.log(data); api('/comment/add', 'POST', data, 'json').then(res => { if (res.code === 200) { this.fetchInfo() + this.setData({content:''}) } }) }, diff --git a/pages/community/info.json b/pages/community/info.json index 8835af0..edfbb38 100644 --- a/pages/community/info.json +++ b/pages/community/info.json @@ -1,3 +1,5 @@ { - "usingComponents": {} + "usingComponents": { + "t-textarea": "tdesign-miniprogram/textarea/textarea" + } } \ No newline at end of file diff --git a/pages/community/info.wxml b/pages/community/info.wxml index 0698e5a..0be6586 100644 --- a/pages/community/info.wxml +++ b/pages/community/info.wxml @@ -1,70 +1,67 @@ - + - - - - {{info.user.name}} - {{info.createdAt}} + + + + {{info.user.name}} + {{info.createdAt}} + + + + {{info.content}} + + + + + + + + + + + + + + + + + {{info.likeCount}} + + + + {{info.commentCount}} + - - {{info.content}} - - - - - - - - - - - + + + + + + + + {{item.user.name}} + + + {{item.createdAt}} + + + + {{item.content}} - - - - {{info.likeCount}} - - - - {{info.commentCount}} - - - - - - - - - - - {{item.user.name}} - - - {{item.createdAt}} - - - - {{item.content}} - - - - - - - + + + - - + \ No newline at end of file diff --git a/pages/knowlage/index.wxml b/pages/knowlage/index.wxml index e1e1944..ae68251 100644 --- a/pages/knowlage/index.wxml +++ b/pages/knowlage/index.wxml @@ -18,7 +18,7 @@ - + 已拥有 可兑换 diff --git a/pages/user/index.wxml b/pages/user/index.wxml index 91c2539..ff868db 100644 --- a/pages/user/index.wxml +++ b/pages/user/index.wxml @@ -87,7 +87,7 @@ - +