index.wxml 5.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. <wxs src="../../utils/filter.wxs" module="filters" />
  2. <view class="commentBox" wx:if="{{show}}">
  3. <view class="commentBg" catchtap="close" catchtouchmove="true"></view>
  4. <view class="comment {{tabBarPadding?'seat2':''}}" animation="{{animationData}}">
  5. <view class="header">
  6. <view class="hl {{type=='comment'?'currentH':''}}" bindtap="changeType" data-type="comment">评论
  7. {{count.commentNum}}
  8. </view>
  9. <view class="hl {{type=='like'?'currentH':''}}" bindtap="changeType" data-type="like">赞 {{count.likeNum}}
  10. </view>
  11. <view class=" hr" catchtap="close">×</view>
  12. </view>
  13. <scroll-view scroll-y="true" class="body" bindscrolltolower='loadMore' bindtap="cancelId">
  14. <view class="body-box">
  15. <view class="content" wx:for="{{list}}" wx:key="id" data-uid='{{item.user.uid}}' bindtap="jumpUserInfo">
  16. <image src="{{item.user.avatar}}" class="c-avatar" />
  17. <view class="c-right" wx:if="{{type=='comment'}}">
  18. <view class="nickName">
  19. {{item.user.nickName||item.user.eid}}
  20. </view>
  21. <view class="detailDesc" data-id='{{item.id}}' data-type='1' bind:longpress="onLongPress"
  22. hover-class='hoverClass'>
  23. {{item.detailDesc}}
  24. </view>
  25. <view class="replyList" wx:if="{{item.replyVOList.length>0}}">
  26. <view class="reply" wx:for="{{item.replyVOList}}" wx:for-item="reply" wx:key='id'
  27. data-parent="{{item.id}}" data-id='{{reply.id}}' data-type='2'
  28. bind:longpress="onLongPress" hover-class='hoverClass2'>
  29. <text class="replyTitle">{{reply.user.nickName||reply.user.eid}}</text>
  30. <text class="replyContent">:{{reply.content}}</text>
  31. </view>
  32. </view>
  33. <view class="record">
  34. <view class="time">{{filters.formatDate(item.gmtCreated,3)}}</view>
  35. <view class="record-right">
  36. <view class="iconBox" catchtap="{{item.isLike? null:'setLike'}}" data-index="{{index}}"
  37. data-id="{{item.id}}">
  38. <image class="icon"
  39. src="{{item.isLike? '/static/like_reply.png' : '/static/like_reply_grey.png'}}" />
  40. <text>{{item.likeCount}}</text>
  41. </view>
  42. <view class="iconBox" catchtap="ReplyComment" data-index="{{index}}"
  43. data-id="{{item.id}}">
  44. <image class="icon" src="/static/reply_icon.png" />
  45. <text>{{item.replyCount}}</text>
  46. </view>
  47. </view>
  48. </view>
  49. </view>
  50. <view class="c-like" wx:else>
  51. <view class="left">
  52. <view class="nickName">
  53. {{item.user.nickName||item.user.eid}}
  54. </view>
  55. <view class="time">{{item.gmtCreated}}</view>
  56. </view>
  57. <view class="follow {{item.isFans?'isFans':''}}" data-user='{{item}}' catchtap="setFans"
  58. wx:if="{{item.uid!=uid}}">
  59. <image src="{{item.isFans?'/static/follow_2.png':'/static/follow_3.png'}}" class="character"
  60. mode="" />
  61. <text class="text">{{item.isFans?'已关注':'关注'}}</text>
  62. </view>
  63. </view>
  64. </view>
  65. </view>
  66. </scroll-view>
  67. <!-- 快捷回复 -->
  68. <view class=" quick" wx:if="{{quickShow&&type=='comment'}}">
  69. <view class="close" catchtap="quickClose">×</view>
  70. <view class="quickTop">
  71. <view class="left">留下你的赞美,鼓励一下。</view>
  72. <view class="right">试试下面的快捷回复吧~</view>
  73. </view>
  74. <scroll-view class="contents" scroll-x="true" enhanced show-scrollbar="{{false}}">
  75. <view class="remark" bindtap="quickRemark" data-remark='你读的也太棒啦!' style="background-color: #FC614E">
  76. 你读的也太棒啦!
  77. </view>
  78. <view class="remark" bindtap="quickRemark" data-remark='很优秀,向你学习'>
  79. 很优秀,向你学习
  80. </view>
  81. <view class="remark" bindtap="quickRemark" data-remark='挺好的,期待更好' style="background-color: #26B944">
  82. 挺好的,期待更好
  83. </view>
  84. <view class="remark" bindtap="quickRemark" data-remark='还可以,继续努力' style="background-color: #7DB2FF">
  85. 还可以,继续努力
  86. </view>
  87. </scroll-view>
  88. </view>
  89. <view class="footer">
  90. <input class="input" bindinput="bindKeyInput" bindfocus='cleanPlaceholder' bindblur='setPlaceholder' value="{{detailDesc}}" placeholder="{{placeholderText}}"
  91. focus="{{ifGetFocus}}" />
  92. <view class="submit" bindtap="sendReply">发送</view>
  93. </view>
  94. </view>
  95. </view>