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

240 lines
4.3 KiB

10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
  1. <template>
  2. <view class="postDetail">
  3. <navbar leftClick @leftClick="$utils.navigateBack" title="详情" />
  4. <view class="swipe">
  5. <uv-swiper :list="detail.images" indicator height="540rpx"></uv-swiper>
  6. </view>
  7. <view class="box">
  8. <view class="title">
  9. {{ detail.name }}
  10. <view class="spot">
  11. 3A景区
  12. </view>
  13. </view>
  14. <view class="pig">
  15. 江华同志故居位于永州市江华瑶族自治县大石桥...
  16. </view>
  17. <hr />
  18. <view class="mie">
  19. <view class="dog">
  20. 开园时间 830-17.30
  21. </view>
  22. <view class="look">
  23. 入园须知
  24. </view>
  25. <uv-icon name="arrow-right"></uv-icon>
  26. </view>
  27. <hr />
  28. <!-- <view class="createBy">
  29. <view class="">
  30. // 发布时间:{{ $dayjs(detail.createTime).format('YYYY-MM-DD') }}
  31. </view>
  32. </view> -->
  33. <!-- <view class="createBy">
  34. <view class="">
  35. 地址{{ detail.address }}
  36. </view>
  37. </view> -->
  38. <addressSpot :address="detail.address" :latitude="detail.latitude" :longitude="detail.longitude" />
  39. </view>
  40. <view style="background-color: #fff;margin-top: 20rpx;">
  41. <uv-tabs :list="tags"
  42. :activeStyle="{color : '#000', fontWeight : 900}"
  43. lineColor="#5baaff"
  44. lineHeight="8rpx"
  45. lineWidth="50rpx"
  46. :scrollable="false"
  47. @click="tabsClick"></uv-tabs>
  48. </view>
  49. <view class="content" v-if="tagIndex == 1">
  50. <uv-parse :content="detail.details"></uv-parse>
  51. </view>
  52. <commentList v-if="tagIndex == 0" @getData="getData" :list="list" :params="params" />
  53. </view>
  54. </template>
  55. <script>
  56. import mixinsList from '@/mixins/list.js'
  57. import commentList from '../components/list/comment/commentList.vue'
  58. export default {
  59. mixins: [mixinsList],
  60. components: {
  61. commentList
  62. },
  63. data() {
  64. return {
  65. detail: {},
  66. mixinsListApi: 'getCommentPage',
  67. params: {
  68. type: '3',
  69. orderId: '',
  70. name: '',
  71. },
  72. id: 0,
  73. tags : [
  74. {
  75. name : '景区评论'
  76. },
  77. {
  78. name : '景区详情'
  79. },
  80. ],
  81. tagIndex : 0,
  82. }
  83. },
  84. onLoad(options) {
  85. // this.$route.query的参数
  86. console.log(options)
  87. this.id = options.id
  88. this.queryParams.type = this.params.type
  89. this.queryParams.orderId = options.id
  90. this.params.orderId = options.id
  91. },
  92. onPullDownRefresh() {
  93. this.getDetail()
  94. },
  95. onShow() {
  96. this.getDetail()
  97. },
  98. onShareAppMessage(res) {
  99. return {
  100. title: this.detail.name,
  101. path: '/pages_order/scenicSpot/scenicSpotDetail?id=' + this.id
  102. }
  103. },
  104. methods: {
  105. tabsClick({index}){
  106. this.tagIndex = index
  107. },
  108. click(item) {
  109. console.log('item', item);
  110. },
  111. getDetail() {
  112. this.$api('getScenicDetail', {
  113. id: this.id
  114. }, res => {
  115. uni.stopPullDownRefresh()
  116. if (res.code == 200) {
  117. this.params.name = res.result.name
  118. this.detail = res.result
  119. this.detail.images = res.result.images && res.result.images.split(',')
  120. }
  121. })
  122. },
  123. }
  124. }
  125. </script>
  126. <style lang="scss" scoped>
  127. .postDetail {
  128. .box {
  129. padding: 20rpx;
  130. width: 100vw;
  131. background-color: #fff;
  132. box-sizing: border-box;
  133. .title {
  134. display: flex;
  135. font-size: 34rpx;
  136. font-weight: 600;
  137. color: #000;
  138. .spot {
  139. margin: 0rpx 20rpx;
  140. padding: 5rpx;
  141. background-color: $uni-color;
  142. border-radius: 10rpx;
  143. color: #fff;
  144. font-size: 30rpx;
  145. letter-spacing: 5rpx;
  146. }
  147. }
  148. .pig {
  149. margin: 50rpx 0rpx;
  150. font-size: 25rpx;
  151. color: $uni-color;
  152. }
  153. .mie {
  154. display: flex;
  155. justify-content: space-between;
  156. .dog {
  157. margin: 30rpx 0rpx;
  158. font-size: 25rpx;
  159. color: $uni-color;
  160. }
  161. .look {
  162. margin: 30rpx 0rpx;
  163. margin-left: 320rpx;
  164. font-size: 25rpx;
  165. }
  166. }
  167. hr {
  168. opacity: 0.5;
  169. }
  170. .createBy {
  171. display: flex;
  172. margin-top: auto;
  173. margin-bottom: 10rpx;
  174. font-size: 24rpx;
  175. margin-top: 20rpx;
  176. color: #555;
  177. &>view {
  178. display: flex;
  179. align-items: center;
  180. justify-content: center;
  181. padding-right: 20rpx;
  182. }
  183. }
  184. .ditu {
  185. display: flex;
  186. justify-content: space-between;
  187. .weizhi {
  188. font-size: 25rpx;
  189. margin-top: 25rpx;
  190. opacity: 0.7;
  191. }
  192. }
  193. .controls {
  194. margin-top: 30rpx;
  195. }
  196. }
  197. .content {
  198. padding: 30rpx;
  199. margin-top: 30rpx;
  200. font-size: 28rpx;
  201. background-color: #fff;
  202. padding-bottom: 100rpx;
  203. }
  204. }
  205. </style>