This repository was archived by the owner on Jan 3, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +8
-11
lines changed Expand file tree Collapse file tree 3 files changed +8
-11
lines changed Original file line number Diff line number Diff line change @@ -25,6 +25,9 @@ class CommentUp extends Component {
25
25
26
26
27
27
_onUpPress ( ) {
28
+ if ( this . props . user . loginname == this . props . authorName ) {
29
+ return window . alert ( '不能给自己点赞哦!' )
30
+ }
28
31
if ( this . state . isLoading ) return
29
32
30
33
this . setState ( {
Original file line number Diff line number Diff line change @@ -90,13 +90,11 @@ class HtmlContent extends Component {
90
90
uri = 'https:' + uri
91
91
}
92
92
return (
93
- < View
93
+ < Image
94
94
key = { index }
95
- style = { styles . imgWrapper } >
96
- < Image source = { { uri :uri } }
97
- style = { styles . img } >
98
- </ Image >
99
- </ View >
95
+ source = { { uri :uri } }
96
+ style = { styles . img } >
97
+ </ Image >
100
98
)
101
99
}
102
100
}
Original file line number Diff line number Diff line change @@ -241,11 +241,6 @@ class Comments extends Component {
241
241
}
242
242
243
243
244
- _onUpPress ( ) {
245
-
246
- }
247
-
248
-
249
244
_onCommentTitlePress ( ) {
250
245
this . _listView . setNativeProps ( {
251
246
contentOffset : {
@@ -275,6 +270,7 @@ class Comments extends Component {
275
270
< View style = { styles . commentFooter } >
276
271
< CommentUp
277
272
replyId = { comment . id }
273
+ authorName = { authorName }
278
274
ups = { comment . ups }
279
275
user = { this . props . state . user }
280
276
style = { styles . up }
You can’t perform that action at this time.
0 commit comments