This repository was archived by the owner on Jul 30, 2020. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +11
-5
lines changed Expand file tree Collapse file tree 3 files changed +11
-5
lines changed Original file line number Diff line number Diff line change 53
53
- 展示未读消息数和消息已读
54
54
- 部分页面添加下拉刷新
55
55
- 主页几个tab切换有点bug
56
+ - 请求失败状态码非200会抛异常,如何统一优雅处理
56
57
后话:
57
58
58
59
这个项目没有涉及到太多复杂的部分,主要到是业务逻辑的开发,对于作为一个vue和mpvue小程序入门项目是非常合适的。由于开发时间短,部分代码质量和交互做得不太好。对于未完成的部分和部分未知bug欢迎各位star、提issue、提pr一起来玩2333.
Original file line number Diff line number Diff line change @@ -4,7 +4,6 @@ import flyio from 'flyio/dist/npm/wx'
4
4
Vue . prototype . $http = new flyio
5
5
Vue . config . productionTip = false
6
6
App . mpType = 'app'
7
-
8
7
const app = new Vue ( App )
9
8
app . $mount ( )
10
9
Original file line number Diff line number Diff line change 1
1
<template >
2
2
<div class =' container' >
3
3
<div v-if =' sendVisible' >
4
- <sendReply @close-modal =' closeModal' @reply-success =' replySuccess' :content =' atWho ' :topicId =' id' :replyId =' replyId' ></sendReply >
4
+ <sendReply @close-modal =' closeModal' @reply-success =' replySuccess' :content =' content ' :topicId =' id' :replyId =' replyId' ></sendReply >
5
5
</div >
6
6
<div >
7
7
<div class =' header' >
39
39
</p >
40
40
<div class =' foot' >
41
41
<div :data-replyid =' item.id' :data-originindex =' originindex' @click.stop =" upOrCancel($event)" ><img class =' icon' v-if =' !item.is_uped' src =' ../../../static/good1.png' /><img class =' icon' v-if =' item.is_uped' src =' ../../../static/good2.png' /><span >点赞:{{item.ups.length}}</span ></div >
42
- <div @click.stop =" showReplyModal($event)" :data-replyid =' item.id' ><img class =' icon' src =' ../../../static/chat.png' /><span >回复</span ></div >
42
+ <div :data-loginname = ' item.author.loginname ' @click.stop =" showReplyModal($event)" :data-replyid =' item.id' ><img class =' icon' src =' ../../../static/chat.png' /><span >回复</span ></div >
43
43
</div >
44
44
</div >
45
45
</div >
@@ -133,7 +133,13 @@ export default {
133
133
}
134
134
},
135
135
showReplyModal (e ) {
136
- console .log (e);
136
+ const replyname = e .currentTarget .dataset .loginname ;
137
+ if (replyname) {
138
+ this .content = ` @${ replyname} ` ;
139
+ } else {
140
+ this .content = " " ;
141
+ }
142
+
137
143
this .replyId = e .currentTarget .dataset .replyid ;
138
144
this .sendVisible = true ;
139
145
},
@@ -153,7 +159,7 @@ export default {
153
159
data () {
154
160
return {
155
161
detailData: {},
156
- atWho : " " ,
162
+ content : " " ,
157
163
sendVisible: false ,
158
164
id: " " ,
159
165
replyId: " "
You can’t perform that action at this time.
0 commit comments