strategyDetatil.vue 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174
  1. <template>
  2. <view class="container">
  3. <view class="title">这里不是瑞士!是江西靖安!</view>
  4. <view class="time">2023-09-08 15:15:15</view>
  5. <rich-text class="desc" :nodes="strings"></rich-text>
  6. <rich-text class="desc" :nodes="strings2"></rich-text>
  7. <view class="tags">
  8. <view class="tag">#南昌周边游</view>
  9. <view class="tag">#江西旅游</view>
  10. <view class="tag">#靖安旅游</view>
  11. <view class="tag">#靖安民宿</view>
  12. <view class="tag">#民宿推荐</view>
  13. <view class="tag">#周末去哪玩</view>
  14. </view>
  15. <view class="imgList">
  16. <img v-for="(ele, index) in imgList" :key="index" mode="scpectfill" :src="ele" @click="handleImg(index)" />
  17. </view>
  18. <view class="info" @click="handleClick">
  19. <view class="info_left">
  20. <view class="left_top">
  21. <img src="../../static/index/hotel2.png" />
  22. <view class="top_info">附近 | 靖安沐光源宿</view>
  23. <view class="top_rate">5.0分</view>
  24. </view>
  25. <view class="left_bottom">经济型 中源乡 4.4km</view>
  26. </view>
  27. <view class="info_right">
  28. <img src="../../static/index/star.png" />
  29. 2100
  30. </view>
  31. </view>
  32. </view>
  33. </template>
  34. <script>
  35. export default {
  36. data() {
  37. return {
  38. strings:
  39. '<div>南昌周边度假的宝藏民宿🏠享受山野间森呼吸🌿</div> <div>很适合逃离城市奔向大自然的快乐躺平☁</div> <div>阴雨绵绵也抵挡不住它的美☔</div> <div>心向山野 尽请赴约🍃</div> <div>一房一景 设计独特 🪐</div> <div>室内有着巨大落地窗🚪</div> <div>地址⛺️宜春市靖安县宁福线中源乡合港村南段组10号</div> <div>交通🚘南昌自驾开车约2H</div> <div>风格⛱民宿是新中式生活美学的格调 非常高级还配备中餐厅、商务会议室、茶室、休闲娱乐包厢等🎞</div> <div>适合情侣、家庭自驾游玩 💕</div>',
  40. strings2:
  41. '<div>🔆附近景区游玩推荐:</div> <div>北岭花海、九岭瀑布、九门楼、九岭尖云海、日出、冰雪、风车、草甸、露营、游客中心、清水平台观景、河道游船、观赏荷花、采莲、客家民俗、农俗活动及客家美食、小吃、果脯、高山滑雪、梯田等</div>',
  42. imgList: [
  43. 'https://chtech.ncjti.edu.cn/hotelReservation/image/19.jpg',
  44. 'https://chtech.ncjti.edu.cn/hotelReservation/image/20.jpg',
  45. 'https://chtech.ncjti.edu.cn/hotelReservation/image/21.jpg',
  46. 'https://chtech.ncjti.edu.cn/hotelReservation/image/22.jpg',
  47. 'https://chtech.ncjti.edu.cn/hotelReservation/image/23.jpg',
  48. 'https://chtech.ncjti.edu.cn/hotelReservation/image/24.jpg',
  49. 'https://chtech.ncjti.edu.cn/hotelReservation/image/25.jpg',
  50. 'https://chtech.ncjti.edu.cn/hotelReservation/image/26.jpg',
  51. 'https://chtech.ncjti.edu.cn/hotelReservation/image/27.jpg'
  52. ]
  53. }
  54. },
  55. methods: {
  56. handleClick() {
  57. uni.navigateTo({
  58. url: `/pages/detail/detail?id=${1363527549}`
  59. })
  60. },
  61. handleImg(index) {
  62. uni.previewImage({
  63. urls: this.imgList,
  64. current: index
  65. })
  66. }
  67. }
  68. }
  69. </script>
  70. <style lang="scss" scoped>
  71. .container {
  72. padding: 30rpx;
  73. min-height: 100vh;
  74. background-color: #ffffff;
  75. .title {
  76. font-size: 36rpx;
  77. font-weight: bold;
  78. }
  79. .time {
  80. margin: 10rpx 0 20rpx;
  81. color: #808080;
  82. font-size: 28rpx;
  83. }
  84. .desc {
  85. line-height: 45rpx;
  86. font-size: 28rpx;
  87. }
  88. .tags {
  89. display: flex;
  90. flex-wrap: wrap;
  91. margin: 15rpx 0;
  92. font-size: 28rpx;
  93. color: #1e7dfb;
  94. .tag {
  95. }
  96. }
  97. .imgList {
  98. display: grid;
  99. grid-template-columns: repeat(auto-fill, 223rpx);
  100. gap: 10rpx;
  101. img {
  102. width: 223rpx;
  103. height: 223rpx;
  104. border-radius: 11rpx;
  105. }
  106. }
  107. .info {
  108. display: flex;
  109. box-sizing: border-box;
  110. padding: 0 20rpx 0 15rpx;
  111. margin: 40rpx 0 48rpx;
  112. width: 690rpx;
  113. height: 130rpx;
  114. border-radius: 13rpx;
  115. background-color: #f2f2f2;
  116. .info_left {
  117. flex: 4;
  118. display: flex;
  119. flex-direction: column;
  120. justify-content: space-evenly;
  121. .left_top {
  122. display: flex;
  123. align-items: center;
  124. img {
  125. width: 34rpx;
  126. height: 34rpx;
  127. }
  128. .top_info {
  129. margin: 0 34rpx 0 13rpx;
  130. font-size: 28rpx;
  131. }
  132. .top_rate {
  133. font-size: 24rpx;
  134. }
  135. }
  136. .left_bottom {
  137. margin-left: 46rpx;
  138. color: #a6a6a6;
  139. font-size: 24rpx;
  140. }
  141. }
  142. .info_right {
  143. flex: 1;
  144. display: flex;
  145. justify-content: space-around;
  146. align-items: center;
  147. font-size: 28rpx;
  148. img {
  149. width: 42rpx;
  150. height: 43rpx;
  151. }
  152. }
  153. }
  154. }
  155. </style>