search.vue 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386
  1. <template>
  2. <view class="container">
  3. <!-- 轮播图区域 -->
  4. <swiper class="banner" indicator-dots indicator-color="rgba(255, 255, 255, 0.5)" indicator-active-color="#1E7DFB" autoplay circular>
  5. <swiper-item v-for="item in lunbo" :key="item.id">
  6. <img mode="aspectFill" :src="item" />
  7. </swiper-item>
  8. </swiper>
  9. <!-- 游客服务区域 -->
  10. <view class="search">
  11. <view class="search_title">游客服务</view>
  12. <view class="search_box">
  13. <!-- 每一个图标区域 -->
  14. <view class="box_item" v-for="item in iconsList" :key="item.id" @click="handleTip">
  15. <img :src="item.imgUrl"></img>
  16. <view class="item_text">
  17. {{item.text}}
  18. </view>
  19. </view>
  20. </view>
  21. </view>
  22. <!-- 景区导览区域 -->
  23. <view class="trave">
  24. <view class="trave_title">
  25. 景区导览
  26. <view class="trave_she"></view>
  27. </view>
  28. <view class="trave_box">
  29. <!-- 每一个图标区域 -->
  30. <view class="box_item" v-for="item in traveList" :key="item.id" @click="handleTip">
  31. <view style="height: 218rpx;">
  32. <img :src="item.imgUrl"></img>
  33. <view class="trave_dian">
  34. <img mode="aspectFill" src="../../static/search/trave_map.png"></img>
  35. <view class="trave_length">{{item.juli}}</view>
  36. </view>
  37. </view>
  38. <!-- <view>2</view> -->
  39. <view class="item_kuang">
  40. <view class="item_name">{{item.name}}</view>
  41. <view class="item_jibie">{{item.jibie}}</view>
  42. </view>
  43. </view>
  44. </view>
  45. </view>
  46. <!-- 特产推荐区域 -->
  47. <view class="techan">
  48. <view class="trave_title">
  49. 特产推荐
  50. <view class="trave_she"></view>
  51. </view>
  52. <view class="techan_box">
  53. <view class="techan_list" v-for="item in techanList" :key="item.id">
  54. <img :src="item.imgUrl" class="techan_img" mode="aspectFill"></img>
  55. <view>
  56. <text class="techan_name">{{item.name}}</text>
  57. <text class="techan_type">{{item.type}}</text>
  58. <text class="techan_liang">{{item.liang}}</text>
  59. <text class="techan_price">{{item.price}}</text>
  60. </view>
  61. <img src="../../static/search/gouwuche.png" class="techan_jiagou" @click="handleTip"></img>
  62. </view>
  63. </view>
  64. </view>
  65. </view>
  66. </template>
  67. <script>
  68. export default {
  69. data() {
  70. return {
  71. //轮播图
  72. lunbo:['https://jtishfw.ncjti.edu.cn/homestay/banner/7.png',
  73. 'https://jtishfw.ncjti.edu.cn/homestay/banner/8.jpg',
  74. 'https://jtishfw.ncjti.edu.cn/homestay/banner/9.png'],
  75. // 图标数组
  76. iconsList:[
  77. {
  78. id:1,
  79. imgUrl:'../../static/search/icon.png',
  80. text:'投诉建议'
  81. },
  82. {
  83. id:2,
  84. imgUrl:'../../static/search/icon2.png',
  85. text:'租车服务'
  86. },{
  87. id:3,
  88. imgUrl:'../../static/search/icon3.png',
  89. text:'车位查询'
  90. },{
  91. id:4,
  92. imgUrl:'../../static/search/icon4.png',
  93. text:'厕所查询'
  94. },{
  95. id:5,
  96. imgUrl:'../../static/search/icon5.png',
  97. text:'寻找向导'
  98. },{
  99. id:6,
  100. imgUrl:'../../static/search/icon6.png',
  101. text:'服务热线'
  102. },{
  103. id:7,
  104. imgUrl:'../../static/search/icon7.png',
  105. text:'服务热线'
  106. },{
  107. id:8,
  108. imgUrl:'../../static/search/icon8.png',
  109. text:'招商平台'
  110. }
  111. ],
  112. // 景区导览
  113. traveList:[
  114. {id:1,
  115. imgUrl:'https://jtishfw.ncjti.edu.cn/homestay/scenicguide/中部梦幻城.png',juli:'45.96km',name:'中部梦幻城',jibie:'4A'},
  116. {id:2,imgUrl:'https://jtishfw.ncjti.edu.cn/homestay/scenicguide/中华传统文化园.png',juli:'45.96km',name:'中华传统文化园',jibie:'4A'},
  117. {id:3,imgUrl:'https://jtishfw.ncjti.edu.cn/homestay/scenicguide/靖安宝峰寺.png',juli:'45.96km',name:'靖安宝峰寺',jibie:'4A'},
  118. {id:4,imgUrl:'https://jtishfw.ncjti.edu.cn/homestay/scenicguide/九岭森林温泉度假村.png',juli:'45.96km',name:'九岭森林温泉度假村',jibie:'4A'},
  119. ],
  120. // 特产
  121. techanList:[
  122. {id:1,imgUrl:'https://jtishfw.ncjti.edu.cn/homestay/productpicture/靖安木耳.png',name:'靖安木耳',type:'手工产品 营养丰富',liang:'500kg',price:'¥200',},
  123. {id:1,imgUrl:'https://jtishfw.ncjti.edu.cn/homestay/productpicture/靖安白茶.jpg',name:'靖安白茶',type:'经典茶品 营养丰富',liang:'500kg',price:'¥400',},
  124. {id:1,imgUrl:'https://jtishfw.ncjti.edu.cn/homestay/productpicture/靖安椪柑.jpg',name:'靖安椪柑',type:'汁水丰富 营养丰富',liang:'500kg',price:'¥80',},
  125. {
  126. id:1,
  127. imgUrl:'https://jtishfw.ncjti.edu.cn/homestay/productpicture/猕猴桃糕.jpg',
  128. name:'猕猴桃糕',
  129. type:'手工制作 回味无穷',
  130. liang:'500kg',
  131. price:'¥50',}
  132. ],
  133. }
  134. },
  135. methods:{
  136. handleTip(){
  137. uni.showToast({
  138. title: '功能开发中',
  139. icon: 'none'
  140. })
  141. }
  142. }
  143. }
  144. </script>
  145. <style lang="scss" scoped>
  146. .container {
  147. display: flex;
  148. flex-direction: column;
  149. min-height: 100vh;
  150. background-color: #ebeced;
  151. .banner {
  152. margin-top: 20rpx;
  153. width: 750rpx;
  154. height: 326rpx;
  155. img {
  156. width: 100%;
  157. height: 100%;
  158. }
  159. }
  160. .search {
  161. margin: 20rpx 0;
  162. width: 750rpx;
  163. height: 475rpx;
  164. background-color: #fff;
  165. .search_title {
  166. padding: 0 30rpx;
  167. height: 93rpx;
  168. line-height: 93rpx;
  169. font-size: 32rpx;
  170. font-weight: bold;
  171. border-bottom: 1rpx solid #e6e6e6;
  172. }
  173. .search_box {
  174. display: flex;
  175. flex-wrap: wrap;
  176. padding: 0 30rpx;
  177. height: 382rpx;
  178. .box_item {
  179. display: flex;
  180. flex-direction: column;
  181. justify-content: center;
  182. align-items: center;
  183. width: 25%;
  184. height: 190rpx;
  185. image {
  186. width: 78rpx;
  187. height: 78rpx;
  188. }
  189. .item_text{
  190. margin-top: 13rpx;
  191. font-size: 28rpx;
  192. }
  193. }
  194. }
  195. }
  196. // 景区导览
  197. .trave {
  198. margin: 20rpx 0;
  199. width: 750rpx;
  200. height: 869rpx;
  201. background-color: #fff;
  202. .trave_title {
  203. padding: 0 30rpx;
  204. height: 93rpx;
  205. line-height: 93rpx;
  206. font-size: 32rpx;
  207. font-weight: bold;
  208. border-bottom: 1rpx solid #e6e6e6;
  209. }
  210. .trave_she{
  211. margin: -40px 0 0 634rpx;
  212. width: 67rpx;
  213. height: 67rpx;
  214. background-image: url('../../static/search/trave_she.png');
  215. background-size: 100%;
  216. }
  217. .trave_box {
  218. display: flex;
  219. flex-wrap: wrap;
  220. padding: 32rpx 10rpx;
  221. height: 766rpx;
  222. .box_item {
  223. display: flex;
  224. flex-direction: column;
  225. justify-content: center;
  226. align-items: center;
  227. height: 331rpx;
  228. width: 50%;
  229. image {
  230. width: 335rpx;
  231. height: 218rpx;
  232. z-index: 2;
  233. }
  234. .trave_dian{
  235. width: 109rpx;
  236. height: 37rpx;
  237. border-radius: 73rpx;
  238. background: rgba(0, 0, 0, 0.4);
  239. margin: -57rpx 0 0 213rpx;
  240. z-index: 3;
  241. position: absolute;
  242. image {
  243. width: 26rpx;
  244. height: 26rpx;
  245. margin: 6rpx 0 0 8rpx;
  246. float: left;
  247. }
  248. .trave_length{
  249. font-size: 16rpx;
  250. line-height: 23rpx;
  251. color: rgba(255, 255, 255, 1);
  252. margin: 10rpx 0 0 8rpx;
  253. }
  254. }
  255. .item_kuang{
  256. width: 335rpx;
  257. height: 113rpx;
  258. background: rgba(255, 255, 255, 1);
  259. box-shadow: 0px 0px 7rpx rgba(0, 0, 0, 0.25);
  260. font-size: 28rpx;
  261. .item_name{
  262. margin: 11rpx 0 0 17rpx;
  263. line-height: 41rpx;
  264. color: rgba(0, 0, 0, 1);
  265. }
  266. .item_jibie{
  267. margin: 11rpx 0 0 17rpx;
  268. width: 48rpx;
  269. height: 30rpx;
  270. border-radius: 136rpx;
  271. background: rgba(255, 223, 117, 1);
  272. font-size: 22rpx;
  273. line-height: 30rpx;
  274. color: rgba(189, 120, 17, 1);
  275. text-align: center;
  276. }
  277. }
  278. }
  279. }
  280. }
  281. // 特产推荐
  282. .techan{
  283. margin: 20rpx 0;
  284. width: 750rpx;
  285. height: 110%;
  286. background-color: #fff;
  287. .trave_title {
  288. padding: 0 30rpx;
  289. height: 93rpx;
  290. line-height: 93rpx;
  291. font-size: 32rpx;
  292. font-weight: bold;
  293. border-bottom: 1rpx solid #e6e6e6;
  294. }
  295. .trave_she{
  296. margin: -40px 0 0 634rpx;
  297. width: 67rpx;
  298. height: 67rpx;
  299. background-image: url('../../static/search/trave_she.png');
  300. background-size: 100%;
  301. }
  302. .techan_box{
  303. display: flex;
  304. flex-wrap: wrap;
  305. margin-left: 30rpx;
  306. height: 110%;
  307. .techan_list{
  308. display: flex;
  309. height: 231rpx;
  310. margin-top: 30rpx;
  311. border-bottom: 1px solid #e6e6e6;
  312. .techan_img{
  313. width: 200rpx;
  314. height: 200rpx;
  315. }
  316. .techan_name{
  317. display: flex;
  318. margin: 0 0 0 23rpx;
  319. font-size: 28rpx;
  320. font-weight: 500;
  321. line-height: 41rpx;
  322. color: rgba(0, 0, 0, 1);
  323. }
  324. .techan_type{
  325. display: flex;
  326. margin: 11rpx 0 0 23rpx;
  327. font-size: 24rpx;
  328. line-height: 35rpx;
  329. color: rgba(166, 166, 166, 1);
  330. }
  331. .techan_liang{
  332. display: flex;
  333. margin: 14rpx 0 0 28rpx;
  334. width: 61rpx;
  335. height: 32rpx;
  336. border-radius: 4rpx;
  337. background: rgba(230, 230, 230, 1);
  338. font-size: 20rpx;
  339. line-height: 32rpx;
  340. color: rgba(166, 166, 166, 1);
  341. text-align: center;
  342. }
  343. .techan_price{
  344. display: flex;
  345. margin: 19rpx 0 0 23rpx;
  346. font-size: 36rpx;
  347. font-weight: 500;
  348. line-height: 52rpx;
  349. color: rgba(255, 87, 51, 1);
  350. }
  351. .techan_jiagou{
  352. margin: 143rpx 0 0 207rpx;
  353. width: 62rpx;
  354. height: 62rpx;
  355. }
  356. }
  357. }
  358. }
  359. }
  360. </style>