普兆健康管家前端代码仓库
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

131 lines
2.7 KiB

2 months ago
2 months ago
2 months ago
2 months ago
2 months ago
2 months ago
2 months ago
2 months ago
  1. <template>
  2. <view class="page__view">
  3. <navbar title="我的评价" leftClick @leftClick="$utils.navigateBack" color="#191919" bgColor="#FFFFFF" />
  4. <view class="main">
  5. <view class="tabs">
  6. <uv-tabs
  7. :list="tabs"
  8. :scrollable="false"
  9. lineColor="#7451DE"
  10. lineWidth="48rpx"
  11. lineHeight="4rpx"
  12. :activeStyle="{
  13. 'font-family': 'PingFang SC',
  14. 'font-weight': 500,
  15. 'font-size': '32rpx',
  16. 'line-height': 1.4,
  17. 'color': '#7451DE',
  18. }"
  19. :inactiveStyle="{
  20. 'font-family': 'PingFang SC',
  21. 'font-weight': 400,
  22. 'font-size': '32rpx',
  23. 'line-height': 1.4,
  24. 'color': '#181818',
  25. }"
  26. @click="clickTabs"
  27. ></uv-tabs>
  28. </view>
  29. <view class="comment">
  30. <view class="comment-item" v-for="item in list" :key="item.id">
  31. <commentCard :data="item" mode="edit" @deleteSucc="getData"></commentCard>
  32. </view>
  33. </view>
  34. </view>
  35. </view>
  36. </template>
  37. <script>
  38. import mixinsList from '@/mixins/list.js'
  39. import commentCard from '@/pages_order/comment/commentCard.vue'
  40. export default {
  41. mixins: [mixinsList],
  42. components: {
  43. commentCard,
  44. },
  45. data() {
  46. return {
  47. tabs: [
  48. { name: '全部' },
  49. { name: '有图/视频' },
  50. { name: '最新' },
  51. ],
  52. queryParams: {
  53. pageNo: 1,
  54. pageSize: 10,
  55. },
  56. mixinsListApi: 'myEvaluate',
  57. }
  58. },
  59. onShow() {
  60. console.log('onShow')
  61. },
  62. onLoad() {
  63. this.getData()
  64. },
  65. methods: {
  66. //点击tab栏
  67. clickTabs({ index }) {
  68. // 【type不传为全部,0是有图,1是最新】
  69. if (index == 0) {
  70. delete this.queryParams.type
  71. } else {
  72. this.queryParams.type = index - 1
  73. }
  74. this.getData()
  75. },
  76. },
  77. }
  78. </script>
  79. <style scoped lang="scss">
  80. .page__view {
  81. width: 100vw;
  82. min-height: 100vh;
  83. background-color: $uni-bg-color;
  84. position: relative;
  85. /deep/ .nav-bar__view {
  86. position: fixed;
  87. top: 0;
  88. left: 0;
  89. }
  90. }
  91. .main {
  92. width: 100vw;
  93. padding-top: calc(var(--status-bar-height) + 204rpx);
  94. box-sizing: border-box;
  95. .tabs {
  96. position: fixed;
  97. top: calc(var(--status-bar-height) + 120rpx);
  98. left: 0;
  99. width: 100%;
  100. height: 84rpx;
  101. background: #FFFFFF;
  102. /deep/ .uv-tabs__wrapper__nav__line {
  103. border-radius: 2rpx;
  104. }
  105. }
  106. }
  107. .comment {
  108. padding: 40rpx 32rpx;
  109. &-item {
  110. & + & {
  111. margin-top: 40rpx;
  112. }
  113. }
  114. }
  115. </style>