hotelDetail.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920
  1. <template>
  2. <view class="hotelDetail">
  3. <zs-header :background="background"></zs-header>
  4. <view class="img-box">
  5. <image class="top-banner" :src="info.pictures[0].path" mode=""></image>
  6. <view class="num-box" @click="goImgList">
  7. {{info.pictures.length}}张
  8. </view>
  9. </view>
  10. <view class="container">
  11. <view class="title-box">
  12. <view class="title">
  13. {{info.chineseName}}
  14. </view>
  15. <view class="star-box">
  16. <image class="star" v-for="i in Math.round(info.star/2)" src="../static/star.png" mode=""></image>
  17. <!-- <image class="star" src="@/static/star.png" mode=""></image>
  18. <image class="star" src="@/static/star.png" mode=""></image>
  19. <image class="star" src="@/static/star.png" mode=""></image>
  20. <image class="star" src="@/static/star.png" mode=""></image>
  21. <image class="star" src="@/static/star.png" mode=""></image> -->
  22. </view>
  23. </view>
  24. <view class="desc-box">
  25. <view class="text">
  26. {{info.debutYear}}年开业
  27. </view>
  28. <view class="text" v-if="info.decorateDate">
  29. {{info.decorateDate}}年装修
  30. </view>
  31. <view class="text">
  32. {{info.roomCount}}间房
  33. </view>
  34. </view>
  35. <view class="address-box">
  36. <view class="address">
  37. {{info.address}}
  38. </view>
  39. <view class="btn-box">
  40. <view class="btn" @click="handleNavigation">
  41. 导航
  42. </view>
  43. <!-- <view class="btn" @click="handleCall">
  44. 电话
  45. </view> -->
  46. </view>
  47. </view>
  48. <view class="choose-box">
  49. <view class="start-box" @click="show = true">
  50. <view class="label">
  51. 入住
  52. </view>
  53. <view class="time-box">
  54. <view class="time">
  55. {{query.checkIn | filterDate('time')}}
  56. </view>
  57. <view class="date">
  58. {{query.checkIn | filterDate('day')}}
  59. </view>
  60. <view class="day">
  61. {{day}}晚
  62. </view>
  63. </view>
  64. </view>
  65. <view class="end-box" @click="show = true">
  66. <view class="label">
  67. 离店
  68. </view>
  69. <view class="time-box">
  70. <view class="time">
  71. {{query.checkOut | filterDate('time')}}
  72. </view>
  73. <view class="date">
  74. {{query.checkOut | filterDate('day')}}
  75. </view>
  76. </view>
  77. </view>
  78. <view class="people-box">
  79. <view class="people" @click="showNum1 = true">
  80. {{query.manNum}}成人
  81. </view>
  82. <view class="child" @click="showNum2 = true">
  83. {{query.childNum}}儿童
  84. </view>
  85. </view>
  86. <image class="jiantou" src="@/static/right.png" mode=""></image>
  87. </view>
  88. <!-- 列表 -->
  89. <zs-list class="store-box" mt="0" @load="loadMore" :status="status">
  90. <view class="hotel-item" v-for="(item,index) in roomList" :key="index">
  91. <view class="box">
  92. <zs-img :src="item.pictures[0].path" width="200rpx" height="200rpx" radius="full" mode="widthFix"></zs-img>
  93. <view class="info">
  94. <view class="title">
  95. {{item.roomNameCn}}
  96. </view>
  97. <view class="desc">
  98. <view class="item" v-if="item.area">
  99. {{item.area}}
  100. </view>
  101. <view class="item" v-if="item.window">
  102. {{item.window |filterWindow}}
  103. </view>
  104. </view>
  105. <!-- <view class="notice">
  106. 早餐不可取消
  107. </view> -->
  108. </view>
  109. <view class="price-box">
  110. <view class="price">
  111. ¥{{item.ratePlanInfo[0].averagePrice}}
  112. </view>
  113. <view class="label">
  114. </view>
  115. </view>
  116. </view>
  117. <view class="type-box">
  118. <view class="type-item" v-for="(i,d) in item.ratePlanInfo" :key="i.id" @click.native="handleImg(item,d)">
  119. <view class="left">
  120. <view class="name-box">
  121. <view class="name">
  122. {{i.meal.breakfast.desc || i.mealInfo.substr(3)}}
  123. </view>
  124. <view class="name">
  125. {{i.cancel.name}}
  126. </view>
  127. </view>
  128. <view class="residue">
  129. 还剩{{i.counts}}间
  130. </view>
  131. </view>
  132. <view class="right">
  133. <view class="price">
  134. ¥{{i.averagePrice}}
  135. </view>
  136. <image class="buy-btn" src="../static/hotel-buy-btn.png" mode="" @click.stop="handleBuy(i,item)"></image>
  137. </view>
  138. </view>
  139. </view>
  140. </view>
  141. </zs-list>
  142. </view>
  143. <view class="intro-box" @click="goIntroduce">
  144. <image class="icon" src="@/static/hotel.png" mode=""></image> 酒店介绍
  145. </view>
  146. <u-popup :show="show1" round="16rpx" mode="bottom" @close="show1 = false">
  147. <view class="content">
  148. <image class="img" :src="roomInfo.pictures[0].path" mode=""></image>
  149. <view class="title">
  150. {{roomInfo.roomNameCn}}
  151. </view>
  152. <view class="desc-box">
  153. <view class="item">
  154. {{roomInfo.area}}
  155. </view>
  156. <view class="item">
  157. {{roomInfo.floor}}
  158. </view>
  159. <view class="item" v-if="roomInfo.window.toString() == 'null'">
  160. {{roomInfo.window |filterWindow}}
  161. </view>
  162. </view>
  163. <view class="box">
  164. <view class="menu-item">
  165. <view class="title">
  166. <image class="icon" src="../static/hotel-icon1.png" mode=""></image>
  167. {{roomInfo.ratePlanInfo[roomIndex].bedInfo || ''}}(加床:{{roomInfo.isExtraBed}})
  168. </view>
  169. <view class="title">
  170. <image class="icon" src="../static/hotel-icon2.png" mode=""></image>
  171. {{roomInfo.ratePlanInfo[roomIndex].mealInfo}}
  172. </view>
  173. </view>
  174. <view class="menu-item" v-for="item in roomFacilities" :key="item.name">
  175. <view class="title">
  176. <image class="icon" src="../static/hotel-icon5.png" mode=""></image>
  177. {{item.name}}
  178. </view>
  179. <view class="item-box">
  180. <view class="item" v-for="i in item.list" :key="i">
  181. {{i}}
  182. </view>
  183. </view>
  184. </view>
  185. <!-- <view class="menu-item">
  186. <view class="title">
  187. <image class="icon" src="../static/hotel-icon4.png" mode=""></image>
  188. 家具设施
  189. </view>
  190. <view class="item-box">
  191. <view class="item">
  192. 书桌
  193. </view>
  194. <view class="item">
  195. 坐卧两用沙发
  196. </view>
  197. <view class="item">
  198. 沙发
  199. </view>
  200. </view>
  201. </view>
  202. <view class="menu-item">
  203. <view class="title">
  204. <image class="icon" src="../static/hotel-icon5.png" mode=""></image>
  205. 便利设施
  206. </view>
  207. <view class="item-box">
  208. <view class="item">
  209. 书桌
  210. </view>
  211. <view class="item">
  212. 坐卧两用沙发
  213. </view>
  214. <view class="item">
  215. 沙发
  216. </view>
  217. </view>
  218. </view> -->
  219. </view>
  220. </view>
  221. </u-popup>
  222. <u-calendar
  223. startText="住店"
  224. endText="离店"
  225. :monthNum="5"
  226. confirmDisabledText="请选择离店日期"
  227. :show="show"
  228. mode="range"
  229. @confirm="confirm"
  230. @close="show = false"
  231. ref="calendar"
  232. :rowHeight="100"
  233. closeOnClickOverlay
  234. color="#EE4320"
  235. :defaultDate="[query.checkIn,query.checkOut]"
  236. >
  237. </u-calendar>
  238. <!-- 选择成人 -->
  239. <u-picker title="成人人数" :show="showNum1" closeOnClickOverlay :columns="columns" @close="showNum1 = false" @cancel="showNum1 = false" @confirm="confirmMan"></u-picker>
  240. <!-- 选择儿童 -->
  241. <u-picker title="儿童人数" :show="showNum2" closeOnClickOverlay :columns="columns" @close="showNum2 = false" @cancel="showNum2 = false" @confirm="confirmChild"></u-picker>
  242. </view>
  243. </template>
  244. <script>
  245. import {getHotelDetail,getRoomList} from '@/api/hotel.js'
  246. import {transformFromWGSToGCJ} from '@/utils/tool.js'
  247. export default {
  248. data() {
  249. return {
  250. background: false,
  251. status:'noMore',
  252. list:10,
  253. show:false,
  254. show1:false,
  255. showNum1:false,
  256. showNum2:false,
  257. info:{pictures:[]},
  258. columns:[
  259. [
  260. 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20
  261. ]
  262. ],
  263. query:{
  264. "checkIn": uni.$u.timeFormat(new Date().getTime(), 'yyyy-mm-dd'),
  265. "checkOut": uni.$u.timeFormat(new Date().getTime()+1000*60*60*24, 'yyyy-mm-dd'),
  266. "childAges": [],
  267. "childNum": 0,
  268. "excludeOta": true,
  269. "hotelId": 0,
  270. "manNum": 1,
  271. "roomNum": 1
  272. },
  273. day:1,
  274. pictures:[],
  275. roomList:[],
  276. roomIndex:0,//当前的房型index
  277. roomFacilities:[],
  278. roomInfo:{
  279. area:'',
  280. bedDescription:'',
  281. broadband:'',
  282. facilities:'',
  283. floor:'',
  284. isExtraBed:'',
  285. noSmoking:'',
  286. pictures:'',
  287. ratePlanInfo:'',
  288. roomId:'',
  289. roomNameCn:'',
  290. wifi:'',
  291. window: 4
  292. }
  293. }
  294. },
  295. filters: {
  296. filterDate: function(value,type) {
  297. let timestamp = new Date(value).getTime()
  298. if(type == 'time'){
  299. return uni.$u.timeFormat(timestamp, 'mm月dd日');
  300. }else if(type == 'day'){
  301. let arr = ['日','一','二','三','四','五','六']
  302. let num = new Date(timestamp).getDay()
  303. return `周${arr[num]}`
  304. }
  305. },
  306. filterWindow:function(val){
  307. if(val === 0){
  308. return '无窗'
  309. }else if(val === 1){
  310. return '部分有窗'
  311. }else if(val === 2){
  312. return '有窗'
  313. }else if(val === 3){
  314. return '不确定'
  315. }else if(val === 4){
  316. return '内窗'
  317. }else if(val === 5){
  318. return '天窗'
  319. }else if(val === 6){
  320. return '封闭窗'
  321. }else if(val === 7){
  322. return '飘窗'
  323. }
  324. },
  325. filterWifi:function(val){
  326. if(val === 1){
  327. return '免费提供'
  328. }else if(val === 2){
  329. return '不提供此服务'
  330. }else if(val === 3){
  331. return '收费提供'
  332. }else if(val === 4){
  333. return '部分收费'
  334. }else if(val === 5){
  335. return '部分提供并收费'
  336. }else if(val === 6){
  337. return '部分能提供并免费'
  338. }else if(val === 7){
  339. return '部分提供并只有部分和收费'
  340. }else if(val === 8){
  341. return '有'
  342. }else if(val === 9){
  343. return '不确定'
  344. }
  345. }
  346. },
  347. methods: {
  348. confirm(e) {
  349. this.show = false
  350. if(e){
  351. this.day = e.length - 1
  352. this.query.checkIn = e[0]
  353. this.query.checkOut = e[this.day]
  354. this.getRoomList()
  355. }
  356. },
  357. confirmMan(val){
  358. console.log(val);
  359. this.showNum1 = false
  360. this.query.manNum = val.value[0]
  361. this.query.roomNum = val.value[0]
  362. this.getRoomList()
  363. },
  364. confirmChild(val){
  365. console.log(val);
  366. this.showNum2 = false
  367. this.query.childNum = val.value[0]
  368. this.getRoomList()
  369. },
  370. goImgList(){
  371. uni.navigateTo({
  372. url:`./hotelImgList?id=${this.query.hotelId}`
  373. })
  374. uni.setStorageSync('hotelImgList',JSON.stringify(this.pictures))
  375. },
  376. handleBuy(i,item){
  377. let that = this
  378. uni.navigateTo({
  379. url:`./makeOut?checkInDate=${this.query.checkIn}&checkOutDate=${this.query.checkOut}&day=${this.day}`,
  380. success: function(res) {
  381. // 通过eventChannel向被打开页面传送数据
  382. let obj = {
  383. manNum:that.query.manNum,
  384. childNum:that.query.childNum,
  385. hotelId:that.query.hotelId,
  386. ratePlanId:i.id,
  387. averagePrice:i.averagePrice,
  388. roomPic:item.pictures[0].path,
  389. hotelPic:that.info.pictures[0].path,
  390. roomNameCn:item.roomNameCn,
  391. area:item.area,
  392. window:item.window,
  393. meal:i.meal.breakfast.desc || i.mealInfo.substr(3),
  394. cancel:i.cancel.name,
  395. }
  396. res.eventChannel.emit('pay', obj)
  397. }
  398. })
  399. },
  400. goIntroduce(){
  401. uni.navigateTo({
  402. url:`./introduce?id=${this.query.hotelId}`
  403. })
  404. },
  405. handleImg(item,index){
  406. this.show1 = true
  407. this.roomInfo = item
  408. this.roomIndex = index
  409. console.log(this.roomInfo);
  410. let obj = {}
  411. item.facilities.map(i=>{
  412. if(obj[i.name]){
  413. obj[i.name].push(i.tmpSubFacilities[0].subName)
  414. }else{
  415. obj[i.name] = [i.tmpSubFacilities[0].subName]
  416. }
  417. })
  418. let list = []
  419. for (let key in obj) {
  420. list.push({name:key,list:obj[key]})
  421. }
  422. console.log(111111111,list);
  423. this.roomFacilities = list
  424. },
  425. loadMore(){},
  426. handleNavigation() {
  427. let {latitude,longitude} = transformFromWGSToGCJ(this.info.latitudeGoogle,this.info.longitudeGoogle)
  428. uni.openLocation({
  429. latitude,
  430. longitude,
  431. name:this.info.storeName,
  432. address:this.info.address,
  433. success: function () {
  434. console.log('success');
  435. }
  436. });
  437. // this.map.openMapApp({
  438. // longitude:this.info.lon,
  439. // latitude:this.info.lat,
  440. // destination:this.info.storeName,
  441. // success(res){
  442. // console.log(res);
  443. // }
  444. // })
  445. },
  446. handleCall() {
  447. if(this.info.tel){
  448. uni.makePhoneCall({
  449. phoneNumber: this.info.tel //仅为示例
  450. });
  451. }else{
  452. uni.showToast({
  453. title:'商家没有预留电话',
  454. icon:'none'
  455. })
  456. }
  457. },
  458. getHotelDetail(hotelId){
  459. getHotelDetail({hotelId}).then(res=>{
  460. if(res.state == 'Success'){
  461. this.info = res.content.data
  462. let obj = {}
  463. this.info.pictures.map(item=>{
  464. if(obj[item.name]){
  465. obj[item.name].push(item.path)
  466. }else{
  467. obj[item.name] = [item.path]
  468. }
  469. })
  470. let list = []
  471. for (let key in obj) {
  472. list.push({name:key,list:obj[key]})
  473. }
  474. this.pictures = list
  475. }
  476. })
  477. },
  478. getRoomList(){
  479. uni.showLoading({
  480. title:'加载中'
  481. })
  482. getRoomList(this.query).then(res=>{
  483. uni.hideLoading()
  484. if(res.state == 'Success'){
  485. this.roomList = res.content.data.roomInfo
  486. console.log(this.roomList);
  487. }
  488. })
  489. }
  490. },
  491. onPageScroll(e) {
  492. if (e.scrollTop >= 50) {
  493. this.background = true
  494. } else {
  495. this.background = false
  496. }
  497. },
  498. onLoad(options) {
  499. this.query.hotelId = options.id
  500. if(options.checkInDate){
  501. this.query.checkIn = options.checkInDate
  502. }
  503. if(options.checkOutDate){
  504. this.query.checkOut = options.checkOutDate
  505. }
  506. this.getHotelDetail(options.id)
  507. this.getRoomList()
  508. }
  509. }
  510. </script>
  511. <style lang="scss" >
  512. .hotelDetail{
  513. padding-bottom: 150rpx;
  514. .img-box{
  515. position: relative;
  516. .top-banner{
  517. width: 750rpx;
  518. height: 382rpx;
  519. vertical-align: bottom;
  520. }
  521. .num-box{
  522. position: absolute;
  523. right: 24rpx;
  524. bottom: 50rpx;
  525. width: 104rpx;
  526. height: 40rpx;
  527. line-height: 40rpx;
  528. text-align: center;
  529. background: rgba(255,255,255,0.5);
  530. border-radius: 26rpx 26rpx 26rpx 26rpx;
  531. font-size: 24rpx;
  532. color: #FFFFFF;
  533. }
  534. }
  535. .container{
  536. position: relative;
  537. z-index: 2;
  538. margin-top: -20rpx;
  539. background: #fff;
  540. border-radius: 16rpx 16rpx 0 0;
  541. padding: 20rpx 24rpx;
  542. .title-box{
  543. display: flex;
  544. align-items: center;
  545. justify-content: space-between;
  546. .title{
  547. font-weight: 600;
  548. font-size: 32rpx;
  549. color: #222222;
  550. width: 550rpx;
  551. white-space: nowrap;
  552. overflow: hidden;
  553. text-overflow: ellipsis;
  554. margin-top: 20rpx;
  555. }
  556. .star-box{
  557. display: flex;
  558. align-items: center;
  559. .star{
  560. width: 21rpx;
  561. height: 17rpx;
  562. margin-left: 3rpx;
  563. }
  564. }
  565. }
  566. .desc-box{
  567. display: flex;
  568. align-items: center;
  569. font-size: 24rpx;
  570. color: #AAAAAA;
  571. margin-top: 20rpx;
  572. .text{
  573. padding-right: 10rpx;
  574. }
  575. .text+.text{
  576. border-left: 2rpx solid #F0F0F0;
  577. padding-left: 10rpx;
  578. }
  579. }
  580. .address-box{
  581. display: flex;
  582. align-items: center;
  583. justify-content: space-between;
  584. width: 702rpx;
  585. height: 140rpx;
  586. background-image: url('@/static/white-map.png');
  587. background-repeat: repeat;
  588. background-size: 100% 140rpx;
  589. box-sizing: border-box;
  590. padding: 36rpx 24rpx;
  591. margin-top: 20rpx;
  592. .address{
  593. font-weight: 600;
  594. font-size: 24rpx;
  595. color: #222222;
  596. line-height: 40rpx;
  597. overflow: hidden;
  598. padding-right: 20rpx;
  599. text-overflow: ellipsis;
  600. /* 弹性伸缩盒子模型显示 */
  601. display: -webkit-box;
  602. /* 限制在一个块元素显示的文本的行数 */
  603. -webkit-line-clamp: 2;
  604. /* 设置或检索伸缩盒对象的子元素的排列方式 */
  605. -webkit-box-orient: vertical;
  606. }
  607. .btn-box{
  608. display: flex;
  609. .btn+.btn{
  610. margin-left: 16rpx;
  611. }
  612. .btn{
  613. width: 120rpx;
  614. height: 52rpx;
  615. line-height: 52rpx;
  616. text-align: center;
  617. background: #E2ECFF;
  618. border-radius: 26rpx 26rpx 26rpx 26rpx;
  619. font-weight: 300;
  620. font-size: 28rpx;
  621. color: #3879F9;
  622. }
  623. }
  624. }
  625. .choose-box{
  626. background: #F9F9F9;
  627. border-radius: 16rpx 16rpx 16rpx 16rpx;
  628. padding: 24rpx;
  629. display: flex;
  630. align-items: center;
  631. position: relative;
  632. margin-top: 20rpx;
  633. .start-box,.end-box{
  634. padding-right: 24rpx;
  635. .label{
  636. font-size: 24rpx;
  637. color: #222222;
  638. }
  639. .time-box{
  640. display: flex;
  641. align-items: center;
  642. margin-top: 16rpx;
  643. .time{
  644. font-weight: 600;
  645. font-size: 28rpx;
  646. color: #222222;
  647. }
  648. .date{
  649. font-size: 24rpx;
  650. color: #222222;
  651. margin-left: 16rpx;
  652. }
  653. .day{
  654. width: 80rpx;
  655. height: 36rpx;
  656. line-height: 36rpx;
  657. text-align: center;
  658. background: #F0F0F0;
  659. border-radius: 18rpx 18rpx 18rpx 18rpx;
  660. font-size: 20rpx;
  661. color: #222222;
  662. margin-left: 24rpx;
  663. }
  664. }
  665. }
  666. .people-box{
  667. padding-left: 24rpx;
  668. border-left: 2rpx solid #F0F0F0;
  669. .people,.child{
  670. font-size: 24rpx;
  671. color: #222222;
  672. }
  673. .child{
  674. margin-top: 16rpx;
  675. }
  676. }
  677. .jiantou{
  678. width: 48rpx;
  679. height: 48rpx;
  680. position: absolute;
  681. top: 50%;
  682. right: 0%;
  683. margin-top: -24rpx;
  684. }
  685. }
  686. .zs-list {
  687. margin-top: 20rpx;
  688. .hotel-item {
  689. .box{
  690. display: flex;
  691. align-items: center;
  692. background: #fff;
  693. border-bottom: 1rpx solid #F0F0F0;
  694. padding: 24rpx 0;
  695. .info{
  696. padding-left: 20rpx;
  697. flex: 1;
  698. .title{
  699. font-weight: 600;
  700. font-size: 36rpx;
  701. color: #222222;
  702. width: 300rpx;
  703. white-space: nowrap;
  704. overflow: hidden;
  705. text-overflow: ellipsis;
  706. margin-top: 20rpx;
  707. }
  708. .desc{
  709. display: flex;
  710. align-items: center;
  711. font-size: 24rpx;
  712. color: #AAAAAA;
  713. margin-top: 20rpx;
  714. .item{
  715. padding-right: 10rpx;
  716. }
  717. .item+.item{
  718. padding-left: 10rpx;
  719. border-left: 2rpx solid #F0F0F0;
  720. }
  721. }
  722. .notice{
  723. font-size: 24rpx;
  724. color: #AAAAAA;
  725. margin-top: 20rpx;
  726. }
  727. }
  728. .price-box{
  729. display: flex;
  730. align-items: center;
  731. .price{
  732. font-weight: 600;
  733. font-size: 36rpx;
  734. color: #FF4D3A;
  735. }
  736. .label{
  737. font-size: 24rpx;
  738. color: #AAAAAA;
  739. }
  740. }
  741. }
  742. }
  743. .type-box{
  744. .type-item+.type-item{
  745. border-top: 1rpx solid #F0F0F0;
  746. }
  747. .type-item{
  748. display: flex;
  749. justify-content: space-between;
  750. align-items: center;
  751. padding: 28rpx 24rpx;
  752. background: #F9F9F9;
  753. .left{
  754. .name-box{
  755. display: flex;
  756. align-items: center;
  757. font-size: 28rpx;
  758. color: #222222;
  759. .name{
  760. padding-right: 20rpx;
  761. }
  762. .name+.name{
  763. padding-left: 20rpx;
  764. border-left: 1rpx solid #222222;
  765. }
  766. }
  767. .residue{
  768. font-size: 24rpx;
  769. color: #FF4D3A;
  770. margin-top: 16rpx;
  771. }
  772. }
  773. .right{
  774. display: flex;
  775. align-items: center;
  776. .price{
  777. font-weight: 600;
  778. font-size: 36rpx;
  779. color: #FF4D3A;
  780. }
  781. .buy-btn{
  782. width: 76rpx;
  783. height: 84rpx;
  784. margin-left: 20rpx;
  785. }
  786. }
  787. }
  788. }
  789. }
  790. }
  791. .intro-box{
  792. position: fixed;
  793. bottom: 0;
  794. left: 0%;
  795. width: 100%;
  796. height: 98rpx;
  797. line-height: 98rpx;
  798. text-align: center;
  799. border-top: 1rpx solid #EEEEEE;
  800. font-size: 28rpx;
  801. color: #222222;
  802. background: #fff;
  803. z-index: 2;
  804. padding-bottom: env(safe-area-inset-bottom);
  805. .icon{
  806. width: 30rpx;
  807. height: 30rpx;
  808. }
  809. }
  810. .content{
  811. max-height: calc(100vh - 362rpx);
  812. overflow: auto;
  813. border-radius: 16rpx;
  814. padding: 24rpx;
  815. box-sizing: border-box;
  816. .img{
  817. width: 100%;
  818. height: 376rpx;
  819. border-radius: 16rpx;
  820. }
  821. .title{
  822. font-weight: 600;
  823. font-size: 32rpx;
  824. color: #222222;
  825. width: 650rpx;
  826. white-space: nowrap;
  827. overflow: hidden;
  828. text-overflow: ellipsis;
  829. margin-top: 24rpx;
  830. }
  831. .desc-box{
  832. display: flex;
  833. flex-wrap: wrap;
  834. margin-top: 24rpx;
  835. .item{
  836. width: 120rpx;
  837. height: 36rpx;
  838. line-height: 36rpx;
  839. text-align: center;
  840. background: #F0F0F0;
  841. border-radius: 8rpx 8rpx 8rpx 8rpx;
  842. font-size: 24rpx;
  843. color: #AAAAAA;
  844. margin-bottom: 20rpx;
  845. }
  846. .item+.item{
  847. margin-left: 12rpx;
  848. }
  849. }
  850. .box{
  851. .menu-item+.menu-item{
  852. border-top: 1rpx solid #F0F0F0;
  853. }
  854. .menu-item{
  855. margin-bottom: 20rpx;
  856. .title{
  857. display: flex;
  858. align-items: center;
  859. .icon{
  860. width: 30rpx;
  861. height: 30rpx;
  862. margin-right: 12rpx;
  863. }
  864. }
  865. .item-box{
  866. display: flex;
  867. flex-wrap: wrap;
  868. margin-top: 20rpx;
  869. .item{
  870. width: 33%;
  871. text-align: center;
  872. font-size: 24rpx;
  873. color: #AAAAAA;
  874. margin-bottom: 20rpx;
  875. }
  876. }
  877. }
  878. }
  879. }
  880. }
  881. </style>