瑶都万能墙
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.

161 lines
2.8 KiB

4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
  1. <template>
  2. <view class="postDetail">
  3. <navbar leftClick @leftClick="$utils.navigateBack" title="详情" />
  4. <view class="swipe">
  5. <uv-swiper
  6. :list="[detail.imageTitle]"
  7. indicator
  8. height="420rpx"></uv-swiper>
  9. </view>
  10. <view class="box">
  11. <view class="title">
  12. {{ detail.title }}
  13. </view>
  14. <view class="createBy">
  15. {{ detail.num }}余座
  16. {{ detail.startTime }}出发
  17. </view>
  18. <view class="createBy">
  19. {{ detail.startAddress }}
  20. {{ detail.endAddress }}
  21. </view>
  22. <view class="createBy">
  23. <view class="">
  24. {{ $dayjs(detail.createTime).format('YYYY-MM-DD') }}
  25. </view>
  26. <view class="phone"
  27. v-if="detail.phone"
  28. @click.stop="callPhone">
  29. <image src="/static/image/home/phone.png" mode=""></image>
  30. 联系司机
  31. </view>
  32. </view>
  33. </view>
  34. <commentList
  35. @getData="getData"
  36. :list="list"
  37. :params="params"
  38. />
  39. </view>
  40. </template>
  41. <script>
  42. import mixinsList from '@/mixins/list.js'
  43. import commentList from '../components/list/comment/commentList.vue'
  44. export default {
  45. mixins: [mixinsList],
  46. components: {
  47. commentList
  48. },
  49. data() {
  50. return {
  51. detail: {},
  52. mixinsListApi : 'getCommentPage',
  53. params : {
  54. type : '7',
  55. orderId : '',
  56. name : '',
  57. },
  58. id : 0,
  59. }
  60. },
  61. onLoad(options) {
  62. // this.$route.query的参数
  63. console.log(options)
  64. this.id = options.id
  65. this.queryParams.type = this.params.type
  66. this.queryParams.orderId = options.id
  67. this.params.orderId = options.id
  68. },
  69. onPullDownRefresh(){
  70. this.getDetail()
  71. },
  72. onShow() {
  73. this.getDetail()
  74. },
  75. onShareAppMessage(res) {
  76. return {
  77. title: this.detail.title,
  78. path: '/pages_order/scenicSpot/scenicSpotDetail?id=' + this.id
  79. }
  80. },
  81. methods: {
  82. getDetail() {
  83. this.$api('getCatDetail', {
  84. id : this.id
  85. }, res => {
  86. uni.stopPullDownRefresh()
  87. if (res.code == 200) {
  88. this.params.title = res.result.title
  89. this.detail = res.result
  90. }
  91. })
  92. },
  93. }
  94. }
  95. </script>
  96. <style lang="scss" scoped>
  97. .postDetail {
  98. .box {
  99. padding: 20rpx;
  100. width: 100vw;
  101. background-color: #fff;
  102. box-sizing: border-box;
  103. .title {
  104. font-size: 34rpx;
  105. font-weight: 600;
  106. color: #000;
  107. }
  108. .createBy {
  109. display: flex;
  110. margin-top: auto;
  111. margin-bottom: 10rpx;
  112. font-size: 24rpx;
  113. margin-top: 20rpx;
  114. color: #555;
  115. &>view {
  116. display: flex;
  117. align-items: center;
  118. justify-content: center;
  119. padding-right: 20rpx;
  120. }
  121. }
  122. .controls {
  123. margin-top: 30rpx;
  124. }
  125. .content {
  126. margin-top: 30rpx;
  127. font-size: 28rpx;
  128. }
  129. }
  130. }
  131. .phone{
  132. background-color: rgba($uni-color, 0.2);
  133. color: $uni-color;
  134. padding: 8rpx 16rpx;
  135. border-radius: 10rpx;
  136. margin-left: auto;
  137. image{
  138. width: 20rpx;
  139. height: 20rpx;
  140. }
  141. }
  142. </style>