1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051 |
- <template>
- <view>
- <view class="inner-box">
- <!-- 收货人 -->
- <view class="address-box" v-if="address==null" @click="openAddress()">
- <view class="left">
- <view class="name-box">
- <text class="text name">添加收货地址</text>
- </view>
- </view>
- <view class="arrow-box">
- <image src="/static/images/arrow_gray.png" mode=""></image>
- </view>
- </view>
- <view class="address-box" v-if="address!=null" @click="openAddress()">
- <view class="left">
- <view class="name-box">
- <text class="text name">{{address.realName}}</text>
- <text class="text" v-if="address.phone!=null">{{$parsePhone(address.phone)}}</text>
- </view>
- <view class="address">
- {{address.province}}{{address.city}}{{address.district}}{{address.detail}}
- </view>
- </view>
- <view class="arrow-box">
- <image src="/static/images/arrow_gray.png" mode=""></image>
- </view>
- </view>
- <!-- 药品列表 -->
- <view class="shopbox" v-for="(shop,idx) in carts" :key="idx">
- <view class="shopbox-name" v-if="shop.storeName && shop.storeName != 'null'">
- <text>{{shop.storeName}}</text>
- </view>
- <view class="goods-list">
- <view v-for="(item,index) in shop.list" :key="index" class="item">
- <view class="img-box">
- <image :src="item.productAttrImage?item.productAttrImage:item.productImage"
- mode="aspectFill"></image>
- </view>
- <view class="info-box">
- <view>
- <view class="name-box ellipsis2">
- <view class="tag">{{utils.getDictLabelName("storeProductType",item.productType)}}
- </view>{{item.productName}}
- </view>
- <view class="spec ellipsis2">{{item.productAttrName}}</view>
- </view>
- <view class="price-num">
- <view class="price">
- <text class="unit">¥</text>
- <text class="num">{{item.price?.toFixed(2)}}</text>
- </view>
- <view class="num">x{{item.cartNum}}</view>
- </view>
- </view>
- </view>
- <!-- 运费 -->
- <view class="points">
- <view class="left">
- <text class="text">运费</text>
- </view>
- <view class="right" v-if="price&&price.length > 0">
- <text
- class="text">{{price[idx].payPostage==null||price[idx].payPostage==0?'免运费':price[idx].payPostage.toFixed(2)}}</text>
- </view>
- </view>
- <!-- 备注 -->
- <view class="points">
- <view class="left">
- <text class="text">备注</text>
- </view>
- <view class="remarks">
- <input type="text" v-model="shop.markinfo" placeholder="备注留言(选填)"
- placeholder-class="input" />
- </view>
- </view>
- </view>
- </view>
- <!-- 积分 -->
- <view class="price-info">
- <view class="price-info-title">价格明细</view>
- <view class="points">
- <view class="left">
- <text class="text">商品总价</text>
- </view>
- <view class="right" style="align-items: baseline;">
- <text class="price-info-unit">¥</text>
- <text class="price-info-num">{{price?.toFixed(2)}}</text>
- </view>
- </view>
- <!-- <view class="points">
- <view class="left">
- <image src="/static/images/points.png" mode=""></image>
- <text class="text">可用积分</text>
- </view>
- <view class="right">
- <text class="text">{{priceAll.usedIntegral}}积分</text>
- <evan-switch @change="integralChange" v-model="checked" activeColor="#0bb3f2"
- inactiveColor="rgba(0, 0, 0, 0.1)"></evan-switch>
- </view>
- </view> -->
- <!-- <view class="points" @click="openCoupon()">
- <view class="left">
- <text class="text">优惠券</text>
- </view>
- <view class="right">
- <text class="text">{{couponText}}</text>
- <image src="/static/images/arrow4.png" mode=""></image>
- </view>
- </view> -->
- <view class="points">
- <view class="left">
- <text class="text">合计</text>
- </view>
- <view class="right" style="align-items: baseline;">
- <text class="price-info-unit">¥</text>
- <text class="price-info-num">{{priceSum?.toFixed(2)}}</text>
- </view>
- </view>
- </view>
- <!-- <view class="points">
- <view class="left">
- <text class="text">运费</text>
- </view>
- <view class="right">
- <text class="text">{{price.payPostage==null||price.payPostage==0?'免运费':price.payPostage.toFixed(2)}}</text>
- </view>
- </view> -->
- <!-- 备注 -->
- <!-- <view class="remarks">
- <input type="text" v-model="form.mark" placeholder="备注留言(选填)" placeholder-class="input" />
- </view> -->
- </view>
- <!-- 底部按钮 -->
- <view class="btn-foot">
- <view class="right">
- <view class="total">
- <text class="label">合计:</text>
- <view class="price">
- <text class="unit">¥</text>
- <text class="num">{{priceSum?.toFixed(2)}}</text>
- </view>
- </view>
- <view class="btn" @click="submitOrder">提交订单</view>
- </view>
- </view>
- <popupBottom ref="popup" :visible.sync="couponVisible" title=" " bgColor="#f5f5f5" radius="30" maxHeight="60%">
- <view class="coupon" style="height:650rpx;">
- <div class="coupon-list" v-if="couponsList.length > 0">
- <div class="item acea-row row-center-wrapper" v-for="(item, index) in couponsList" :key="index">
- <div class="money">
- <image v-if="item.status==0" class="img" src="/static/images/coupon1.png" mode="widthFix">
- </image>
- <image v-if="item.status!=0" class="img" src="/static/images/coupon2.png" mode="widthFix">
- </image>
- <div style="z-index: 999;">
- ¥<span class="num">{{ item.couponPrice }}</span>
- </div>
- <div class="pic-num">满{{ item.useMinPrice }}元可用</div>
- </div>
- <div class="text">
- <div class="condition line1">
- {{ item.couponTitle }}
- </div>
- <div class="data acea-row row-between-wrapper">
- <div>{{ item.limitTime }}到期</div>
- <div class="bnt bg-color-red" @click="couponSelect(item)">选择</div>
- </div>
- </div>
- </div>
- </div>
- <view v-if="couponsList.length == 0" class="no-data-box">
- <image src="/static/images/no_data.png" mode="aspectFit"></image>
- <view class="empty-title">暂无数据</view>
- </view>
- </view>
- </popupBottom>
- </view>
- </template>
- <script>
- // import {getWeixinOrderTemps} from '@/api/common'
- // import {confirm,computed,create} from '@/api/storeOrder'
- // import { getMyEnableCouponList } from '@/api/coupon'
- import {
- createliveOrder, // 创建订单
- } from "@/api/order.js"
- import EvanSwitch from '@/components/evan-switch/evan-switch.vue'
- import popupBottom from '@/components/px-popup-bottom/px-popup-bottom.vue'
- export default {
- components: {
- EvanSwitch,
- popupBottom
- },
- data() {
- return {
- address: null,
- addressId: null,
- totalNum: null,
- orderKey: null,
- price: null,
- liveId: null,
- orderList: [],
- userInfo: null,
- userAddrLiat: [], //用户地址
- temps: [],
- couponUserId: null,
- couponText: "请选择",
- couponsList: [],
- couponVisible: false,
- priceAll: {
- payPrice: 0,
- totalPostage: 0,
- usedIntegral: 0,
- totalPrice: 0.00,
- },
- address: null,
- carts: [],
- checked: false,
- type: null,
- cartIds: null,
- // form:{
- // useIntegral:0,
- // orderKey:null,
- // addressId:null,
- // mark:null,
- // companyId:null,
- // companyUserId:null,
- // createOrderKey:null,
- // },
- confirmParam: []
- }
- },
- computed: {
- priceSum() {
- return this.price * this.totalNum;
- }
- },
- onLoad(options) {
- console.log("确认订单", options)
- this.orderKey = options.orderKey;
- this.liveId = options.liveId
- this.productId = options.productId
- this.totalNum = Number(options.totalNum)
- this.price = Number(options.price)
- // this.confirmParam = JSON.parse(decodeURIComponent(option.confirmParam))
- // this.form.createOrderKey=option.createOrderKey;
- // this.form.companyId= option.companyId;
- // this.form.companyUserId=option.companyUserId;
- // this.cartIds=option.cartIds;
- // this.type=option.type;
- // this.confirm();
- // uni.$on('updateAddress', (e) => {
- // console.log("e",e)
- // this.address=e;
- // this.addressId=e.id;
- // })
- // this.getWeixinOrderTemps();
- },
- mounted() {
- uni.$on('updateAddress', (e) => {
- this.address = e;
- this.addressId = e.addressId;
- });
- },
- beforeDestroy() {
- // 移除事件监听,避免内存泄漏
- uni.$off('updateAddress');
- },
- methods: {
- // 创建订单
- createLiveOrder() {
- let data = {
- liveId: this.liveId,
- orderKey: this.orderKey,
- // storeId:this.storeId,,
- userName: "没名字",
- userPhone: "1234568",
- userAddress: "随便住",
- // cartId:"5",
- productId: this.productId,
- totalNum: this.totalNum,
- // totalPrice:999,
- // remark:"随便备注",
- }
- return createliveOrder(data).then(res => { // 添加 return
- if (res.code == 200) {
- this.orderList = res.order;
- return res.order; // 返回订单数据供后续使用
- } else {
- uni.showToast({
- title: res.msg,
- icon: 'none'
- });
- throw new Error(res.msg); // 抛出错误以便 submitOrder 捕获
- }
- });
- },
- getWeixinOrderTemps: function() {
- getWeixinOrderTemps().then(
- res => {
- if (res.code == 200) {
- this.temps = res.temp
- } else {
- }
- },
- rej => {}
- );
- },
- couponSelect(item) {
- this.couponText = "-¥" + item.couponPrice.toFixed(2);
- this.couponUserId = item.id;
- this.couponVisible = false;
- this.computed();
- },
- openCoupon() {
- let that = this;
- var data = {
- couponType: 2,
- useMinPrice: this.price.payPrice
- };
- getMyEnableCouponList(data).then(res => {
- this.couponVisible = true;
- that.couponsList = res.data
- })
- },
- integralChange(e) {
- this.form.useIntegral = e ? 1 : 0
- this.computed()
- },
- // confirm(item) {
- // // let data = {type:this.type,cartIds:this.cartIds};
- // confirm(this.confirmParam).then(
- // res => {
- // if (res.code == 200) {
- // this.carts = res.carts.map(item => ({
- // ...item,
- // markinfo: ""
- // }));
- // this.form.orderKey = res.orderKeys;
- // if (res.address != null) {
- // this.form.addressId = res.address.id;
- // this.address = res.address;
- // }
- // this.computed()
- // } else {
- // uni.showToast({
- // icon: 'none',
- // title: res.msg,
- // });
- // }
- // },
- // rej => {}
- // );
- // },
- // computed(item) {
- // let data = {
- // createOrderKey: this.form.createOrderKey,
- // couponUserId: this.couponUserId,
- // orderKeys: this.form.orderKey,
- // addressId: this.form.addressId,
- // useIntegral: this.form.useIntegral
- // };
- // computed(data).then(
- // res => {
- // if (res.code == 200) {
- // // this.price=res.data
- // this.price = res.data && res.data.length > 0 ? res.data : []
- // this.priceAll = res.data && res.data.length > 0 ? res.data[res.data.length - 1] : {
- // payPrice: 0,
- // totalPostage: 0,
- // usedIntegral: 0,
- // totalPrice: 0.00,
- // }
- // } else {
- // if (res.code == 501) {
- // uni.showToast({
- // icon: 'none',
- // title: res.msg,
- // });
- // setTimeout(function() {
- // uni.navigateBack({
- // delta: 1
- // })
- // }, 500);
- // return;
- // } else {
- // uni.showToast({
- // icon: 'none',
- // title: res.msg,
- // });
- // }
- // }
- // },
- // rej => {}
- // );
- // },
- // 提交订单
- async submitOrder() {
- try {
- if (this.orderKey == null) {
- uni.showToast({
- icon: 'none',
- title: '订单KEY不存在',
- });
- return;
- }
- if (this.address == null) {
- uni.showToast({
- icon: 'none',
- title: '收货地址不能为空',
- });
- return;
- }
- const orderList = await this.createLiveOrder(); // 等待订单数据返回
- const orderListStr = encodeURIComponent(JSON.stringify(orderList));
- uni.navigateTo({
- url: `/pages_shop/paymentOrder?orderList=${orderListStr}`
- });
- } catch (error) {
- console.error('订单创建失败:', error);
- uni.showToast({
- title: '提交失败',
- icon: 'none'
- });
- }
- }
- // var that=this;
- // if(this.form.orderKey==null){
- // uni.showToast({
- // icon:'none',
- // title: '订单KEY不存在',
- // });
- // return;
- // }
- // if(this.form.addressId==null){
- // uni.showToast({
- // icon:'none',
- // title: '收货地址不能为空',
- // });
- // return;
- // }
- // uni.requestSubscribeMessage({
- // tmplIds: this.temps,
- // success(res) {
- // that.createOrder();
- // },
- // fail(res) {
- // that.createOrder();
- // }
- // })
- ,
- // createOrder() {
- // const mark = this.carts.map(item => item.markinfo)
- // var that = this;
- // var data = null;
- // var tuiUserId = uni.getStorageSync('tuiUserId');
- // uni.showLoading({
- // title: '正在处理中...'
- // });
- // if (tuiUserId != null && tuiUserId != undefined && tuiUserId > 0) {
- // data = {
- // createOrderKey: this.form.createOrderKey,
- // orderCreateType: 3,
- // tuiUserId: tuiUserId,
- // companyId: this.form.companyId,
- // companyUserId: this.form.companyUserId,
- // couponUserId: this.couponUserId,
- // mark: mark,
- // orderKeys: this.form.orderKey,
- // addressId: this.form.addressId,
- // useIntegral: this.form.useIntegral,
- // payType: 1
- // };
- // } else {
- // data = {
- // createOrderKey: this.form.createOrderKey,
- // orderCreateType: 3,
- // companyId: this.form.companyId,
- // companyUserId: this.form.companyUserId,
- // couponUserId: this.couponUserId,
- // mark: mark,
- // orderKeys: this.form.orderKey,
- // addressId: this.form.addressId,
- // useIntegral: this.form.useIntegral,
- // payType: 1
- // };
- // }
- // create(data).then(
- // res => {
- // uni.hideLoading()
- // if (!res.code && res.code !== 0) {
- // uni.hideLoading()
- // // if(res.order.isPrescribe==1){
- // // setTimeout(function(){
- // // uni.redirectTo({
- // // url:"prescribe?orderId="+res.order.id
- // // })
- // // },200);
- // // }
- // // else{
- // // setTimeout(function(){
- // // uni.redirectTo({
- // // url: './paymentOrder?orderId='+res.order.id
- // // })
- // // },200);
- // // }
- // if (res.some(item => item.order.isPrescribe) == 1) {
- // setTimeout(function() {
- // let orderIds = res.filter(item => item.order.isPrescribe == 1).map(it => it
- // .order.id)
- // orderIds = orderIds.join(',')
- // uni.redirectTo({
- // url: "prescribe?orderId=" + orderIds + "&combinationOrderId=" +
- // encodeURIComponent(res[0].order.combinationOrderId)
- // })
- // }, 200);
- // } else {
- // setTimeout(function() {
- // uni.redirectTo({
- // url: './paymentOrder?combinationOrderId=' + encodeURIComponent(
- // res[0].order.combinationOrderId)
- // })
- // }, 200);
- // }
- // return;
- // } else {
- // if (res.code == 501) {
- // uni.showToast({
- // icon: 'none',
- // title: res.msg,
- // });
- // setTimeout(function() {
- // uni.navigateBack({
- // delta: 1
- // })
- // }, 200);
- // return;
- // } else {
- // uni.showToast({
- // icon: 'none',
- // title: res.msg,
- // });
- // }
- // }
- // },
- // rej => {}
- // );
- // },
- openAddress() {
- uni.navigateTo({
- url: '/pages_user/address'
- })
- }
- }
- }
- </script>
- <style lang="scss">
- .inner-box {
- padding: 20upx 20upx 140upx;
- .address-box {
- margin-bottom: 20rpx;
- box-sizing: border-box;
- min-height: 171upx;
- background: #FFFFFF;
- border-radius: 16upx;
- // background-image: url(../../static/images/address_bg.png);
- background-repeat: no-repeat;
- background-size: 100% 30upx;
- background-position: left bottom;
- padding: 38upx 30upx 36upx;
- display: flex;
- align-items: center;
- justify-content: space-between;
- .left {
- width: 92%;
- .name-box {
- display: flex;
- align-items: center;
- .text {
- font-size: 32upx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #111111;
- line-height: 1;
- &.name {
- margin-right: 30upx;
- }
- }
- }
- .address {
- font-size: 28upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #666666;
- line-height: 42upx;
- text-align: left;
- margin-top: 23upx;
- }
- }
- .arrow-box {
- width: 12upx;
- height: 23upx;
- display: flex;
- align-items: cenetr;
- justify-content: cenetr;
- image {
- width: 100%;
- height: 100%;
- }
- }
- }
- .shopbox {
- background: #FFFFFF;
- border-radius: 16rpx;
- margin-bottom: 20rpx;
- .points {
- padding: 0 !important;
- }
- .remarks {
- padding: 0 !important;
- }
- }
- .shopbox-name {
- padding: 30rpx 30rpx 0 30rpx;
- font-family: PingFang SC, PingFang SC;
- font-weight: 400;
- font-size: 30rpx;
- color: #111;
- overflow: hidden;
- white-space: nowrap;
- text-overflow: ellipsis;
- }
- .goods-list {
- // margin-top: 20upx;
- padding: 0 30upx;
- background-color: #FFFFFF;
- border-radius: 16upx;
- .item {
- padding: 30upx 0;
- border-bottom: 1px solid #EDEEEF;
- display: flex;
- align-items: center;
- .img-box {
- width: 160upx;
- height: 160upx;
- margin-right: 30upx;
- image {
- width: 100%;
- height: 100%;
- }
- }
- .info-box {
- width: calc(100% - 190upx);
- height: 160upx;
- display: flex;
- flex-direction: column;
- justify-content: space-between;
- .name-box {
- font-size: 28upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #111111;
- line-height: 40upx;
- .tag {
- display: inline-block;
- padding: 0 6upx;
- height: 30upx;
- background: linear-gradient(90deg, #66b2ef 0%, #0bb3f2 100%);
- border-radius: 4upx;
- margin-right: 10upx;
- font-size: 22upx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #FFFFFF;
- line-height: 30upx;
- float: left;
- margin-top: 7upx;
- }
- }
- .spec {
- margin-top: 10upx;
- font-size: 24upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #999999;
- line-height: 1;
- }
- .price-num {
- display: flex;
- align-items: center;
- justify-content: space-between;
- .price {
- display: flex;
- align-items: flex-end;
- .unit {
- font-size: 24upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #111111;
- line-height: 1.2;
- margin-right: 4upx;
- }
- .num {
- font-size: 32upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #111111;
- line-height: 1;
- }
- }
- .num {
- font-size: 24upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #999999;
- line-height: 1;
- }
- }
- }
- }
- .sub-total {
- height: 88upx;
- display: flex;
- align-items: center;
- justify-content: flex-end;
- .label {
- font-size: 24upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #999999;
- }
- .price {
- display: flex;
- align-items: flex-end;
- .unit {
- font-size: 24upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #FF6633;
- line-height: 1.2;
- margin-right: 4upx;
- }
- .num {
- font-size: 32upx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #FF6633;
- line-height: 1;
- }
- }
- }
- }
- .price-info {
- background: #FFFFFF;
- border-radius: 16upx;
- &-title {
- padding: 30rpx 30rpx 20rpx 30rpx;
- font-family: PingFang SC, PingFang SC;
- font-weight: 500;
- font-size: 30rpx;
- color: #111;
- }
- &-unit {
- font-size: 24rpx;
- }
- &-num {
- font-size: 28rpx;
- }
- }
- .points {
- height: 88upx;
- padding: 0 30upx;
- background: #FFFFFF;
- border-radius: 16upx;
- display: flex;
- align-items: center;
- justify-content: space-between;
- .left {
- display: flex;
- align-items: center;
- image {
- width: 28upx;
- height: 28upx;
- margin-right: 20upx;
- }
- .text {
- font-size: 28upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #666666;
- }
- }
- .right {
- display: flex;
- align-items: center;
- .text {
- font-size: 28upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #111111;
- }
- image {
- margin-left: 15upx;
- width: 14upx;
- height: 24upx;
- }
- }
- }
- .remarks {
- // height: 88upx;
- padding: 0 30upx;
- background: #FFFFFF;
- border-radius: 16upx;
- margin-top: 20upx;
- display: flex;
- align-items: center;
- input {
- width: 100%;
- font-size: 28upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #000000;
- }
- .input {
- font-size: 28upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #999999;
- }
- }
- }
- .btn-foot {
- box-sizing: border-box;
- width: 100%;
- height: 121upx;
- background: #FFFFFF;
- padding: 16upx 30upx 16upx 60upx;
- display: flex;
- align-items: center;
- justify-content: flex-end;
- position: fixed;
- left: 0;
- bottom: 0;
- z-index: 99;
- .right {
- display: flex;
- align-items: center;
- .total {
- display: flex;
- align-items: flex-end;
- margin-right: 36upx;
- .label {
- font-size: 26upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #999999;
- line-height: 1.5;
- }
- .price {
- display: flex;
- align-items: flex-end;
- .unit {
- font-size: 32upx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #FF6633;
- line-height: 1.2;
- margin-right: 10upx;
- }
- .num {
- font-size: 50upx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #FF6633;
- line-height: 1;
- }
- }
- }
- .btn {
- width: 200upx;
- height: 88upx;
- line-height: 88upx;
- text-align: center;
- font-size: 30upx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #FFFFFF;
- background: #0bb3f2;
- border-radius: 44upx;
- }
- }
- }
- </style>
- <style lang="less" scoped>
- .coupon {
- height: 100%;
- }
- /*优惠券列表公共*/
- .coupon-list {}
- .coupon-list .item {
- display: flex;
- flex-direction: column;
- justify-content: center;
- align-items: center;
- width: 100%;
- height: 1.7 * 100rpx;
- margin-bottom: 0.16 * 100rpx;
- }
- .coupon-list .item .money {
- background-size: 100% 100%;
- width: 2.4 * 100rpx;
- height: 100%;
- color: #fff;
- font-size: 0.36 * 100rpx;
- font-weight: bold;
- text-align: center;
- display: flex;
- flex-direction: column;
- align-items: center;
- justify-content: center;
- position: relative;
- }
- .coupon-list .item .money .img {
- position: absolute;
- width: 2.4 * 100rpx;
- height: 100%;
- color: #fff;
- }
- .coupon-list .item .money .num {
- font-size: 0.6 * 100rpx;
- }
- .coupon-list .item .money .pic-num {
- font-size: 20rpx;
- z-index: 99;
- }
- .coupon-list .item .text {
- width: 4.5 * 100rpx;
- padding: 0 0.17 * 100rpx 0 0.24 * 100rpx;
- background-color: #fff;
- box-sizing: border-box;
- }
- .coupon-list .item .text .condition {
- font-size: 0.3 * 100rpx;
- color: #282828;
- height: 0.93 * 100rpx;
- line-height: 0.93 * 100rpx;
- border-bottom: 1px solid #f0f0f0;
- }
- .coupon-list .item .text .data {
- font-size: 0.2 * 100rpx;
- color: #999;
- height: 0.76 * 100rpx;
- }
- .coupon-list .item .text .data .bnt {
- width: 1.36 * 100rpx;
- height: 0.44 * 100rpx;
- border-radius: 0.22 * 100rpx;
- font-size: 0.22 * 100rpx;
- color: #fff;
- text-align: center;
- line-height: 0.44 * 100rpx;
- background-color: red;
- }
- .coupon-list .item .text .data .bnt.gray {
- background-color: #ccc;
- }
- </style>
|