comment-detail.vue 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <template>
  2. <v-header title="评价详情" border backgroundColor="#fff">
  3. <flat-list
  4. @changeData="flatChangeData"
  5. background="transparent"
  6. :ref="base_flat_id"
  7. @fetch="fetch"
  8. mode="skeleton"
  9. :refresh="false"
  10. :skeleton="parentItem.replay >= 10 ? 10: parentItem.replay"
  11. >
  12. <view class="detail-header overflow" slot="header">
  13. <layout-comment
  14. size="big"
  15. :item="parentItem"
  16. ></layout-comment>
  17. </view>
  18. <view class="detail-list">
  19. <view class="detail-list-title">评价回复<text v-if="parentItem.replay">({{parentItem.replay}})</text></view>
  20. <view class="detail-item"
  21. v-for="(item,index) in base_flat_data.data"
  22. :key="index"
  23. >
  24. <layout-comment
  25. size="big"
  26. :item="item"
  27. :rate="false"
  28. :image="false"
  29. ></layout-comment>
  30. </view>
  31. </view>
  32. <!-- 底部 -->
  33. <view class="detail-footer row aCenter" slot="end-footer">
  34. <view class="flex-all-1 detail-input jCenter">
  35. <input v-model="value" type="text" maxlength="200" placeholder="写个评论聊聊" placeholder-class="detail-input-placeholder" class="detail-input-target" />
  36. </view>
  37. <view v-if="isLogin"
  38. class="detail-button center"
  39. :class="{'detail-button-disabled':disabled}"
  40. @click="sendMessage">评价</view>
  41. <view v-else class="detail-login-button center" @click="routerLogin">登录后发表评论</view>
  42. </view>
  43. </flat-list>
  44. </v-header>
  45. </template>
  46. <script>
  47. import vHeader from '@/components/v-header/main.vue';
  48. import flatList from '@/components/flat-list/src/main';
  49. import layoutComment from '@/layout/layout-commet/main';
  50. import mixins from './mixins';
  51. export default {
  52. name: "comment-detail",
  53. components:{
  54. vHeader,
  55. flatList,
  56. layoutComment
  57. },
  58. mixins
  59. }
  60. </script>
  61. <style scoped src="./style.scss" lang="scss"></style>