search.vue 9.3 KB

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