Showing
9 changed files
with
911 additions
and
381 deletions
| @@ -21,6 +21,7 @@ Page({ | @@ -21,6 +21,7 @@ Page({ | ||
| 21 | is_time: false, //是否继续执行 | 21 | is_time: false, //是否继续执行 |
| 22 | timeList: [], //定时器列表 | 22 | timeList: [], //定时器列表 |
| 23 | timers: null, | 23 | timers: null, |
| 24 | + distance:'', | ||
| 24 | }, | 25 | }, |
| 25 | stopWaiting() { | 26 | stopWaiting() { |
| 26 | for (var i = 0; i < this.data.timeList.length; i++) { | 27 | for (var i = 0; i < this.data.timeList.length; i++) { |
| @@ -34,7 +35,7 @@ Page({ | @@ -34,7 +35,7 @@ Page({ | ||
| 34 | this.setData({ | 35 | this.setData({ |
| 35 | id: options.id | 36 | id: options.id |
| 36 | }) | 37 | }) |
| 37 | - console.log(this.data.id); | 38 | + console.log('options',{...options}); |
| 38 | this.getDetail('1') | 39 | this.getDetail('1') |
| 39 | }, | 40 | }, |
| 40 | 41 | ||
| @@ -57,17 +58,21 @@ Page({ | @@ -57,17 +58,21 @@ Page({ | ||
| 57 | }).then(res => { | 58 | }).then(res => { |
| 58 | let detail = res.data; | 59 | let detail = res.data; |
| 59 | let exp_date = detail.exp_date ? JSON.parse(detail.exp_date) : ''; | 60 | let exp_date = detail.exp_date ? JSON.parse(detail.exp_date) : ''; |
| 61 | + let use = detail.activity.use ? JSON.parse(detail.activity.use) : ''; | ||
| 62 | + use.images = use && use.images ? JSON.parse(use.images) : ''; | ||
| 60 | let date = Date.now() * 1; | 63 | let date = Date.now() * 1; |
| 61 | if (date > detail.etime) { | 64 | if (date > detail.etime) { |
| 62 | detail.is_expire = '0'; | 65 | detail.is_expire = '0'; |
| 63 | } else { | 66 | } else { |
| 64 | detail.is_expire = '1'; | 67 | detail.is_expire = '1'; |
| 65 | } | 68 | } |
| 69 | + detail.use = use; | ||
| 66 | this.setData({ | 70 | this.setData({ |
| 67 | detail, | 71 | detail, |
| 68 | exp_date | 72 | exp_date |
| 69 | }) | 73 | }) |
| 70 | - console.log('is_examine', detail.is_examine); | 74 | + console.log('detail', {...detail}); |
| 75 | + console.log('exp_date', {...exp_date}); | ||
| 71 | if (detail.is_examine == '0') { | 76 | if (detail.is_examine == '0') { |
| 72 | this.setData({ | 77 | this.setData({ |
| 73 | is_time: true, | 78 | is_time: true, |
| @@ -122,6 +127,7 @@ Page({ | @@ -122,6 +127,7 @@ Page({ | ||
| 122 | }, | 127 | }, |
| 123 | // 获取商家信息 | 128 | // 获取商家信息 |
| 124 | getSeller(sid) { | 129 | getSeller(sid) { |
| 130 | + let that = this; | ||
| 125 | App.Customer.GetSellerDetail({ | 131 | App.Customer.GetSellerDetail({ |
| 126 | sid, | 132 | sid, |
| 127 | }).then(res => { | 133 | }).then(res => { |
| @@ -138,13 +144,45 @@ Page({ | @@ -138,13 +144,45 @@ Page({ | ||
| 138 | }) | 144 | }) |
| 139 | cateStr = cateStr.join('/') | 145 | cateStr = cateStr.join('/') |
| 140 | } | 146 | } |
| 147 | + let distance = ''; | ||
| 148 | + let latitude = ''; | ||
| 149 | + let longitude = ''; | ||
| 141 | let sellerObj = { | 150 | let sellerObj = { |
| 142 | sellername: data.sellername, | 151 | sellername: data.sellername, |
| 152 | + sid: data.id, | ||
| 143 | seller_image: data.seller_image, | 153 | seller_image: data.seller_image, |
| 144 | real_address: data.real_address, | 154 | real_address: data.real_address, |
| 145 | - cateStr | 155 | + is_parking: data.is_parking, |
| 156 | + average: data.average, | ||
| 157 | + is_online_reserve: data.is_online_reserve, | ||
| 158 | + phone: data.phone, | ||
| 159 | + cateStr, | ||
| 146 | } | 160 | } |
| 147 | - | 161 | + wx.getLocation({ |
| 162 | + type: 'wgs84', // 返回可以用于 wx.openLocation 的经纬度 | ||
| 163 | + success: function (res) { | ||
| 164 | + latitude = res.latitude; // 纬度 | ||
| 165 | + longitude = res.longitude; // 经度 | ||
| 166 | + console.log(`当前的纬度: ${latitude}, 当前的经度: ${longitude}`); | ||
| 167 | + if (latitude && longitude) { | ||
| 168 | + console.log('dddddd',latitude, longitude, data.lat, data.long); | ||
| 169 | + distance = that.getDistance(latitude, longitude, data.lat, data.long); | ||
| 170 | + console.log('distancedistancedistance'); | ||
| 171 | + distance = parseInt(distance) | ||
| 172 | + if (distance > 1000) { | ||
| 173 | + distance = (distance / 1000).toFixed(2) + 'km' | ||
| 174 | + } else { | ||
| 175 | + distance += 'm'; | ||
| 176 | + } | ||
| 177 | + that.setData({ | ||
| 178 | + distance | ||
| 179 | + }) | ||
| 180 | + } | ||
| 181 | + }, | ||
| 182 | + fail: function (err) { | ||
| 183 | + console.error('获取位置失败:', err); | ||
| 184 | + } | ||
| 185 | + }); | ||
| 148 | this.setData({ | 186 | this.setData({ |
| 149 | sellerObj | 187 | sellerObj |
| 150 | }) | 188 | }) |
| @@ -153,6 +191,12 @@ Page({ | @@ -153,6 +191,12 @@ Page({ | ||
| 153 | }); | 191 | }); |
| 154 | }) | 192 | }) |
| 155 | }, | 193 | }, |
| 194 | + // 拨打电话 | ||
| 195 | + callPhone() { | ||
| 196 | + wx.makePhoneCall({ | ||
| 197 | + phoneNumber: this.data.sellerObj.phone | ||
| 198 | + }) | ||
| 199 | + }, | ||
| 156 | // 申请退款 | 200 | // 申请退款 |
| 157 | subscribeDrawback() { | 201 | subscribeDrawback() { |
| 158 | clearTimeout(this.timers) | 202 | clearTimeout(this.timers) |
| @@ -167,6 +211,22 @@ Page({ | @@ -167,6 +211,22 @@ Page({ | ||
| 167 | url: '/pages/reserve/shopHome?id=' + this.data.detail.sellerid | 211 | url: '/pages/reserve/shopHome?id=' + this.data.detail.sellerid |
| 168 | }) | 212 | }) |
| 169 | }, | 213 | }, |
| 214 | + // 计算2点之间的距离 | ||
| 215 | + getDistance(lat1, lon1, lat2, lon2) { | ||
| 216 | + const R = 6371e3; // 地球半径(米) | ||
| 217 | + // 将经纬度转换为弧度 | ||
| 218 | + const φ1 = lat1 * Math.PI / 180; // 纬度1 | ||
| 219 | + const φ2 = lat2 * Math.PI / 180; // 纬度2 | ||
| 220 | + const Δφ = (lat2 - lat1) * Math.PI / 180; // 纬度差 | ||
| 221 | + const Δλ = (lon2 - lon1) * Math.PI / 180; // 经度差 | ||
| 222 | + // Haversine 公式 | ||
| 223 | + const a = Math.sin(Δφ / 2) * Math.sin(Δφ / 2) + | ||
| 224 | + Math.cos(φ1) * Math.cos(φ2) * | ||
| 225 | + Math.sin(Δλ / 2) * Math.sin(Δλ / 2); | ||
| 226 | + const c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a)); | ||
| 227 | + const distance = R * c; // 计算距离(米) | ||
| 228 | + return distance; // 返回距离 | ||
| 229 | + }, | ||
| 170 | /** | 230 | /** |
| 171 | * 生命周期函数--监听页面隐藏 | 231 | * 生命周期函数--监听页面隐藏 |
| 172 | */ | 232 | */ |
| 1 | <!--pack-activity/pack/examineCertificate.wxml 二维码验券页面--> | 1 | <!--pack-activity/pack/examineCertificate.wxml 二维码验券页面--> |
| 2 | <wxs src="../../utils/util.wxs" module="util" /> | 2 | <wxs src="../../utils/util.wxs" module="util" /> |
| 3 | <nav>{{detail.sellername}}</nav> | 3 | <nav>{{detail.sellername}}</nav> |
| 4 | -<view class="box_wrap"> | ||
| 5 | - <view class="top_box"> | ||
| 6 | - <view class="discount_name font40r"> | ||
| 7 | - {{detail.activity.aname}} | ||
| 8 | - </view> | ||
| 9 | - <view class="shop_name font28r"> | ||
| 10 | - {{detail.sellername}} | ||
| 11 | - </view> | ||
| 12 | - <!-- is_type 1店铺券 2个人券 是店铺券 && 需要验券--> | ||
| 13 | - <view class="lineBox" wx:if="{{detail.activity.is_type=='1' && detail.activity.is_examine=='1'}}"> | ||
| 14 | - <view class="line" ></view> | ||
| 15 | - <image wx:if="{{detail.is_examine=='1'}}" class="group" src="https://qn.colorcun.com/WechatIMG713.png" mode="" /> | ||
| 16 | - <image wx:if="{{detail.is_expire=='1'}}" class="group" src="https://qn.colorcun.com/WechatIMG714.png" mode="" /> | ||
| 17 | - </view> | ||
| 18 | - <image wx:if="{{detail.qrcode && detail.activity.is_type=='1' && detail.activity.is_examine=='1'}}" class="qcode" src="{{detail.qrcode}}" mode="" /> | ||
| 19 | - <view class="orderNumber font28r" wx:if="{{detail.activity.is_type=='1' && detail.activity.is_examine=='1'}}"> | ||
| 20 | - {{detail.order_no}} | ||
| 21 | - </view> | ||
| 22 | - </view> | ||
| 23 | - <view class="center_box"> | ||
| 24 | - <view class="info" wx:if="{{detail.activity.desc}}"> | ||
| 25 | - <view class="info_left font32r"> | ||
| 26 | - 券要求 | ||
| 27 | - </view> | ||
| 28 | - <view class="info_right font32r"> | ||
| 29 | - {{detail.activity.desc}} | ||
| 30 | - </view> | ||
| 31 | - </view> | ||
| 32 | - <view class="info" wx:if="{{detail.stime}}"> | ||
| 33 | - <view class="info_left font32r"> | ||
| 34 | - 有效期从 | ||
| 35 | - </view> | ||
| 36 | - <view class="info_right font32r"> | ||
| 37 | - {{util.unixtoTime(detail.stime,'YYYY-MM-DD')}} | ||
| 38 | - </view> | ||
| 39 | - </view> | ||
| 40 | - <view class="info"> | ||
| 41 | - <view class="info_left font32r" wx:if="{{detail.etime}}"> | ||
| 42 | - 有效期至 | ||
| 43 | - </view> | ||
| 44 | - <view class="info_right font32r"> | ||
| 45 | - {{util.unixtoTime(detail.etime,'YYYY-MM-DD')}} | ||
| 46 | - </view> | ||
| 47 | - </view> | ||
| 48 | - <view wx:if="{{exp_date.is_none=='1' || exp_date.is_none===true}}" class="info"> | ||
| 49 | - <view class="info_left font32r"> | ||
| 50 | - 使用限制: | ||
| 51 | - </view> | ||
| 52 | - <view class="info_right font32r"> | ||
| 53 | - 无限制 | ||
| 54 | - </view> | ||
| 55 | - </view> | ||
| 56 | - <view wx:if="{{exp_date.is_birthday=='1' || exp_date.is_birthday===true}}" class="info"> | ||
| 57 | - <view class="info_left font32r"> | ||
| 58 | - 使用限制: | ||
| 59 | - </view> | ||
| 60 | - <view class="info_right font32r"> | ||
| 61 | - 会员生日当天 | ||
| 62 | - </view> | ||
| 63 | - </view> | ||
| 64 | - <view wx:if="{{exp_date.is_week=='1' || exp_date.is_week===true}}" class="week"> | ||
| 65 | - <view class="week_top"> | ||
| 66 | - <view class="week_left font32r"> | ||
| 67 | - 充值日期限制: | ||
| 68 | - </view> | ||
| 69 | - <view class="texts font32r"> | ||
| 70 | - 每周指定日期餐段可用 | ||
| 71 | - </view> | ||
| 72 | - </view> | ||
| 73 | - <text class="dateList texts font30r"> | ||
| 74 | - {{exp_date.week_show?exp_date.week_show+'可用':''}} | ||
| 75 | - </text> | ||
| 76 | - </view> | ||
| 77 | - <view class="info info1" wx:if="{{detail.activity.explain}}"> | ||
| 78 | - <view class="info_left font32r"> | ||
| 79 | - 券说明 | ||
| 80 | - </view> | ||
| 81 | - </view> | ||
| 82 | - <view class="explain_news">{{detail.activity.explain}}</view> | ||
| 83 | - </view> | ||
| 84 | - <view class="btns" wx:if="{{detail.is_examine!='1' && detail.is_expire!='1' && detail.price!='0'}}"> | ||
| 85 | - <button class="font24r" plain="true" bindtap="subscribeDrawback">申请退费</button> | ||
| 86 | - </view> | ||
| 87 | - <view class="canteen_box" bindtap="getReserve"> | ||
| 88 | - <image src="{{sellerObj.seller_image}}" mode="heightFix" /> | ||
| 89 | - <view class="info_right"> | ||
| 90 | - <view class="font36r sellerName">{{sellerObj.sellername}}</view> | ||
| 91 | - <view class="font24r" wx:if="{{sellerObj.cateStr}}">{{sellerObj.cateStr}}</view> | ||
| 92 | - <view class="font28r" wx:if="{{sellerObj.real_address}}">{{sellerObj.real_address}}</view> | ||
| 93 | - </view> | ||
| 94 | - </view> | ||
| 95 | - <view class="bottom_box"> | ||
| 96 | - <view class="font24r">温馨提示:</view> | ||
| 97 | - <view class="font24r">1、到店消费时,请您向餐厅出示该二维码。</view> | ||
| 98 | - <view class="font24r">2、从<text class="bold_box">周到安排</text>微信小程序,我的-卡券,可以找到您的卡券。</view> | ||
| 99 | - <!-- <view class="font24r">3、您也可以关注<text class="bold_box">周到安排</text>公众号,公众号菜单“优惠券”获取优惠券更多信息。</view> --> | ||
| 100 | - <view class="font28r publicity" bindtap="wananchi">关注<text class="bold_box">周到安排</text>公众号,及时获取更多优惠券动态<view class="more" style="margin-left: 20rpx;"></view> | ||
| 101 | - </view> | ||
| 102 | - </view> | 4 | +<view class="top_box"> |
| 5 | + <image src="https://qn.colorcun.com/voucherIcon1.png" mode="" /> | ||
| 6 | + <view class="texts"> | ||
| 7 | + <view class="font32r textName">{{detail.use.is_discount=='1'?'店铺折扣券':''}}{{detail.use.is_dish=='1'?'店铺菜品券':''}}{{detail.use.is_cash=='1'?'店铺代金券':''}}</view> | ||
| 8 | + <view class="font24r threshold"> | ||
| 9 | + <block wx:if="{{detail.use.is_cash=='1'}}"> | ||
| 10 | + ¥<text class="priceText">{{detail.price}}</text> | ||
| 11 | + </block> | ||
| 12 | + <block wx:if="{{detail.use.is_discount=='1'}}"> | ||
| 13 | + <text class="priceText">{{detail.use.discount}}折</text> | ||
| 14 | + </block> | ||
| 15 | + <text class="font24r" wx:if="{{detail.use.is_dish!='1' && detail.activity.desc}}">{{detail.activity.desc}}</text> | ||
| 16 | + <text class="priceText" wx:if="{{detail.use.is_dish=='1'}}">{{detail.activity.aname}}</text> | ||
| 17 | + </view> | ||
| 18 | + </view> | ||
| 19 | +</view> | ||
| 20 | +<view class="center_box qrcodeBox"> | ||
| 21 | + <view class="infoText font28r">请向店员出示二维码,用于核销确认</view> | ||
| 22 | + <image wx:if="{{detail.qrcode && detail.activity.is_type=='1' && detail.activity.is_examine=='1'}}" class="qcode" src="{{detail.qrcode}}" mode="" /> | ||
| 23 | + <view class="infoText font28r" wx:if="{{detail.activity.is_type=='1' && detail.activity.is_examine=='1'}}"> | ||
| 24 | + {{detail.order_no}} | ||
| 25 | + </view> | ||
| 26 | +</view> | ||
| 27 | + | ||
| 28 | +<view class="center_box" wx:if="{{detail.use && (detail.use.dish || detail.use.images.length>0)}}"> | ||
| 29 | + <view class="centerMain"> | ||
| 30 | + <view class="title"> | ||
| 31 | + <image src="https://qn.colorcun.com/voucherUnion_1.png" mode="" /> | ||
| 32 | + <text class="font28r">菜品</text> | ||
| 33 | + </view> | ||
| 34 | + <view class="info font24r">{{detail.use.dish}}</view> | ||
| 35 | + <image class="useImg" wx:for="{{detail.use.images}}" src="{{item}}" mode="" /> | ||
| 36 | + </view> | ||
| 37 | +</view> | ||
| 38 | +<view class="center_box"> | ||
| 39 | + <view class="centerMain"> | ||
| 40 | + <view class="title"> | ||
| 41 | + <image src="https://qn.colorcun.com/voucherUnion_1.png" mode="" /> | ||
| 42 | + <text class="font28r">有效期</text> | ||
| 43 | + </view> | ||
| 44 | + <view class="info font24r"><text>活动期限</text>{{util.unixtoTime(detail.stime,'YYYY-MM-DD')}}<text>至</text>{{util.unixtoTime(detail.etime,'YYYY-MM-DD')}}</view> | ||
| 45 | + </view> | ||
| 46 | + <view class="centerMain"> | ||
| 47 | + <view class="title"> | ||
| 48 | + <image src="https://qn.colorcun.com/voucherUnion_2.png" mode="" /> | ||
| 49 | + <text class="font28r">可用日期</text> | ||
| 50 | + </view> | ||
| 51 | + <view class="mLeft"> | ||
| 52 | + <text wx:if="{{exp_date.is_week=='1' || exp_date.is_week===true}}" class="info font24r">{{exp_date.week_show?exp_date.week_show:''}}</text> | ||
| 53 | + <view wx:if="{{exp_date.is_none=='1' || exp_date.is_none===true}}" class="info font24r">无限制</view> | ||
| 54 | + </view> | ||
| 55 | + </view> | ||
| 56 | + <view class="centerMain" wx:if="{{exp_date.is_birthday=='1' || exp_date.is_birthday===true}}"> | ||
| 57 | + <view class="title"> | ||
| 58 | + <image src="https://qn.colorcun.com/voucherUnion_2.png" mode="" /> | ||
| 59 | + <text class="font28r">使用限制</text> | ||
| 60 | + </view> | ||
| 61 | + <view class="info font24r">会员生日当天</view> | ||
| 62 | + </view> | ||
| 63 | + <view class="centerMain" wx:if="{{detail.activity.explain}}"> | ||
| 64 | + <view class="title"> | ||
| 65 | + <image src="https://qn.colorcun.com/voucherUnion_5.png" mode="" /> | ||
| 66 | + <text class="font28r">其他说明</text> | ||
| 67 | + </view> | ||
| 68 | + <view class="info font24r">{{detail.activity.explain}}</view> | ||
| 69 | + </view> | ||
| 70 | +</view> | ||
| 71 | +<view class="seller_data"> | ||
| 72 | + <image src="{{sellerObj.seller_image}}" mode="aspectFill" /> | ||
| 73 | + <view class="seller_box"> | ||
| 74 | + <view class="infos"> | ||
| 75 | + <view class="info_name font32r">{{sellerObj.sellername}}</view> | ||
| 76 | + <view class="park font24r" wx:if="{{sellerObj.is_parking}}">可停车</view> | ||
| 77 | + </view> | ||
| 78 | + <view class="infos infos1"> | ||
| 79 | + <view class="dish font24r">{{sellerObj.cateStr}}</view> | ||
| 80 | + <view class="averageText font24r" wx:if="{{sellerObj.average && sellerObj.average>0}}">人均¥{{sellerObj.average}}</view> | ||
| 81 | + <view class="marTop font24r">{{distance}}</view> | ||
| 82 | + </view> | ||
| 83 | + <!-- <view class="bottom_btns"> | ||
| 84 | + <view class="book font24r">朋友订过</view> | ||
| 85 | + <view class="book font24r">我订过</view> | ||
| 86 | + <view class="book font24r">我去过</view> | ||
| 87 | + <view class="book font24r">我有券</view> | ||
| 88 | + </view> --> | ||
| 89 | + </view> | ||
| 90 | +</view> | ||
| 91 | +<view class="bottom_box_wrap"> | ||
| 92 | + <view class="bottom_box"> | ||
| 93 | + <view class="font24r">温馨提示:</view> | ||
| 94 | + <view class="font24r">到店消费时,请您扫描商家二维码付款时,可以直接识别并使用优惠券</view> | ||
| 95 | + <view class="font24r">2、从<text class="bold_box">周到安排</text>微信小程序,<text class="bold_box">“我的-卡券”</text>中,可以找到您的卡券。</view> | ||
| 96 | + <view class="font24r">3、您也可以关注<text class="bold_box">周到安排</text>公众号,获取更多优惠券信息</view> | ||
| 97 | + <view class="font28r publicity" bindtap="wananchi">关注<text class="bold_box">周到安排</text>公众号,及时获取更多优惠券动态<view class="more" style="margin-left: 20rpx;"></view> | ||
| 98 | + </view> | ||
| 99 | + </view> | ||
| 100 | +</view> | ||
| 101 | +<view class="sharewidth" wx:if="{{(detail.is_examine!='1' && detail.is_expire!='1' && detail.price!='0') || (sellerObj.is_online_reserve == '1')}}"> | ||
| 102 | + <view class="btns"> | ||
| 103 | + <view wx:if="{{detail.is_examine!='1' && detail.is_expire!='1' && detail.price!='0'}}" class="btn1 font36r" bindtap="subscribeDrawback">申请退款</view> | ||
| 104 | + <view class="btn font36r" wx:if="{{sellerObj.is_online_reserve == '1'}}"> | ||
| 105 | + <navigator url="/pages/reserve/reserve?id={{sellerObj.sid}}&activeTab=reserve" class="book-item-font second-book-button flex-cc font30r" style="position: relative;">预订包间</navigator> | ||
| 106 | + </view> | ||
| 107 | + <view class="btn font36r" wx:if="{{sellerObj.is_online_reserve == '0' && sellerObj.phone}}"> | ||
| 108 | + <view bindtap="callPhone">预订包间</view> | ||
| 109 | + </view> | ||
| 110 | + </view> | ||
| 103 | </view> | 111 | </view> |
| 1 | /* pack-activity/pack/examineCertificate.wxss */ | 1 | /* pack-activity/pack/examineCertificate.wxss */ |
| 2 | -.box_wrap { | ||
| 3 | - display: flex; | ||
| 4 | - padding: 0 40rpx 30rpx 40rpx; | ||
| 5 | - flex-direction: column; | ||
| 6 | - align-items: center; | ||
| 7 | - justify-content: center; | 2 | + |
| 3 | +page { | ||
| 4 | + background: #F5F5F5; | ||
| 8 | } | 5 | } |
| 9 | 6 | ||
| 10 | .top_box { | 7 | .top_box { |
| 11 | - border-radius: 16rpx; | ||
| 12 | - background: #f8f9fd; | ||
| 13 | - width: 100%; | ||
| 14 | - padding: 48rpx 0 42rpx 0; | ||
| 15 | - display: flex; | ||
| 16 | - align-items: center; | ||
| 17 | - justify-content: center; | ||
| 18 | - flex-direction: column; | 8 | + background: #fff; |
| 9 | + display: flex; | ||
| 10 | + padding: 20rpx 40rpx; | ||
| 11 | + margin-bottom: 2rpx; | ||
| 19 | } | 12 | } |
| 20 | 13 | ||
| 21 | -.lineBox { | ||
| 22 | - position: relative; | ||
| 23 | - width: 92%; | ||
| 24 | - height: 4rpx; | ||
| 25 | - margin-bottom: 80rpx; | 14 | +.top_box image { |
| 15 | + width: 120rpx; | ||
| 16 | + height: 120rpx; | ||
| 26 | } | 17 | } |
| 27 | 18 | ||
| 28 | -.discount_name { | ||
| 29 | - color: #0143a3; | ||
| 30 | - font-family: PingFang SC; | ||
| 31 | - font-weight: 500; | 19 | +.textName { |
| 20 | + font-weight: 600; | ||
| 21 | + margin-bottom: 10rpx; | ||
| 32 | } | 22 | } |
| 33 | 23 | ||
| 34 | -.top_box .qcode { | ||
| 35 | - width: 400rpx; | ||
| 36 | - height: 400rpx; | 24 | +.threshold .priceText { |
| 25 | + font-size: 52rpx; | ||
| 26 | + font-weight: 600; | ||
| 27 | + margin-right: 12rpx; | ||
| 37 | } | 28 | } |
| 38 | 29 | ||
| 39 | -.lineBox .group { | ||
| 40 | - width: 100rpx; | ||
| 41 | - height: 100rpx; | ||
| 42 | - position: absolute !important; | ||
| 43 | - right: 12%; | ||
| 44 | - top: -30rpx; | 30 | +.top_box .texts { |
| 31 | + flex: 1; | ||
| 32 | + margin-left: 32rpx; | ||
| 45 | } | 33 | } |
| 46 | 34 | ||
| 47 | -.shop_name { | ||
| 48 | - color: #515151; | ||
| 49 | - font-family: PingFang SC; | ||
| 50 | - font-weight: 500; | ||
| 51 | - margin: 34rpx 0 30rpx 0; | 35 | +.threshold { |
| 36 | + color: #FD4D59; | ||
| 37 | + font-weight: 400; | ||
| 52 | } | 38 | } |
| 53 | 39 | ||
| 54 | -.line { | ||
| 55 | - width: 100%; | ||
| 56 | - height: 4rpx; | ||
| 57 | - border-bottom: 4rpx dashed #999999; | 40 | +.receive { |
| 41 | + display: flex; | ||
| 42 | + align-items: flex-end; | ||
| 43 | + color: #999999; | ||
| 58 | } | 44 | } |
| 59 | 45 | ||
| 60 | -.orderNumber { | ||
| 61 | - color: #515151; | ||
| 62 | - font-family: PingFang SC; | ||
| 63 | - font-weight: 500; | ||
| 64 | - margin-top: 16rpx; | 46 | +.center_box { |
| 47 | + border-radius: 20rpx; | ||
| 48 | + background: #ffffff; | ||
| 49 | + padding: 40rpx; | ||
| 50 | + margin: 20rpx; | ||
| 65 | } | 51 | } |
| 66 | 52 | ||
| 67 | -.center_box { | ||
| 68 | - margin: 24rpx 0 32rpx 0; | ||
| 69 | - border-radius: 16rpx; | ||
| 70 | - background: #f8f9fd; | ||
| 71 | - width: 100%; | ||
| 72 | - display: flex; | ||
| 73 | - align-items: center; | ||
| 74 | - justify-content: center; | ||
| 75 | - flex-direction: column; | 53 | +.qrcodeBox { |
| 54 | + display: flex; | ||
| 55 | + flex-direction: column; | ||
| 56 | + align-items: center; | ||
| 76 | } | 57 | } |
| 77 | 58 | ||
| 78 | -.info { | ||
| 79 | - width: 93%; | ||
| 80 | - height: 96rpx; | ||
| 81 | - margin-left: 7%; | ||
| 82 | - padding-right: 7%; | ||
| 83 | - box-sizing: border-box; | ||
| 84 | - display: flex; | ||
| 85 | - justify-content: space-between; | ||
| 86 | - align-items: center; | ||
| 87 | - line-height: 48rpx; | ||
| 88 | - border-bottom: 2rpx solid #E7E7E7; | 59 | +.qrcodeBox .infoText:nth-last-of-type(1) { |
| 60 | + border-bottom: none; | ||
| 89 | } | 61 | } |
| 90 | 62 | ||
| 91 | -.info_left { | ||
| 92 | - color: #515151; | ||
| 93 | - font-family: PingFang SC; | 63 | +.infoText { |
| 64 | + color: #515151; | ||
| 65 | + font-family: PingFang SC; | ||
| 66 | + font-weight: 500; | ||
| 67 | + line-height: 32rpx; | ||
| 68 | + border-bottom: 4rpx dashed #999; | ||
| 69 | + margin: 0 16rpx; | ||
| 70 | + flex: 1; | ||
| 71 | + padding-bottom: 40rpx; | ||
| 72 | + width: 100%; | ||
| 73 | + text-align: center; | ||
| 94 | } | 74 | } |
| 95 | 75 | ||
| 96 | -.info_right { | ||
| 97 | - color: #999999; | ||
| 98 | - font-family: PingFang SC; | 76 | +.qcode { |
| 77 | + width: 400rpx; | ||
| 78 | + height: 400rpx; | ||
| 99 | } | 79 | } |
| 100 | 80 | ||
| 101 | -.sellerName{ | ||
| 102 | - color: #515151; | 81 | +.title { |
| 82 | + display: flex; | ||
| 83 | + align-items: center; | ||
| 84 | + margin-bottom: 16rpx; | ||
| 103 | } | 85 | } |
| 104 | 86 | ||
| 105 | -.explain_news { | ||
| 106 | - width: 100%; | ||
| 107 | - box-sizing: border-box; | ||
| 108 | - padding: 24rpx 7%; | ||
| 109 | - color: #999999; | ||
| 110 | - font-family: PingFang SC; | ||
| 111 | - font-size: 24rpx; | ||
| 112 | - line-height: 48rpx; | 87 | +.title text { |
| 88 | + letter-spacing: 2rpx; | ||
| 113 | } | 89 | } |
| 114 | 90 | ||
| 115 | -.info1 { | ||
| 116 | - border-bottom: 1rpx solid #E7E7E7; | 91 | +.title image { |
| 92 | + width: 26rpx; | ||
| 93 | + height: 26rpx; | ||
| 94 | + margin-right: 14rpx; | ||
| 117 | } | 95 | } |
| 118 | 96 | ||
| 119 | -.btns { | ||
| 120 | - width: 100%; | ||
| 121 | - display: flex; | ||
| 122 | - align-items: flex-end; | ||
| 123 | - justify-content: flex-end; | 97 | +.centerMain3 image { |
| 98 | + width: 22rpx; | ||
| 124 | } | 99 | } |
| 125 | 100 | ||
| 126 | -.btns button { | ||
| 127 | - margin: 0; | ||
| 128 | - border-radius: 50rpx; | ||
| 129 | - border: 2rpx solid #0143a3; | ||
| 130 | - background-color: #fff; | ||
| 131 | - color: #999999; | ||
| 132 | - font-family: PingFang SC; | ||
| 133 | - cursor: none; | ||
| 134 | - box-shadow: none; | 101 | +.centerMain { |
| 102 | + margin-bottom: 40rpx; | ||
| 135 | } | 103 | } |
| 136 | 104 | ||
| 137 | -.canteen_box { | ||
| 138 | - margin: 32rpx 0; | ||
| 139 | - border-radius: 16rpx; | ||
| 140 | - background: #f8f9fd; | ||
| 141 | - width: 100%; | ||
| 142 | - display: flex; | ||
| 143 | - align-items: center; | ||
| 144 | - padding: 30rpx 20rpx; | ||
| 145 | - box-sizing: border-box; | 105 | +.centerMain .drop { |
| 106 | + width: 8rpx; | ||
| 107 | + height: 8rpx; | ||
| 108 | + background: #575757; | ||
| 109 | + border-radius: 50%; | ||
| 110 | + position: absolute; | ||
| 111 | + left: -23rpx; | ||
| 112 | + top: 45%; | ||
| 146 | } | 113 | } |
| 147 | 114 | ||
| 148 | -.canteen_box image { | ||
| 149 | - height: 160rpx; | ||
| 150 | - border-radius: 10rpx; | ||
| 151 | - margin-right: 20rpx; | 115 | +.centerMain:nth-last-of-type(1) { |
| 116 | + margin-bottom: 0; | ||
| 152 | } | 117 | } |
| 153 | 118 | ||
| 154 | -.info_right .font24r { | ||
| 155 | - margin: 10rpx 0 38rpx 0; | 119 | +.centerMain .useImg:nth-of-type(1) { |
| 120 | + margin-bottom: 20rpx; | ||
| 121 | +} | ||
| 122 | + | ||
| 123 | +.centerMain .useImg { | ||
| 124 | + margin-bottom: 20rpx; | ||
| 125 | +} | ||
| 126 | + | ||
| 127 | +.title text { | ||
| 128 | + font-weight: 600; | ||
| 129 | +} | ||
| 130 | + | ||
| 131 | +.info { | ||
| 132 | + margin-left: 44rpx; | ||
| 133 | + color: #575757; | ||
| 134 | + letter-spacing: 2rpx; | ||
| 135 | + position: relative; | ||
| 136 | + line-height: 40rpx; | ||
| 137 | +} | ||
| 138 | + | ||
| 139 | +.mLeft { | ||
| 140 | + margin-left: 44rpx; | ||
| 141 | +} | ||
| 142 | + | ||
| 143 | +.mLeft .info { | ||
| 144 | + margin-left: 0; | ||
| 156 | } | 145 | } |
| 157 | 146 | ||
| 158 | .bottom_box { | 147 | .bottom_box { |
| 159 | - border-radius: 16rpx; | ||
| 160 | - background: #f8f9fd; | ||
| 161 | - width: 100%; | ||
| 162 | - padding: 8rpx 20rpx 28rpx 20rpx; | ||
| 163 | - box-sizing: border-box; | 148 | + border-radius: 16rpx; |
| 149 | + background: #fff; | ||
| 150 | + padding: 40rpx 40rpx 36rpx 40rpx; | ||
| 151 | + box-sizing: border-box; | ||
| 152 | + margin: 0 20rpx; | ||
| 153 | +} | ||
| 154 | + | ||
| 155 | +.bottom_box_wrap { | ||
| 156 | + padding-bottom: 180rpx; | ||
| 164 | } | 157 | } |
| 165 | 158 | ||
| 166 | .bottom_box view { | 159 | .bottom_box view { |
| 167 | - color: #999999; | ||
| 168 | - font-family: PingFang SC; | ||
| 169 | - line-height: 38rpx; | 160 | + color: #515151; |
| 161 | + font-family: PingFang SC; | ||
| 162 | + line-height: 40rpx; | ||
| 170 | } | 163 | } |
| 171 | 164 | ||
| 172 | .bold_box { | 165 | .bold_box { |
| 173 | - font-weight: bold; | ||
| 174 | - color: #515151; | 166 | + font-size: 28rpx; |
| 167 | + font-weight: bold; | ||
| 168 | + color: #000; | ||
| 175 | } | 169 | } |
| 176 | 170 | ||
| 177 | .publicity { | 171 | .publicity { |
| 178 | - margin-top: 14rpx; | ||
| 179 | - display: flex; | ||
| 180 | - align-items: center; | ||
| 181 | - justify-content: center; | ||
| 182 | - padding: 20rpx 0; | ||
| 183 | -} | ||
| 184 | - | ||
| 185 | -.week { | ||
| 186 | - width: 93%; | ||
| 187 | - margin-left: 7%; | ||
| 188 | - padding-right: 7%; | ||
| 189 | - box-sizing: border-box; | ||
| 190 | - display: flex; | ||
| 191 | - justify-content: space-between; | ||
| 192 | - flex-direction: column; | ||
| 193 | - align-items: center; | ||
| 194 | - line-height: 48rpx; | ||
| 195 | - border-bottom: 2rpx solid #E7E7E7; | ||
| 196 | -} | ||
| 197 | - | ||
| 198 | -.week_top { | ||
| 199 | - padding: 24rpx 0; | ||
| 200 | - padding-bottom: 0; | ||
| 201 | - width: 100%; | ||
| 202 | - display: flex; | ||
| 203 | - align-items: center; | ||
| 204 | - justify-content: space-between; | ||
| 205 | -} | ||
| 206 | - | ||
| 207 | -.week_left { | ||
| 208 | - color: #515151; | ||
| 209 | - font-family: PingFang SC; | ||
| 210 | -} | ||
| 211 | - | ||
| 212 | -.texts { | ||
| 213 | - color: #999; | ||
| 214 | - font-family: PingFang SC; | ||
| 215 | -} | ||
| 216 | - | ||
| 217 | -.dateList { | ||
| 218 | - width: 100%; | ||
| 219 | - display: flex; | ||
| 220 | - padding-bottom: 24rpx; | ||
| 221 | - position: relative; | ||
| 222 | - top: -10rpx; | ||
| 223 | - letter-spacing:4rpx; | ||
| 224 | - justify-content: flex-end; | 172 | + margin-top: 14rpx; |
| 173 | + display: flex; | ||
| 174 | + align-items: center; | ||
| 175 | + padding: 20rpx 0; | ||
| 176 | +} | ||
| 177 | + | ||
| 178 | +.sharewidth { | ||
| 179 | + position: fixed; | ||
| 180 | + left: 0; | ||
| 181 | + bottom: 0; | ||
| 182 | + height: 160rpx; | ||
| 183 | + padding: 40rpx 32rpx; | ||
| 184 | + background: #fff; | ||
| 185 | + box-sizing: border-box; | ||
| 186 | + z-index: 100; | ||
| 187 | + width: 100%; | ||
| 188 | + display: flex; | ||
| 189 | +} | ||
| 190 | + | ||
| 191 | +.btns { | ||
| 192 | + flex: 1; | ||
| 193 | + display: flex; | ||
| 194 | + justify-content: flex-end; | ||
| 195 | +} | ||
| 196 | + | ||
| 197 | +.shareBtn { | ||
| 198 | + display: flex; | ||
| 199 | + flex-direction: column; | ||
| 200 | + font-weight: 600; | ||
| 201 | + margin-left: 40rpx; | ||
| 202 | + background: transparent; | ||
| 203 | + align-items: center; | ||
| 204 | +} | ||
| 205 | + | ||
| 206 | +.shareBtn image { | ||
| 207 | + width: 34rpx; | ||
| 208 | + height: 40rpx; | ||
| 209 | +} | ||
| 210 | + | ||
| 211 | +.btn { | ||
| 212 | + color: #fff; | ||
| 213 | + padding: 0 40rpx; | ||
| 214 | + height: 80rpx; | ||
| 215 | + line-height: 80rpx; | ||
| 216 | + border-radius: 40rpx; | ||
| 217 | + font-weight: 600; | ||
| 218 | + margin-left: 20rpx; | ||
| 219 | + width: 40%; | ||
| 220 | + background: linear-gradient(90.98deg, #f41919 0.25%, #ff7426 120.07%); | ||
| 221 | +} | ||
| 222 | + | ||
| 223 | +.btn1 { | ||
| 224 | + font-weight: 600; | ||
| 225 | + padding: 0 40rpx; | ||
| 226 | + height: 80rpx; | ||
| 227 | + line-height: 80rpx; | ||
| 228 | + border-radius: 40rpx; | ||
| 229 | + color: #fb4e21; | ||
| 230 | + border: 2rpx solid #fb4e21; | ||
| 231 | + width: 40%; | ||
| 232 | + text-align: center; | ||
| 233 | +} | ||
| 234 | + | ||
| 235 | +#myModal .titleModal { | ||
| 236 | + margin-top: 80%; | ||
| 237 | + width: 100%; | ||
| 238 | + position: relative; | ||
| 239 | +} | ||
| 240 | + | ||
| 241 | +#myModal .titleModal2 { | ||
| 242 | + margin-top: 80%; | ||
| 243 | +} | ||
| 244 | + | ||
| 245 | +#myModal .titleModal3 { | ||
| 246 | + margin-top: 60%; | ||
| 247 | +} | ||
| 248 | + | ||
| 249 | +#myModal .titleModal4 { | ||
| 250 | + margin-top: 30%; | ||
| 251 | +} | ||
| 252 | + | ||
| 253 | +#myModal .mymodal { | ||
| 254 | + background: rgba(0, 0, 0, 0.8); | ||
| 255 | + width: 100% !important; | ||
| 256 | + top: 0 !important; | ||
| 257 | + height: auto !important; | ||
| 258 | + z-index: 300; | ||
| 259 | +} | ||
| 260 | + | ||
| 261 | +.closeImg { | ||
| 262 | + width: 60rpx; | ||
| 263 | + height: 60rpx; | ||
| 264 | + position: absolute; | ||
| 265 | + right: 0; | ||
| 266 | + top: 0; | ||
| 267 | +} | ||
| 268 | + | ||
| 269 | +.modalText1 { | ||
| 270 | + color: #dfdfdf; | ||
| 271 | + font-family: PingFang SC; | ||
| 272 | + font-weight: 600; | ||
| 273 | + font-size: 52rpx; | ||
| 274 | + text-align: center; | ||
| 275 | +} | ||
| 276 | + | ||
| 277 | +.modalText2 { | ||
| 278 | + color: #dfdfdf; | ||
| 279 | + font-family: PingFang SC; | ||
| 280 | + font-weight: 500; | ||
| 281 | + text-align: center; | ||
| 282 | + margin: 0 40rpx; | ||
| 283 | +} | ||
| 284 | + | ||
| 285 | +.couponBtn { | ||
| 286 | + width: 80%; | ||
| 287 | + margin: 0 auto; | ||
| 288 | + border-radius: 42rpx; | ||
| 289 | + background: linear-gradient(90.98deg, #f41919 0.25%, #ff7426 120.07%); | ||
| 290 | + font-weight: 400; | ||
| 291 | + color: #fff; | ||
| 292 | + text-align: center; | ||
| 293 | + border: 4rpx solid #fff; | ||
| 294 | + padding: 12rpx 0; | ||
| 295 | + margin: 80rpx auto 20rpx auto; | ||
| 296 | +} | ||
| 297 | + | ||
| 298 | +.seller_data { | ||
| 299 | + display: flex; | ||
| 300 | + justify-content: space-between; | ||
| 301 | + padding: 16rpx 24rpx; | ||
| 302 | + background: #fff; | ||
| 303 | + margin: 20rpx; | ||
| 304 | + border-radius: 16rpx; | ||
| 305 | +} | ||
| 306 | + | ||
| 307 | +.seller_data image { | ||
| 308 | + width: 200rpx; | ||
| 309 | + height: 200rpx; | ||
| 310 | + border-radius: 10rpx; | ||
| 311 | +} | ||
| 312 | + | ||
| 313 | +.seller_box { | ||
| 314 | + margin-left: 16rpx; | ||
| 315 | + flex: 1; | ||
| 316 | + position: relative; | ||
| 317 | +} | ||
| 318 | + | ||
| 319 | +.infos { | ||
| 320 | + display: flex; | ||
| 321 | + align-items: center; | ||
| 322 | + justify-content: space-between; | ||
| 323 | + margin: 8rpx 0; | ||
| 324 | + color: #696969; | ||
| 325 | +} | ||
| 326 | + | ||
| 327 | +.dish { | ||
| 328 | + overflow: hidden; | ||
| 329 | + word-break: break-all; | ||
| 330 | + text-overflow: ellipsis; | ||
| 331 | + display: -webkit-box; | ||
| 332 | + -webkit-box-orient: vertical; | ||
| 333 | + -webkit-line-clamp: 2; | ||
| 334 | +} | ||
| 335 | + | ||
| 336 | +.marTop { | ||
| 337 | + margin-top: 4rpx; | ||
| 338 | +} | ||
| 339 | + | ||
| 340 | +.infos1 { | ||
| 341 | + padding-bottom: 40rpx; | ||
| 342 | +} | ||
| 343 | + | ||
| 344 | +.averageText { | ||
| 345 | + flex-shrink: 0; | ||
| 346 | + margin: 0 14rpx; | ||
| 347 | +} | ||
| 348 | + | ||
| 349 | +.park { | ||
| 350 | + background: #FFEEDF; | ||
| 351 | + color: #B56737; | ||
| 352 | + padding: 8rpx 12rpx 0 12rpx; | ||
| 353 | + border-radius: 4rpx; | ||
| 354 | + height: 30rpx; | ||
| 355 | + line-height: 30rpx; | ||
| 356 | + flex-shrink: 0; | ||
| 357 | +} | ||
| 358 | + | ||
| 359 | +.info_name { | ||
| 360 | + color: #000; | ||
| 361 | + overflow: hidden; | ||
| 362 | + word-break: break-all; | ||
| 363 | + text-overflow: ellipsis; | ||
| 364 | + display: -webkit-box; | ||
| 365 | + -webkit-box-orient: vertical; | ||
| 366 | + -webkit-line-clamp: 1; | ||
| 367 | + font-weight: 600; | ||
| 368 | +} | ||
| 369 | + | ||
| 370 | +.bottom_btns { | ||
| 371 | + display: flex; | ||
| 372 | + position: absolute; | ||
| 373 | + bottom: 0; | ||
| 374 | +} | ||
| 375 | + | ||
| 376 | +.book { | ||
| 377 | + margin-right: 8rpx; | ||
| 378 | + padding: 4rpx 12rpx; | ||
| 379 | + background: #FFE8D7; | ||
| 380 | + color: #fb4e21; | ||
| 381 | + border-radius: 4rpx; | ||
| 225 | } | 382 | } |
| @@ -175,9 +175,12 @@ Page({ | @@ -175,9 +175,12 @@ Page({ | ||
| 175 | let distance = ''; | 175 | let distance = ''; |
| 176 | let seller = { | 176 | let seller = { |
| 177 | cateStr, | 177 | cateStr, |
| 178 | + is_parking: data.is_parking, | ||
| 179 | + average: data.average, | ||
| 178 | sellername: data.sellername, | 180 | sellername: data.sellername, |
| 179 | is_online_reserve: data.is_online_reserve, | 181 | is_online_reserve: data.is_online_reserve, |
| 180 | seller_image: data.seller_image, | 182 | seller_image: data.seller_image, |
| 183 | + phone: data.phone, | ||
| 181 | } | 184 | } |
| 182 | wx.getLocation({ | 185 | wx.getLocation({ |
| 183 | type: 'wgs84', // 返回可以用于 wx.openLocation 的经纬度 | 186 | type: 'wgs84', // 返回可以用于 wx.openLocation 的经纬度 |
| @@ -212,6 +215,12 @@ Page({ | @@ -212,6 +215,12 @@ Page({ | ||
| 212 | }) | 215 | }) |
| 213 | }) | 216 | }) |
| 214 | }, | 217 | }, |
| 218 | + // 拨打电话 | ||
| 219 | + callPhone() { | ||
| 220 | + wx.makePhoneCall({ | ||
| 221 | + phoneNumber: this.data.seller.phone | ||
| 222 | + }) | ||
| 223 | + }, | ||
| 215 | // 处理优惠券不可用日期数据 | 224 | // 处理优惠券不可用日期数据 |
| 216 | hasConsecutiveSelect(arr, type) { | 225 | hasConsecutiveSelect(arr, type) { |
| 217 | let firstTitle = null; | 226 | let firstTitle = null; |
| @@ -77,12 +77,12 @@ | @@ -77,12 +77,12 @@ | ||
| 77 | <view class="seller_box"> | 77 | <view class="seller_box"> |
| 78 | <view class="infos"> | 78 | <view class="infos"> |
| 79 | <view class="info_name font32r">{{seller.sellername}}</view> | 79 | <view class="info_name font32r">{{seller.sellername}}</view> |
| 80 | - <!-- <view class="park font24r">可停车</view> --> | 80 | + <view class="park font24r" wx:if="{{seller.is_parking}}">可停车</view> |
| 81 | </view> | 81 | </view> |
| 82 | - <view class="infos"> | 82 | + <view class="infos infos1"> |
| 83 | <view class="dish font24r">{{seller.cateStr}}</view> | 83 | <view class="dish font24r">{{seller.cateStr}}</view> |
| 84 | - <view class="aa font24r" wx:if="{{seller.average && seller.average>0}}">人均¥{{seller.average}}</view> | ||
| 85 | - <text class="font24r">{{distance}}</text> | 84 | + <view class="averageText font24r" wx:if="{{seller.average && seller.average>0}}">人均¥{{seller.average}}</view> |
| 85 | + <view class="marTop font24r">{{distance}}</view> | ||
| 86 | </view> | 86 | </view> |
| 87 | <!-- <view class="bottom_btns"> | 87 | <!-- <view class="bottom_btns"> |
| 88 | <view class="book font24r">朋友订过</view> | 88 | <view class="book font24r">朋友订过</view> |
| @@ -111,6 +111,9 @@ | @@ -111,6 +111,9 @@ | ||
| 111 | <view class="btn1 font36r" wx:if="{{seller.is_online_reserve == '1'}}"> | 111 | <view class="btn1 font36r" wx:if="{{seller.is_online_reserve == '1'}}"> |
| 112 | <navigator url="/pages/reserve/reserve?id={{opt.sid}}&activeTab=reserve" class="book-item-font second-book-button flex-cc font30r" style="position: relative;">预订包间</navigator> | 112 | <navigator url="/pages/reserve/reserve?id={{opt.sid}}&activeTab=reserve" class="book-item-font second-book-button flex-cc font30r" style="position: relative;">预订包间</navigator> |
| 113 | </view> | 113 | </view> |
| 114 | + <view class="btn font36r" wx:if="{{seller.is_online_reserve == '0' && seller.phone}}"> | ||
| 115 | + <view bindtap="callPhone">预订包间</view> | ||
| 116 | + </view> | ||
| 114 | <view wx:if="{{resultCoupon == '0' && detail.grant_last>0}}" class="btn font36r" bindtap="submitOrder">领取到卡包</view> | 117 | <view wx:if="{{resultCoupon == '0' && detail.grant_last>0}}" class="btn font36r" bindtap="submitOrder">领取到卡包</view> |
| 115 | </view> | 118 | </view> |
| 116 | </view> | 119 | </view> |
| @@ -270,11 +270,34 @@ page { | @@ -270,11 +270,34 @@ page { | ||
| 270 | 270 | ||
| 271 | .infos { | 271 | .infos { |
| 272 | display: flex; | 272 | display: flex; |
| 273 | + align-items: center; | ||
| 273 | justify-content: space-between; | 274 | justify-content: space-between; |
| 274 | margin: 8rpx 0; | 275 | margin: 8rpx 0; |
| 275 | color: #696969; | 276 | color: #696969; |
| 276 | } | 277 | } |
| 277 | 278 | ||
| 279 | +.dish { | ||
| 280 | + overflow: hidden; | ||
| 281 | + word-break: break-all; | ||
| 282 | + text-overflow: ellipsis; | ||
| 283 | + display: -webkit-box; | ||
| 284 | + -webkit-box-orient: vertical; | ||
| 285 | + -webkit-line-clamp: 2; | ||
| 286 | +} | ||
| 287 | + | ||
| 288 | +.marTop { | ||
| 289 | + margin-top: 4rpx; | ||
| 290 | +} | ||
| 291 | + | ||
| 292 | +.infos1 { | ||
| 293 | + padding-bottom: 40rpx; | ||
| 294 | +} | ||
| 295 | + | ||
| 296 | +.averageText { | ||
| 297 | + flex-shrink: 0; | ||
| 298 | + margin: 0 14rpx; | ||
| 299 | +} | ||
| 300 | + | ||
| 278 | .park { | 301 | .park { |
| 279 | background: #FFEEDF; | 302 | background: #FFEEDF; |
| 280 | color: #B56737; | 303 | color: #B56737; |
| @@ -40,6 +40,47 @@ Page({ | @@ -40,6 +40,47 @@ Page({ | ||
| 40 | item.status = '2'; | 40 | item.status = '2'; |
| 41 | item.is_examine = '0'; | 41 | item.is_examine = '0'; |
| 42 | } | 42 | } |
| 43 | + item.exp_date = item.exp_date ? util.determine(item.exp_date) : ''; | ||
| 44 | + item.arule = item.arule ? util.determine(item.arule) : ''; | ||
| 45 | + item.use = item.use ? util.determine(item.use) : ''; | ||
| 46 | + if ((item.use && (!item.use.is_cash || item.use.is_cash == '1'))) { | ||
| 47 | + let cash = item.use.cash * 1; | ||
| 48 | + let price = item.price * 1; | ||
| 49 | + item.discount = cash != 0 ? ((price / cash) * 10).toFixed(1) : ''; | ||
| 50 | + } | ||
| 51 | + if (item.exp_date && item.exp_date.week_data) { | ||
| 52 | + let noon = this.hasConsecutiveSelect(item.exp_date.week_data, '1').rArr.join('、') | ||
| 53 | + let nig = this.hasConsecutiveSelect(item.exp_date.week_data, '2').rArr.join('、') | ||
| 54 | + if (noon) noon = '午餐:' + noon | ||
| 55 | + if (nig) nig = '晚餐:' + nig | ||
| 56 | + item.noonText = noon; | ||
| 57 | + item.nigText = nig; | ||
| 58 | + } | ||
| 59 | + item.noShow = '1'; | ||
| 60 | + item.noShowTetxt = ''; | ||
| 61 | + if(item.is_examine=='1' && item.is_comment!='1'){ | ||
| 62 | + item.noShow = '0' | ||
| 63 | + item.noShowTetxt = '已使用' | ||
| 64 | + } | ||
| 65 | + if(item.is_expire=='1'){ | ||
| 66 | + item.noShow = '0' | ||
| 67 | + item.noShowTetxt = '已失效' | ||
| 68 | + } | ||
| 69 | + if(item.status=='4'){ | ||
| 70 | + item.noShow = '0' | ||
| 71 | + item.noShowTetxt = '退款中' | ||
| 72 | + } | ||
| 73 | + if(item.status=='5'){ | ||
| 74 | + item.noShow = '0' | ||
| 75 | + item.noShowTetxt = '已退款' | ||
| 76 | + } | ||
| 77 | + if(item.is_examine=='1' && item.is_comment=='1'){ | ||
| 78 | + item.noShow = '0' | ||
| 79 | + item.noShowTetxt = '已评价' | ||
| 80 | + } | ||
| 81 | + if(item.is_examine=='1' && item.is_expire=='0' && item.status!='4' && item.status!='5' && item.is_comment!='1'){ | ||
| 82 | + item.noShow = '1' | ||
| 83 | + } | ||
| 43 | }) | 84 | }) |
| 44 | list.sort((a, b) => a.is_examine - b.is_examine); | 85 | list.sort((a, b) => a.is_examine - b.is_examine); |
| 45 | list.sort((a, b) => a.is_expire - b.is_expire); | 86 | list.sort((a, b) => a.is_expire - b.is_expire); |
| @@ -104,4 +145,48 @@ Page({ | @@ -104,4 +145,48 @@ Page({ | ||
| 104 | this.todetail() | 145 | this.todetail() |
| 105 | } | 146 | } |
| 106 | }, | 147 | }, |
| 148 | + // 处理优惠券不可用日期数据 | ||
| 149 | + hasConsecutiveSelect(arr, type) { | ||
| 150 | + let firstTitle = null; | ||
| 151 | + let lastTitle = null; | ||
| 152 | + let rArr = [] | ||
| 153 | + let num = 0 | ||
| 154 | + for (let i = 0; i < arr.length; i++) { | ||
| 155 | + let str = type == '1' ? arr[i].selectNoon : arr[i].selectNig | ||
| 156 | + if (str) { | ||
| 157 | + rArr.push(arr[i].title) | ||
| 158 | + num++ | ||
| 159 | + if (num == 1) { | ||
| 160 | + firstTitle = arr[i].title | ||
| 161 | + } | ||
| 162 | + if (num >= 5) { | ||
| 163 | + lastTitle = arr[i].title | ||
| 164 | + } | ||
| 165 | + if (num >= 5 && i >= (arr.length - 1)) { | ||
| 166 | + let fi = rArr.findIndex((item) => { | ||
| 167 | + return item == firstTitle | ||
| 168 | + }) | ||
| 169 | + rArr.splice(fi, num, firstTitle + '至' + lastTitle) | ||
| 170 | + num = 0 | ||
| 171 | + } | ||
| 172 | + } else { | ||
| 173 | + if (num < 5) { | ||
| 174 | + num = 0 | ||
| 175 | + firstTitle = null; | ||
| 176 | + lastTitle = null; | ||
| 177 | + } else { | ||
| 178 | + let fi = rArr.findIndex((item) => { | ||
| 179 | + return item == firstTitle | ||
| 180 | + }) | ||
| 181 | + rArr.splice(fi, num, firstTitle + '至' + lastTitle) | ||
| 182 | + num = 0 | ||
| 183 | + } | ||
| 184 | + } | ||
| 185 | + } | ||
| 186 | + return { | ||
| 187 | + rArr, | ||
| 188 | + lastTitle, | ||
| 189 | + firstTitle | ||
| 190 | + }; | ||
| 191 | + }, | ||
| 107 | }) | 192 | }) |
| @@ -3,23 +3,43 @@ | @@ -3,23 +3,43 @@ | ||
| 3 | <nav>卡券</nav> | 3 | <nav>卡券</nav> |
| 4 | <scroll-view class="list" style="height:{{contentHeight}}px;" scroll-y> | 4 | <scroll-view class="list" style="height:{{contentHeight}}px;" scroll-y> |
| 5 | <block wx:if="{{list.length>0}}"> | 5 | <block wx:if="{{list.length>0}}"> |
| 6 | - <view wx:for="{{list}}" class="card bg-white" bindtap="todetail" data-item="{{item}}" > | ||
| 7 | - <view class="flex-vl gray-font card-main" style="justify-content:space-between;"> | ||
| 8 | - <view class="seller-info flex-ll"> | ||
| 9 | - <view class="smooth font-siny font32r" wx:if="{{item.recharge_name || item.aname}}">{{item.recharge_name || item.aname}}</view> | ||
| 10 | - </view> | ||
| 11 | - <view class="font24r font-bold text1" wx:if="{{item.sellername}}">{{item.sellername}}</view> | ||
| 12 | - <view class="font24r font-bold text1" wx:if="{{item.order_no}}">{{item.order_no}}</view> | 6 | + <view wx:for="{{list}}" bindtap="todetail" data-item="{{item}}" wx:if="{{item.recharge_name || item.aname}}" class="preferentialItems {{item.noShow == '0' ? 'noStyle':''}}"> |
| 7 | + <view class="itemLeft"> | ||
| 8 | + <text wx:if="{{item.discount!='0.00' && (item.use.is_cash=='1' || item.use.is_cash) && item.discount}}" class="discountText font24r">{{item.discount}}折</text> | ||
| 9 | + <view class="discountText1 font20r {{item.arule.is_accumulation == '1'?'discountText2':'discountText3'}}" wx:if="{{item.is_type == '3'}}">{{item.arule.is_accumulation == '1' ? '可' : '不可'}}叠加</view> | ||
| 10 | + <view class="priceText" wx:if="{{item.price}}"> | ||
| 11 | + <view class="icons font24r">¥</view><text class="font40r">{{item.price}}</text> | ||
| 12 | + </view> | ||
| 13 | + <view class="icons font20r" wx:if="{{item.is_type == '3' && item.desc!='0'}}">消费满{{item.desc}}元可用</view> | ||
| 14 | + </view> | ||
| 15 | + <view class="couponLine"></view> | ||
| 16 | + <view class="itemRight"> | ||
| 17 | + <view class="btns"> | ||
| 18 | + <text class="font40r">{{item.recharge_name || item.aname}}</text> | ||
| 19 | + <block wx:if="{{item.is_type == '1' || item.is_type == '2' || item.type == '1' || item.type == '2'}}"> | ||
| 20 | + <view wx:if="{{item.exp_date.is_week=='1' || item.exp_date.is_week===true}}" class="bottom font24r">{{item.exp_date.week_show?item.exp_date.week_show+'可用':''}}{{item.desc?','+item.desc+'。':'。'}}</view> | ||
| 21 | + <view wx:if="{{item.exp_date.is_none=='1' || item.exp_date.is_none===true}}" class="bottom font24r"> | ||
| 22 | + 无限制{{item.desc?','+item.desc+'。':'。'}} | ||
| 23 | + </view> | ||
| 24 | + <view wx:if="{{item.exp_date.is_birthday=='1' || item.exp_date.is_birthday===true}}" class="bottom font24r"> | ||
| 25 | + 会员生日当天可用{{item.desc?','+item.desc+'。':'。'}} | ||
| 26 | + </view> | ||
| 27 | + </block> | ||
| 28 | + <block wx:if="{{item.is_type == '3'}}"> | ||
| 29 | + <view wx:if="{{item.is_type == '3' && item.aexpiration>0}}" class="bottom font24r">领取后{{item.aexpiration}}天有效</view> | ||
| 30 | + <view wx:if="{{item.noonText || item.noonText}}" class="bottom font24r">不可用日期:</view> | ||
| 31 | + <view wx:if="{{item.noonText}}" class="bottom font24r nodate">{{item.noonText}}</view> | ||
| 32 | + <view wx:if="{{item.nigText}}" class="bottom font24r nodate">{{item.nigText}}</view> | ||
| 33 | + <view wx:if="{{item.exp_date.week_show=='无'}}" class="bottom font24r">无使用时间限制</view> | ||
| 34 | + <view wx:if="{{item.is_type == '4' && item.desc!='0'}}" class="bottom font24r">消费满{{item.desc}}元可用</view> | ||
| 35 | + </block> | ||
| 36 | + </view> | ||
| 37 | + <view class="btnBox"> | ||
| 38 | + <view class="font24r orderingFood" wx:if="{{item.is_examine=='0' && item.is_expire=='0' && item.is_examine=='0' && item.status!='4' && item.status!='5'}}">去核销</view> | ||
| 39 | + <view class="font24r orderingFood" wx:if="{{item.is_examine=='1' && item.is_expire=='0' && item.status!='4' && item.status!='5' && item.is_comment!='1'}}">去评价</view> | ||
| 40 | + <view class="font24r orderingFood" wx:if="{{!(item.is_examine=='1' && item.is_expire=='0' && item.status!='4' && item.status!='5' && item.is_comment!='1') && item.noShowTetxt}}">{{item.noShowTetxt}}</view> | ||
| 41 | + </view> | ||
| 13 | </view> | 42 | </view> |
| 14 | - <!-- status 状态 1 待支付 2 已支付 3 支付失败 4 退款中 5 已退款 is_expire 1未失效 --> | ||
| 15 | - <image wx:if="{{item.is_examine=='1' && item.is_comment!='1'}}" src="https://qn.colorcun.com/WechatIMG713.png" class="imgs1" mode="" /> | ||
| 16 | - <image wx:if="{{item.is_expire=='1'}}" src="https://qn.colorcun.com/WechatIMG714.png" class="imgs1" mode="" /> | ||
| 17 | - <image wx:if="{{item.status=='4'}}" src="https://qn.colorcun.com/WechatIMG1.png" class="imgs1" mode="" /> | ||
| 18 | - <image wx:if="{{item.status=='5'}}" src="https://qn.colorcun.com/WechatIMG2.png" class="imgs1" mode="" /> | ||
| 19 | - <image wx:if="{{item.is_examine=='1' && item.is_comment=='1'}}" src="https://qn.colorcun.com/A1.png" class="imgs1" mode="" /> | ||
| 20 | - <!-- is_comment 1已评论 is_examine 1已核销 is_expire 1已过期--> | ||
| 21 | - <button wx:if="{{item.is_examine=='1' && item.is_expire=='0' && item.status!='4' && item.status!='5' && item.is_comment!='1'}}" class="flex-cc card-info font30r font-bold smooth">去评价</button> | ||
| 22 | - <view class="font24r texts {{(item.is_examine=='1' || item.is_expire=='1' || item.status=='4' || item.status=='5')?'texts2':'texts1' }} smooth">有效时间:{{util.unixtoTime(item.stime,'YYYY-MM-DD')}} 至 {{util.unixtoTime(item.etime,'YYYY-MM-DD')}}</view> | ||
| 23 | </view> | 43 | </view> |
| 24 | </block> | 44 | </block> |
| 25 | <block wx:if="{{list.length=='0' && isShow}}"> | 45 | <block wx:if="{{list.length=='0' && isShow}}"> |
| 1 | /* pages/me/coupon_news.wxss */ | 1 | /* pages/me/coupon_news.wxss */ |
| 2 | @import "../../app.wxss"; | 2 | @import "../../app.wxss"; |
| 3 | 3 | ||
| 4 | -.card { | ||
| 5 | - width: 690rpx; | ||
| 6 | - height: 240rpx; | ||
| 7 | - border-radius: 6rpx; | ||
| 8 | - margin: 0 auto 30rpx; | ||
| 9 | - background: #F8F9FD; | ||
| 10 | - overflow: hidden; | ||
| 11 | - position: relative; | ||
| 12 | - border-radius: 16rpx; | ||
| 13 | -} | ||
| 14 | - | ||
| 15 | .font-siny { | 4 | .font-siny { |
| 16 | color: #0143a3; | 5 | color: #0143a3; |
| 17 | font-family: PingFang SC; | 6 | font-family: PingFang SC; |
| @@ -42,135 +31,137 @@ | @@ -42,135 +31,137 @@ | ||
| 42 | } | 31 | } |
| 43 | 32 | ||
| 44 | .card-main.canuse { | 33 | .card-main.canuse { |
| 45 | - border-right: 2rpx dashed #F05522; | 34 | + border-right: 2rpx dashed #F05522; |
| 46 | } | 35 | } |
| 47 | 36 | ||
| 48 | .card-main.used { | 37 | .card-main.used { |
| 49 | - border-right: 2rpx dashed #CCCCCC; | 38 | + border-right: 2rpx dashed #CCCCCC; |
| 50 | } | 39 | } |
| 51 | 40 | ||
| 52 | .seller-image { | 41 | .seller-image { |
| 53 | - width: 30rpx; | ||
| 54 | - height: 30rpx; | ||
| 55 | - border-radius: 50%; | ||
| 56 | - background: #EEEEEE; | ||
| 57 | - margin-right: 10rpx; | 42 | + width: 30rpx; |
| 43 | + height: 30rpx; | ||
| 44 | + border-radius: 50%; | ||
| 45 | + background: #EEEEEE; | ||
| 46 | + margin-right: 10rpx; | ||
| 58 | } | 47 | } |
| 59 | 48 | ||
| 60 | .card-info { | 49 | .card-info { |
| 61 | - padding: 0 26rpx; | ||
| 62 | - height: 48rpx; | ||
| 63 | - line-height: 48rpx; | ||
| 64 | - box-sizing: border-box; | ||
| 65 | - margin: 0; | ||
| 66 | - position: absolute; | ||
| 67 | - right: 4%; | ||
| 68 | - bottom: 44%; | ||
| 69 | - border: 2rpx solid #0143A3; | ||
| 70 | - border-radius: 44rpx; | ||
| 71 | - font-weight: normal; | ||
| 72 | - color: #999999; | 50 | + padding: 0 26rpx; |
| 51 | + height: 48rpx; | ||
| 52 | + line-height: 48rpx; | ||
| 53 | + box-sizing: border-box; | ||
| 54 | + margin: 0; | ||
| 55 | + position: absolute; | ||
| 56 | + right: 4%; | ||
| 57 | + bottom: 44%; | ||
| 58 | + border: 2rpx solid #0143A3; | ||
| 59 | + border-radius: 44rpx; | ||
| 60 | + font-weight: normal; | ||
| 61 | + color: #999999; | ||
| 73 | } | 62 | } |
| 74 | 63 | ||
| 75 | .use-button { | 64 | .use-button { |
| 76 | - width: 160rpx; | ||
| 77 | - height: 44rpx; | ||
| 78 | - border-radius: 24rpx; | ||
| 79 | - border: 2rpx solid #5EB2FF; | 65 | + width: 160rpx; |
| 66 | + height: 44rpx; | ||
| 67 | + border-radius: 24rpx; | ||
| 68 | + border: 2rpx solid #5EB2FF; | ||
| 80 | } | 69 | } |
| 81 | 70 | ||
| 82 | .circle-pos { | 71 | .circle-pos { |
| 83 | - width: 24rpx; | ||
| 84 | - height: 100%; | ||
| 85 | - position: absolute; | ||
| 86 | - left: 78%; | ||
| 87 | - top: 0; | ||
| 88 | - margin-left: -14rpx; | 72 | + width: 24rpx; |
| 73 | + height: 100%; | ||
| 74 | + position: absolute; | ||
| 75 | + left: 78%; | ||
| 76 | + top: 0; | ||
| 77 | + margin-left: -14rpx; | ||
| 89 | } | 78 | } |
| 90 | 79 | ||
| 91 | .circle { | 80 | .circle { |
| 92 | - width: 24rpx; | ||
| 93 | - height: 12rpx; | ||
| 94 | - background: #FFFFFF; | 81 | + width: 24rpx; |
| 82 | + height: 12rpx; | ||
| 83 | + background: #FFFFFF; | ||
| 95 | } | 84 | } |
| 96 | 85 | ||
| 97 | .circle-top { | 86 | .circle-top { |
| 98 | - border-radius: 12rpx 12rpx 0 0; | 87 | + border-radius: 12rpx 12rpx 0 0; |
| 99 | } | 88 | } |
| 100 | 89 | ||
| 101 | .circle-bottom { | 90 | .circle-bottom { |
| 102 | - border-radius: 0 0 12rpx 12rpx; | 91 | + border-radius: 0 0 12rpx 12rpx; |
| 103 | } | 92 | } |
| 104 | 93 | ||
| 105 | .orange-font { | 94 | .orange-font { |
| 106 | - color: #F05522; | 95 | + color: #F05522; |
| 107 | } | 96 | } |
| 108 | 97 | ||
| 109 | .list { | 98 | .list { |
| 110 | - width: 100%; | ||
| 111 | - padding-top: 20rpx; | ||
| 112 | - box-sizing: border-box; | 99 | + width: 100%; |
| 100 | + padding-top: 20rpx; | ||
| 101 | + box-sizing: border-box; | ||
| 113 | } | 102 | } |
| 114 | 103 | ||
| 115 | .select-all { | 104 | .select-all { |
| 116 | - width: 200rpx; | ||
| 117 | - padding: 30rpx 20rpx; | ||
| 118 | - box-sizing: border-box; | 105 | + width: 200rpx; |
| 106 | + padding: 30rpx 20rpx; | ||
| 107 | + box-sizing: border-box; | ||
| 119 | } | 108 | } |
| 120 | 109 | ||
| 121 | .circle { | 110 | .circle { |
| 122 | - width: 30rpx; | ||
| 123 | - height: 30rpx; | ||
| 124 | - border: 2rpx solid #ECD9B7; | ||
| 125 | - border-radius: 50%; | ||
| 126 | - box-sizing: border-box; | 111 | + width: 30rpx; |
| 112 | + height: 30rpx; | ||
| 113 | + border: 2rpx solid #ECD9B7; | ||
| 114 | + border-radius: 50%; | ||
| 115 | + box-sizing: border-box; | ||
| 127 | } | 116 | } |
| 128 | 117 | ||
| 129 | .card-used { | 118 | .card-used { |
| 130 | - width: 90%; | ||
| 131 | - box-sizing: border-box; | ||
| 132 | - height: 120rpx; | ||
| 133 | - box-shadow: 0 0 8rpx #EEF0F2; | ||
| 134 | - background: #FFFFFF; | ||
| 135 | - display: flex; | ||
| 136 | - align-items: center; | ||
| 137 | - justify-content: center; | ||
| 138 | - margin: 0 auto; | ||
| 139 | - color: #999999; | ||
| 140 | - font-family: PingFang SC; | ||
| 141 | - font-weight: 500; | ||
| 142 | - font-size: 28rpx; | 119 | + width: 90%; |
| 120 | + box-sizing: border-box; | ||
| 121 | + height: 120rpx; | ||
| 122 | + box-shadow: 0 0 8rpx #EEF0F2; | ||
| 123 | + background: #FFFFFF; | ||
| 124 | + display: flex; | ||
| 125 | + align-items: center; | ||
| 126 | + justify-content: center; | ||
| 127 | + margin: 0 auto; | ||
| 128 | + color: #999999; | ||
| 129 | + font-family: PingFang SC; | ||
| 130 | + font-weight: 500; | ||
| 131 | + font-size: 28rpx; | ||
| 143 | } | 132 | } |
| 144 | 133 | ||
| 145 | .wananchi text{ | 134 | .wananchi text{ |
| 146 | - color: #515151; | 135 | + color: #515151; |
| 147 | } | 136 | } |
| 148 | 137 | ||
| 149 | .texts { | 138 | .texts { |
| 150 | - width: 100%; | ||
| 151 | - height: 60rpx; | ||
| 152 | - padding-left: 24rpx; | ||
| 153 | - box-sizing: border-box; | ||
| 154 | - display: flex; | ||
| 155 | - align-items: center; | ||
| 156 | - position: absolute; | ||
| 157 | - bottom: 0; | ||
| 158 | - left: 0; | ||
| 159 | - color: #fff; | 139 | + width: 100%; |
| 140 | + height: 60rpx; | ||
| 141 | + padding-left: 24rpx; | ||
| 142 | + box-sizing: border-box; | ||
| 143 | + display: flex; | ||
| 144 | + align-items: center; | ||
| 145 | + position: absolute; | ||
| 146 | + bottom: 0; | ||
| 147 | + left: 0; | ||
| 148 | + color: #fff; | ||
| 160 | } | 149 | } |
| 161 | 150 | ||
| 162 | .texts1{ | 151 | .texts1{ |
| 163 | - background: linear-gradient(104.24deg, #4c8dad -57.47%, #0143a3 55.72%, #42a5ff 148.72%); | 152 | + background: linear-gradient(104.24deg, #4c8dad -57.47%, #0143a3 55.72%, #42a5ff 148.72%); |
| 164 | } | 153 | } |
| 154 | + | ||
| 165 | .texts2{ | 155 | .texts2{ |
| 166 | - background:#DBDBDB; | 156 | + background:#DBDBDB; |
| 167 | } | 157 | } |
| 158 | + | ||
| 168 | .imgs1{ | 159 | .imgs1{ |
| 169 | - position: absolute !important; | ||
| 170 | - right: 30%; | ||
| 171 | - top: 15%; | ||
| 172 | - width: 92rpx; | ||
| 173 | - height: 92rpx; | 160 | + position: absolute !important; |
| 161 | + right: 30%; | ||
| 162 | + top: 15%; | ||
| 163 | + width: 92rpx; | ||
| 164 | + height: 92rpx; | ||
| 174 | } | 165 | } |
| 175 | 166 | ||
| 176 | .empty-img{ | 167 | .empty-img{ |
| @@ -179,6 +170,7 @@ | @@ -179,6 +170,7 @@ | ||
| 179 | width:302rpx; | 170 | width:302rpx; |
| 180 | height:408rpx; | 171 | height:408rpx; |
| 181 | } | 172 | } |
| 173 | + | ||
| 182 | .empty-txt{ | 174 | .empty-txt{ |
| 183 | height:44rpx; | 175 | height:44rpx; |
| 184 | font-size:32rpx; | 176 | font-size:32rpx; |
| @@ -187,4 +179,177 @@ | @@ -187,4 +179,177 @@ | ||
| 187 | color:rgba(53,53,53,1); | 179 | color:rgba(53,53,53,1); |
| 188 | line-height:44rpx; | 180 | line-height:44rpx; |
| 189 | margin-top: 40rpx; | 181 | margin-top: 40rpx; |
| 182 | +} | ||
| 183 | + | ||
| 184 | +.preferentialItems { | ||
| 185 | + display: flex; | ||
| 186 | + background: linear-gradient(180deg, #ffefd0 0%, #ffdc9b 100%); | ||
| 187 | + min-height: 160rpx; | ||
| 188 | + padding-bottom: 10rpx; | ||
| 189 | + border-radius: 20rpx; | ||
| 190 | + margin: 0 40rpx 20rpx; | ||
| 191 | +} | ||
| 192 | + | ||
| 193 | +.itemLeft { | ||
| 194 | + width: 27%; | ||
| 195 | + display: flex; | ||
| 196 | + flex-direction: column; | ||
| 197 | + justify-content: center; | ||
| 198 | + position: relative; | ||
| 199 | + align-items: center; | ||
| 200 | +} | ||
| 201 | + | ||
| 202 | +.discountText { | ||
| 203 | + text-align: center; | ||
| 204 | + color: #FFEFC5; | ||
| 205 | + border-radius: 6rpx; | ||
| 206 | + font-family: PingFang SC; | ||
| 207 | + background: #FD4D59; | ||
| 208 | + width: max-content; | ||
| 209 | + padding: 6rpx; | ||
| 210 | + position: absolute; | ||
| 211 | + left: 16rpx; | ||
| 212 | + top: 12rpx; | ||
| 213 | +} | ||
| 214 | + | ||
| 215 | +.discountText1 { | ||
| 216 | + text-align: center; | ||
| 217 | + border-radius: 6rpx; | ||
| 218 | + font-family: PingFang SC; | ||
| 219 | + background: transparent; | ||
| 220 | + width: max-content; | ||
| 221 | + padding: 2rpx 8rpx; | ||
| 222 | + position: absolute; | ||
| 223 | + left: 16rpx; | ||
| 224 | + top: 12rpx; | ||
| 225 | +} | ||
| 226 | + | ||
| 227 | +.discountText2 { | ||
| 228 | + background: #FD4D59; | ||
| 229 | + color: #fff; | ||
| 230 | +} | ||
| 231 | + | ||
| 232 | +.discountText3 { | ||
| 233 | + color: #FD4D59; | ||
| 234 | + border: 2rpx solid #FD4D59; | ||
| 235 | +} | ||
| 236 | + | ||
| 237 | +.priceText { | ||
| 238 | + display: flex; | ||
| 239 | + align-items: baseline; | ||
| 240 | + justify-content: center; | ||
| 241 | + font-family: PingFang SC; | ||
| 242 | + color: #F6231B; | ||
| 243 | + font-weight: 600; | ||
| 244 | + font-size: 48rpx; | ||
| 245 | + padding-top: 20rpx; | ||
| 246 | +} | ||
| 247 | + | ||
| 248 | +.icons { | ||
| 249 | + color: #F6231B; | ||
| 250 | +} | ||
| 251 | + | ||
| 252 | +.priceText .icons { | ||
| 253 | + color: #FD4D59; | ||
| 254 | +} | ||
| 255 | + | ||
| 256 | +.priceText text { | ||
| 257 | + font-size: 48rpx; | ||
| 258 | +} | ||
| 259 | + | ||
| 260 | +.nodate{ | ||
| 261 | + margin-left: 20rpx; | ||
| 262 | +} | ||
| 263 | + | ||
| 264 | +.couponLine { | ||
| 265 | + margin: 24rpx 0; | ||
| 266 | + border-right: 2rpx dashed #f6231b; | ||
| 267 | +} | ||
| 268 | + | ||
| 269 | +.itemRight { | ||
| 270 | + padding-right: 10rpx; | ||
| 271 | + margin-left: 14rpx; | ||
| 272 | + width: 74%; | ||
| 273 | + display: flex; | ||
| 274 | + align-items: center; | ||
| 275 | +} | ||
| 276 | + | ||
| 277 | +.btns { | ||
| 278 | + margin: 24rpx 20rpx 0 0; | ||
| 279 | + display: flex; | ||
| 280 | + justify-content: space-between; | ||
| 281 | + align-items: baseline; | ||
| 282 | + flex-direction: column; | ||
| 283 | +} | ||
| 284 | + | ||
| 285 | +.orderingFood { | ||
| 286 | + padding: 0 24rpx; | ||
| 287 | + border-radius: 22rpx; | ||
| 288 | + text-align: center; | ||
| 289 | + border-radius: 20rpx; | ||
| 290 | + line-height: 44rpx; | ||
| 291 | + height: 44rpx; | ||
| 292 | + width: max-content; | ||
| 293 | + flex-shrink: 0; | ||
| 294 | + border: 2rpx solid #fa4b20; | ||
| 295 | + background: transparent; | ||
| 296 | + color: #fa4b20; | ||
| 297 | +} | ||
| 298 | + | ||
| 299 | +.btns { | ||
| 300 | + flex: 1; | ||
| 301 | +} | ||
| 302 | + | ||
| 303 | +.btnBox { | ||
| 304 | + display: flex; | ||
| 305 | + flex-direction: column; | ||
| 306 | +} | ||
| 307 | + | ||
| 308 | +.btns text { | ||
| 309 | + font-weight: 600; | ||
| 310 | + margin-bottom: 4rpx; | ||
| 311 | +} | ||
| 312 | + | ||
| 313 | +.bottom { | ||
| 314 | + margin-top: 4rpx; | ||
| 315 | + width: 100%; | ||
| 316 | + color: #C36607; | ||
| 317 | + font-family: PingFang SC; | ||
| 318 | + font-weight: 500; | ||
| 319 | + display: -webkit-box; | ||
| 320 | + word-break: break-all; | ||
| 321 | + word-wrap: break-word; | ||
| 322 | + overflow: hidden; | ||
| 323 | + text-align: left; | ||
| 324 | +} | ||
| 325 | + | ||
| 326 | +.noStyle .preferentialItems{ | ||
| 327 | + background: #DBDBDB; | ||
| 328 | +} | ||
| 329 | + | ||
| 330 | +.noStyle .priceText, | ||
| 331 | +.noStyle .bottom, | ||
| 332 | +.noStyle .btns, | ||
| 333 | +.noStyle .icons, | ||
| 334 | +.noStyle .priceText .icons { | ||
| 335 | + color: #999; | ||
| 336 | +} | ||
| 337 | + | ||
| 338 | +.noStyle .orderingFood{ | ||
| 339 | + border: 2rpx solid #999; | ||
| 340 | + color: #999; | ||
| 341 | +} | ||
| 342 | + | ||
| 343 | +.noStyle .couponLine { | ||
| 344 | + border-right: 2rpx dashed #999; | ||
| 345 | +} | ||
| 346 | + | ||
| 347 | +.noStyle .discountText2{ | ||
| 348 | + background: #999; | ||
| 349 | + color: #fff; | ||
| 350 | +} | ||
| 351 | + | ||
| 352 | +.noStyle .discountText3{ | ||
| 353 | + color: #999; | ||
| 354 | + border: 2rpx solid #999; | ||
| 190 | } | 355 | } |
-
Please register or login to post a comment