Merge branch 'Branch_1' of https://git.u8t.cn/tangxinyue/alipay-emulator into Branch_1
This commit is contained in:
commit
dab4d15c24
|
|
@ -138,6 +138,9 @@
|
||||||
<text style="font-size: 22rpx; color: #999;">旗舰店 </text>
|
<text style="font-size: 22rpx; color: #999;">旗舰店 </text>
|
||||||
<switch :checked="order.shop.hasFlagship" @change="(e) => order.shop.hasFlagship = e.detail.value"
|
<switch :checked="order.shop.hasFlagship" @change="(e) => order.shop.hasFlagship = e.detail.value"
|
||||||
color="#E02E24" style="transform: scale(0.6); margin-left: -10rpx; margin-right: -20rpx;" />
|
color="#E02E24" style="transform: scale(0.6); margin-left: -10rpx; margin-right: -20rpx;" />
|
||||||
|
<text style="font-size: 22rpx; color: #999;">618 </text>
|
||||||
|
<switch :checked="order.shop.has618" @change="(e) => order.shop.has618 = e.detail.value" color="#E02E24"
|
||||||
|
style="transform: scale(0.6); margin-left: -10rpx; margin-right: -20rpx;" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
|
@ -155,6 +158,8 @@
|
||||||
</image>
|
</image>
|
||||||
<image v-if="order.shop.hasFlagship" class="flagship-tag"
|
<image v-if="order.shop.hasFlagship" class="flagship-tag"
|
||||||
src="/static/image/shopping/pdd/qijiandian.png" mode="heightFix"></image>
|
src="/static/image/shopping/pdd/qijiandian.png" mode="heightFix"></image>
|
||||||
|
<image v-if="order.shop.has618" style="margin-left: 8rpx;height: 28rpx;" class="flagship-tag"
|
||||||
|
src="/static/image/shopping/pdd/618.png" mode="heightFix"></image>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 商品主要内容 -->
|
<!-- 商品主要内容 -->
|
||||||
|
|
@ -166,8 +171,10 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="info-box flex-1">
|
<view class="info-box flex-1">
|
||||||
<view class="title-price flex">
|
<view class="title-price flex">
|
||||||
<view class="title text-ellipsis-2 flex-1">
|
<view class="title flex-1">
|
||||||
<auto-width-input type="textarea" v-model="product.title" show-edit />
|
<!-- <auto-width-input type="textarea" v-model="product.title" show-edit /> -->
|
||||||
|
<auto-width-input class="flex-1" v-model="product.title" fontSize="28rpx" color="#1A1A1A"
|
||||||
|
type="textarea" show-edit />
|
||||||
</view>
|
</view>
|
||||||
<view class="price-box flex-column align-end">
|
<view class="price-box flex-column align-end">
|
||||||
<text class="price">¥<auto-width-input v-model="product.price" type="number"
|
<text class="price">¥<auto-width-input v-model="product.price" type="number"
|
||||||
|
|
@ -176,7 +183,7 @@
|
||||||
show-edit /></text>
|
show-edit /></text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="spec text-ellipsis-2">
|
<view class="spec">
|
||||||
<auto-width-input type="textarea" v-model="product.spec" show-edit />
|
<auto-width-input type="textarea" v-model="product.spec" show-edit />
|
||||||
</view>
|
</view>
|
||||||
<view class="tags flex-align-center" style="flex-wrap: wrap; gap: 8rpx 0;">
|
<view class="tags flex-align-center" style="flex-wrap: wrap; gap: 8rpx 0;">
|
||||||
|
|
@ -287,7 +294,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<uni-popup ref="timepopup" type="bottom">
|
<uni-popup ref="timepopup" type="bottom" :z-index="9999" style="z-index: 9999;">
|
||||||
<view class="timeBox">
|
<view class="timeBox">
|
||||||
<view class="titleBox">
|
<view class="titleBox">
|
||||||
<view class="title" @click="closeTimePicker">取消</view>
|
<view class="title" @click="closeTimePicker">取消</view>
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,8 @@
|
||||||
</image>
|
</image>
|
||||||
<image class="flag-img" v-if="item.shop?.hasFlagship" src="/static/image/shopping/pdd/qijiandian.png">
|
<image class="flag-img" v-if="item.shop?.hasFlagship" src="/static/image/shopping/pdd/qijiandian.png">
|
||||||
</image>
|
</image>
|
||||||
|
<image v-if="item.shop?.has618" style="margin-left: 8rpx;height: 28rpx;" class="flagship-tag"
|
||||||
|
src="/static/image/shopping/pdd/618.png" mode="heightFix"></image>
|
||||||
<uni-icons style="margin-top: 4rpx;" type="right" color="#999999" size="12"></uni-icons>
|
<uni-icons style="margin-top: 4rpx;" type="right" color="#999999" size="12"></uni-icons>
|
||||||
</view>
|
</view>
|
||||||
<view class="status-text" v-if="item.orderType === 'wait_pay'">待支付</view>
|
<view class="status-text" v-if="item.orderType === 'wait_pay'">待支付</view>
|
||||||
|
|
@ -27,7 +29,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="product-content flex-1">
|
<view class="product-content flex-1">
|
||||||
<view class="title-box">
|
<view class="title-box">
|
||||||
<view class="brand-tag flex-center" v-if="item.shop?.hasBrandAuth">品牌</view>
|
<text class="brand-tag" v-if="item.shop?.hasBrandAuth">品牌</text>
|
||||||
<text class="title-text">{{ product.title }}</text>
|
<text class="title-text">{{ product.title }}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="spec-text text-ellipsis">{{ product.spec }}</view>
|
<view class="spec-text text-ellipsis">{{ product.spec }}</view>
|
||||||
|
|
@ -224,8 +226,7 @@ const toDetail = (id) => {
|
||||||
.product-box {
|
.product-box {
|
||||||
padding: 0 24rpx;
|
padding: 0 24rpx;
|
||||||
padding-bottom: 14rpx;
|
padding-bottom: 14rpx;
|
||||||
margin-bottom: 10rpx;
|
// border-bottom: 1rpx solid #EFEFEF;
|
||||||
border-bottom: 1rpx solid #EFEFEF;
|
|
||||||
|
|
||||||
.product-img-box {
|
.product-img-box {
|
||||||
width: 148rpx;
|
width: 148rpx;
|
||||||
|
|
@ -246,6 +247,7 @@ const toDetail = (id) => {
|
||||||
width: 0;
|
width: 0;
|
||||||
|
|
||||||
.title-box {
|
.title-box {
|
||||||
|
width: 100%;
|
||||||
font-size: 26rpx;
|
font-size: 26rpx;
|
||||||
color: #1A1A1A;
|
color: #1A1A1A;
|
||||||
line-height: 36rpx;
|
line-height: 36rpx;
|
||||||
|
|
@ -253,22 +255,21 @@ const toDetail = (id) => {
|
||||||
-webkit-box-orient: vertical;
|
-webkit-box-orient: vertical;
|
||||||
-webkit-line-clamp: 2;
|
-webkit-line-clamp: 2;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
word-break: break-all;
|
||||||
|
|
||||||
.brand-tag {
|
.brand-tag {
|
||||||
display: inline-block;
|
|
||||||
background-color: #252525;
|
background-color: #252525;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
font-size: 22rpx;
|
font-size: 22rpx;
|
||||||
line-height: 22rpx;
|
line-height: 22rpx;
|
||||||
padding: 4rpx 8rpx;
|
padding: 2rpx 8rpx;
|
||||||
border-radius: 4rpx;
|
border-radius: 4rpx;
|
||||||
margin-right: 8rpx;
|
margin-right: 8rpx;
|
||||||
margin-top: -4rpx;
|
position: relative;
|
||||||
|
top: -2rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.title-text {
|
.title-text {}
|
||||||
vertical-align: middle;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.spec-text {
|
.spec-text {
|
||||||
|
|
@ -328,6 +329,7 @@ const toDetail = (id) => {
|
||||||
margin-bottom: 16rpx;
|
margin-bottom: 16rpx;
|
||||||
padding: 0 16rpx;
|
padding: 0 16rpx;
|
||||||
padding-bottom: 14rpx;
|
padding-bottom: 14rpx;
|
||||||
|
padding-top: 10rpx;
|
||||||
|
|
||||||
&::after {
|
&::after {
|
||||||
content: "";
|
content: "";
|
||||||
|
|
@ -337,8 +339,20 @@ const toDetail = (id) => {
|
||||||
right: 0;
|
right: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 1px;
|
height: 1px;
|
||||||
transform: scaleY(0.3);
|
transform: scaleY(0.5);
|
||||||
background-color: #D2D2D2;
|
background-color: #EFEFEF;
|
||||||
|
}
|
||||||
|
|
||||||
|
&::before {
|
||||||
|
content: "";
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 1px;
|
||||||
|
transform: scaleY(0.5);
|
||||||
|
background-color: #EFEFEF;
|
||||||
}
|
}
|
||||||
|
|
||||||
.avatar-group {
|
.avatar-group {
|
||||||
|
|
@ -474,13 +488,21 @@ const toDetail = (id) => {
|
||||||
}
|
}
|
||||||
|
|
||||||
.delivery-content {
|
.delivery-content {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
font-size: 24rpx;
|
font-size: 24rpx;
|
||||||
|
white-space: nowrap;
|
||||||
|
|
||||||
.green-text {
|
.green-text {
|
||||||
color: #2BB40C;
|
color: #2BB40C;
|
||||||
}
|
}
|
||||||
|
|
||||||
.gray-text {
|
.gray-text {
|
||||||
|
flex: 1;
|
||||||
|
overflow: hidden;
|
||||||
|
white-space: nowrap;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
width: 100px;
|
||||||
color: #595959;
|
color: #595959;
|
||||||
margin-left: 10rpx;
|
margin-left: 10rpx;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,8 @@
|
||||||
"name": "",
|
"name": "",
|
||||||
"logo": "",
|
"logo": "",
|
||||||
"hasBrandAuth": true,
|
"hasBrandAuth": true,
|
||||||
"hasFlagship": true
|
"hasFlagship": true,
|
||||||
|
"has618": false
|
||||||
},
|
},
|
||||||
"products": [
|
"products": [
|
||||||
{
|
{
|
||||||
|
|
@ -64,7 +65,8 @@
|
||||||
"name": "",
|
"name": "",
|
||||||
"logo": "",
|
"logo": "",
|
||||||
"hasBrandAuth": true,
|
"hasBrandAuth": true,
|
||||||
"hasFlagship": true
|
"hasFlagship": true,
|
||||||
|
"has618": false
|
||||||
},
|
},
|
||||||
"products": [
|
"products": [
|
||||||
{
|
{
|
||||||
|
|
@ -144,7 +146,8 @@
|
||||||
"name": "",
|
"name": "",
|
||||||
"logo": "",
|
"logo": "",
|
||||||
"hasBrandAuth": true,
|
"hasBrandAuth": true,
|
||||||
"hasFlagship": true
|
"hasFlagship": true,
|
||||||
|
"has618": false
|
||||||
},
|
},
|
||||||
"products": [
|
"products": [
|
||||||
{
|
{
|
||||||
|
|
@ -490,8 +493,9 @@
|
||||||
"shop": {
|
"shop": {
|
||||||
"name": "索尼(SONY)数码官方旗舰店",
|
"name": "索尼(SONY)数码官方旗舰店",
|
||||||
"logo": "",
|
"logo": "",
|
||||||
"hasBrandAuth": true,
|
"hasBrandAuth": false,
|
||||||
"hasFlagship": true
|
"hasFlagship": false,
|
||||||
|
"has618": true
|
||||||
},
|
},
|
||||||
"products": [
|
"products": [
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,17 @@
|
||||||
<view class="nav-bar">
|
<view class="nav-bar">
|
||||||
<nav-bar v-if="!selectedImage" :buttonGroup="buttonGroup" @button-click="util.clickTitlePopupButton"
|
<nav-bar v-if="!selectedImage" :buttonGroup="buttonGroup" @button-click="util.clickTitlePopupButton"
|
||||||
tipLayerType="pdd-shopping-list" isTipLayer tipLayerText="添加订单信息">
|
tipLayerType="pdd-shopping-list" isTipLayer tipLayerText="添加订单信息">
|
||||||
|
|
||||||
|
<!-- 使用作用域插槽自定义按钮渲染,特别是switch的checked绑定 -->
|
||||||
|
<template #button="{ button }">
|
||||||
|
<view class="button flex-align-center flex-justify-center">
|
||||||
|
{{ button.name }}
|
||||||
|
<view @tap.stop>
|
||||||
|
<switch v-if="button.isSwitch" :checked="couponInfo[button.key]" @change="button.click"
|
||||||
|
style="transform: scale(0.7);"></switch>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
<template v-slot:left>
|
<template v-slot:left>
|
||||||
<image style="width: 48rpx;height: 48rpx;" src="/static/image/shopping/pdd/back.png"
|
<image style="width: 48rpx;height: 48rpx;" src="/static/image/shopping/pdd/back.png"
|
||||||
@click="util.goBack()">
|
@click="util.goBack()">
|
||||||
|
|
@ -43,6 +54,20 @@
|
||||||
</scroll-view>
|
</scroll-view>
|
||||||
<scroll-view class="flex-1" style="height: 100px;" scroll-y="true" :scroll-into-view="scrollIntoId"
|
<scroll-view class="flex-1" style="height: 100px;" scroll-y="true" :scroll-into-view="scrollIntoId"
|
||||||
scroll-with-animation>
|
scroll-with-animation>
|
||||||
|
<view v-if="couponInfo.show618Coupon" class="flex-align-center coupon-banner">
|
||||||
|
<image style="width: 32rpx;height: 28rpx;margin-right: 10rpx;"
|
||||||
|
src="/static/image/shopping/pdd/coupon-logo.png">
|
||||||
|
</image>
|
||||||
|
<view class="flex-align-center flex-1">
|
||||||
|
<text class="red">618</text>
|
||||||
|
<text>降价正式开始!再送</text>
|
||||||
|
<text class="red">{{ couponInfo.coupon618Amount || '188' }}元</text>
|
||||||
|
<text>优惠券</text>
|
||||||
|
</view>
|
||||||
|
<uni-icons type="right" size="14" color="#B7B7B7"></uni-icons>
|
||||||
|
</view>
|
||||||
|
<image v-if="couponInfo.hasCoupon" style="width: 100%;height: 300rpx;"
|
||||||
|
:src="couponInfo.couponPath || '/static/image/shopping/pdd/coupon1.png'" mode="widthFix"></image>
|
||||||
<list-card v-for="(item, index) in filteredOrderList" :key="index" :item="item"
|
<list-card v-for="(item, index) in filteredOrderList" :key="index" :item="item"
|
||||||
@longpress="handleLongPress($event, item)"></list-card>
|
@longpress="handleLongPress($event, item)"></list-card>
|
||||||
<view v-if="filteredOrderList.length == 0" class="null-data-box flex-align-center">
|
<view v-if="filteredOrderList.length == 0" class="null-data-box flex-align-center">
|
||||||
|
|
@ -95,6 +120,52 @@
|
||||||
<c-lottie ref="cLottieRef" :src='$watermark()' width="94px" height='74px' :loop="true"></c-lottie>
|
<c-lottie ref="cLottieRef" :src='$watermark()' width="94px" height='74px' :loop="true"></c-lottie>
|
||||||
</liu-drag-button>
|
</liu-drag-button>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
<!-- 优惠券弹窗 -->
|
||||||
|
<uni-popup ref="couponPopup" type="center">
|
||||||
|
<view class="popup-content"
|
||||||
|
style="width: 620rpx; background-color: #fff; border-radius: 24rpx; padding: 40rpx 30rpx; box-sizing: border-box;">
|
||||||
|
<view class="flex-align-center flex-between" style="margin-bottom: 30rpx;">
|
||||||
|
<text style="font-size: 34rpx; font-weight: 500; color: #1A1A1A;">618活动券展示</text>
|
||||||
|
<switch :checked="tempCouponInfo.show618Coupon"
|
||||||
|
@change="(e) => tempCouponInfo.show618Coupon = e.detail.value" color="#E02E24"
|
||||||
|
style="transform: scale(0.8);" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<view v-if="tempCouponInfo.show618Coupon" class="flex-align-center flex-between"
|
||||||
|
style="margin-bottom: 30rpx;">
|
||||||
|
<text style="font-size: 30rpx; color: #1A1A1A;">设置618优惠券额度</text>
|
||||||
|
<input type="text" v-model="tempCouponInfo.coupon618Amount" placeholder="如 188"
|
||||||
|
style="text-align: right; border: 1px solid #ddd; border-radius: 8rpx; padding: 4rpx 16rpx; width: 140rpx; font-size: 28rpx;" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<view style="height: 1px; background-color: #f5f5f5; margin-bottom: 30rpx;"></view>
|
||||||
|
|
||||||
|
<view class="flex-align-center flex-between" style="margin-bottom: 30rpx;">
|
||||||
|
<text style="font-size: 34rpx; font-weight: 500; color: #1A1A1A;">普通优惠券展示</text>
|
||||||
|
<switch :checked="tempCouponInfo.hasCoupon"
|
||||||
|
@change="(e) => tempCouponInfo.hasCoupon = e.detail.value" color="#E02E24"
|
||||||
|
style="transform: scale(0.8);" />
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<scroll-view scroll-y v-if="tempCouponInfo.hasCoupon" class="coupon-options flex-column"
|
||||||
|
style="max-height: 55vh;">
|
||||||
|
<view class="coupon-item"
|
||||||
|
v-for="(img, idx) in ['/static/image/shopping/pdd/coupon1.png', '/static/image/shopping/pdd/coupon2.png', '/static/image/shopping/pdd/coupon3.png']"
|
||||||
|
:key="idx" @click="tempCouponInfo.couponPath = img"
|
||||||
|
:style="{ border: tempCouponInfo.couponPath === img ? '4rpx solid #E02E24' : '4rpx solid transparent', marginBottom: '20rpx', borderRadius: '16rpx', overflow: 'hidden', padding: '4rpx' }">
|
||||||
|
<image :src="img" style="width: 100%; display: block; border-radius: 12rpx;" mode="widthFix">
|
||||||
|
</image>
|
||||||
|
</view>
|
||||||
|
</scroll-view>
|
||||||
|
|
||||||
|
<view class="flex-center" style="margin-top: 40rpx;">
|
||||||
|
<view class="btn primary flex-center"
|
||||||
|
style="width: 100%; border-radius: 40rpx; padding: 22rpx 0; text-align: center; background-color: #E02E24; color: #fff; font-size: 32rpx; font-weight: 500;"
|
||||||
|
@click="saveCouponInfo">确认保存</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</uni-popup>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|
@ -111,6 +182,33 @@ const { proxy } = getCurrentInstance();
|
||||||
const activeTab = ref(0);
|
const activeTab = ref(0);
|
||||||
const scrollIntoId = ref('');
|
const scrollIntoId = ref('');
|
||||||
|
|
||||||
|
// 优惠券配置
|
||||||
|
const couponInfo = ref({
|
||||||
|
show618Coupon: true,
|
||||||
|
coupon618Amount: '188',
|
||||||
|
hasCoupon: true,
|
||||||
|
couponPath: '/static/image/shopping/pdd/coupon1.png'
|
||||||
|
});
|
||||||
|
const tempCouponInfo = ref({
|
||||||
|
show618Coupon: true,
|
||||||
|
coupon618Amount: '188',
|
||||||
|
hasCoupon: true,
|
||||||
|
couponPath: '/static/image/shopping/pdd/coupon1.png'
|
||||||
|
});
|
||||||
|
const couponPopup = ref(null);
|
||||||
|
|
||||||
|
const openCouponPopup = () => {
|
||||||
|
tempCouponInfo.value = JSON.parse(JSON.stringify(couponInfo.value));
|
||||||
|
couponPopup.value.open();
|
||||||
|
};
|
||||||
|
|
||||||
|
const saveCouponInfo = () => {
|
||||||
|
couponInfo.value = JSON.parse(JSON.stringify(tempCouponInfo.value));
|
||||||
|
uni.setStorageSync('pddCouponInfo', couponInfo.value);
|
||||||
|
couponPopup.value.close();
|
||||||
|
uni.showToast({ title: '保存成功', icon: 'success' });
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
//导航栏菜单按钮
|
//导航栏菜单按钮
|
||||||
const buttonGroup = [
|
const buttonGroup = [
|
||||||
|
|
@ -132,7 +230,12 @@ const buttonGroup = [
|
||||||
chooseImage();
|
chooseImage();
|
||||||
}, 400);
|
}, 400);
|
||||||
}
|
}
|
||||||
},
|
}, {
|
||||||
|
name: "设置优惠券",
|
||||||
|
click: () => {
|
||||||
|
openCouponPopup();
|
||||||
|
}
|
||||||
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
onLoad(() => {
|
onLoad(() => {
|
||||||
|
|
@ -328,6 +431,11 @@ const filteredOrderList = computed(() => {
|
||||||
});
|
});
|
||||||
|
|
||||||
onShow(() => {
|
onShow(() => {
|
||||||
|
const pddCouponInfo = uni.getStorageSync('pddCouponInfo');
|
||||||
|
if (pddCouponInfo) {
|
||||||
|
couponInfo.value = pddCouponInfo;
|
||||||
|
}
|
||||||
|
|
||||||
const isInitialized = uni.getStorageSync('isPddOrderListInitialized');
|
const isInitialized = uni.getStorageSync('isPddOrderListInitialized');
|
||||||
if (!isInitialized) {
|
if (!isInitialized) {
|
||||||
uni.setStorageSync('pddOrderList', defaultDataList);
|
uni.setStorageSync('pddOrderList', defaultDataList);
|
||||||
|
|
@ -756,6 +864,19 @@ const closeImage = () => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.coupon-banner {
|
||||||
|
background-color: #FEF5B2;
|
||||||
|
padding: 20rpx 22rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 26rpx;
|
||||||
|
color: #1A1A1A;
|
||||||
|
line-height: 26rpx;
|
||||||
|
|
||||||
|
.red {
|
||||||
|
color: #DF2E26;
|
||||||
|
}
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
<style>
|
<style>
|
||||||
@import '@/common/main.css';
|
@import '@/common/main.css';
|
||||||
|
|
|
||||||
|
|
@ -30,15 +30,18 @@
|
||||||
<!-- 头部信息卡片:优惠券 + 物流 + 地址 -->
|
<!-- 头部信息卡片:优惠券 + 物流 + 地址 -->
|
||||||
<view class="header-info-card">
|
<view class="header-info-card">
|
||||||
<!-- 优惠券横幅 -->
|
<!-- 优惠券横幅 -->
|
||||||
<view v-if="order.orderType !== 'wait_pay' && order.couponInfo"
|
<view v-if="couponInfo.show618Coupon && order.orderType !== 'wait_pay'"
|
||||||
class="coupon-banner flex-align-center flex-justify-between">
|
class="flex-align-center coupon-banner">
|
||||||
<view class="flex-align-center">
|
<image style="width: 32rpx;height: 28rpx;margin-right: 10rpx;"
|
||||||
<view class="coupon-icon flex-center">¥</view>
|
src="/static/image/shopping/pdd/coupon-logo.png">
|
||||||
<text class="black-text">{{ order.couponInfo.title }}</text>
|
</image>
|
||||||
<text class="red-text">{{ order.couponInfo.priceText }}</text>
|
<view class="flex-align-center flex-1">
|
||||||
<text class="black-text">{{ order.couponInfo.timeText }}</text>
|
<text class="red">618</text>
|
||||||
|
<text>降价正式开始!再送</text>
|
||||||
|
<text class="red">{{ couponInfo.coupon618Amount || '188' }}元</text>
|
||||||
|
<text>优惠券</text>
|
||||||
</view>
|
</view>
|
||||||
<uni-icons type="right" size="14" color="#D3D3D3"></uni-icons>
|
<uni-icons type="right" size="14" color="#B7B7B7"></uni-icons>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 物流信息 -->
|
<!-- 物流信息 -->
|
||||||
|
|
@ -74,12 +77,6 @@
|
||||||
<view v-if="order.orderType == 'wait_pay'" class="edit-btn">修改</view>
|
<view v-if="order.orderType == 'wait_pay'" class="edit-btn">修改</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="false" class="upload-shop-logo-box flex-justify-between flex-align-center">
|
|
||||||
<text>上传店铺头像</text>
|
|
||||||
<view>
|
|
||||||
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
<view class="product-card">
|
<view class="product-card">
|
||||||
<!-- 店铺信息 -->
|
<!-- 店铺信息 -->
|
||||||
<view class="shop-header flex-align-center">
|
<view class="shop-header flex-align-center">
|
||||||
|
|
@ -92,6 +89,8 @@
|
||||||
</image>
|
</image>
|
||||||
<image v-if="order.shop.hasFlagship" class="flagship-tag"
|
<image v-if="order.shop.hasFlagship" class="flagship-tag"
|
||||||
src="/static/image/shopping/pdd/qijiandian.png" mode="heightFix"></image>
|
src="/static/image/shopping/pdd/qijiandian.png" mode="heightFix"></image>
|
||||||
|
<image v-if="order.shop.has618" style="margin-left: 12rpx;height: 28rpx;" class="flagship-tag"
|
||||||
|
src="/static/image/shopping/pdd/618.png" mode="heightFix"></image>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 商品主要内容 -->
|
<!-- 商品主要内容 -->
|
||||||
|
|
@ -210,7 +209,7 @@
|
||||||
<!-- 底部固定支付栏 -->
|
<!-- 底部固定支付栏 -->
|
||||||
<view v-if="order.orderType == 'wait_pay'" class="fixed-bottom-bar flex-justify-between">
|
<view v-if="order.orderType == 'wait_pay'" class="fixed-bottom-bar flex-justify-between">
|
||||||
<!-- 样式 2:先用后付 (activePayIndex === 2) -->
|
<!-- 样式 2:先用后付 (activePayIndex === 2) -->
|
||||||
<view class="left-info style-2 flex-column" v-if="activePayIndex === 2">
|
<view class="left-info style-2 flex-column" v-if="order.activePayIndex === 2">
|
||||||
<view class="line-top flex-align-end">
|
<view class="line-top flex-align-end">
|
||||||
<text class="label">实付款: </text>
|
<text class="label">实付款: </text>
|
||||||
<text class="symbol">¥</text>
|
<text class="symbol">¥</text>
|
||||||
|
|
@ -259,7 +258,7 @@
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { ref, computed, getCurrentInstance } from 'vue';
|
import { ref, computed, getCurrentInstance } from 'vue';
|
||||||
import { onLoad } from '@dcloudio/uni-app';
|
import { onLoad, onShow } from '@dcloudio/uni-app';
|
||||||
import { stringUtil } from '@/utils/common.js';
|
import { stringUtil } from '@/utils/common.js';
|
||||||
import { util } from '@/utils/common.js';
|
import { util } from '@/utils/common.js';
|
||||||
|
|
||||||
|
|
@ -275,14 +274,7 @@ const buttonGroup = [
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
onLoad(() => {
|
|
||||||
proxy.$apiUserEvent('all', {
|
|
||||||
type: 'event',
|
|
||||||
key: 'shopping',
|
|
||||||
prefix: '.uni.other.',
|
|
||||||
value: '拼多多订单详情'
|
|
||||||
})
|
|
||||||
})
|
|
||||||
const isOrderInfoExpanded = ref(false);
|
const isOrderInfoExpanded = ref(false);
|
||||||
const order = ref({
|
const order = ref({
|
||||||
orderType: 'wait_recv',
|
orderType: 'wait_recv',
|
||||||
|
|
@ -361,9 +353,33 @@ const payList = ref([
|
||||||
{ name: '云闪付', icon: '/static/image/shopping/pdd/pay/yunshanfu-blue.png' }
|
{ name: '云闪付', icon: '/static/image/shopping/pdd/pay/yunshanfu-blue.png' }
|
||||||
])
|
])
|
||||||
|
|
||||||
|
const id = ref('')
|
||||||
onLoad((option) => {
|
onLoad((option) => {
|
||||||
|
id.value = option.id
|
||||||
|
proxy.$apiUserEvent('all', {
|
||||||
|
type: 'event',
|
||||||
|
key: 'shopping',
|
||||||
|
prefix: '.uni.other.',
|
||||||
|
value: '拼多多订单详情'
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
// 优惠券配置
|
||||||
|
const couponInfo = ref({
|
||||||
|
show618Coupon: true,
|
||||||
|
coupon618Amount: '188',
|
||||||
|
hasCoupon: true,
|
||||||
|
couponPath: '/static/image/shopping/pdd/coupon1.png'
|
||||||
|
});
|
||||||
|
|
||||||
|
onShow(() => {
|
||||||
const cacheList = uni.getStorageSync('pddOrderList');
|
const cacheList = uni.getStorageSync('pddOrderList');
|
||||||
order.value = cacheList.find(item => item.id == option.id);
|
order.value = cacheList.find(item => item.id == id.value);
|
||||||
|
|
||||||
|
const pddCouponInfo = uni.getStorageSync('pddCouponInfo');
|
||||||
|
if (pddCouponInfo) {
|
||||||
|
couponInfo.value = pddCouponInfo;
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -831,13 +847,12 @@ const selectPayMethod = (index) => {
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
width: 76rpx;
|
width: 76rpx;
|
||||||
height: 42rpx;
|
height: 40rpx;
|
||||||
border-radius: 8rpx;
|
border-radius: 8rpx;
|
||||||
border: 1rpx solid #9E9E9E;
|
border: 1rpx solid #9E9E9E;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
font-size: 26rpx;
|
font-size: 26rpx;
|
||||||
color: #535353;
|
color: #535353;
|
||||||
line-height: 26rpx;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.arrow {
|
.arrow {
|
||||||
|
|
@ -1040,6 +1055,19 @@ const selectPayMethod = (index) => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.coupon-banner {
|
||||||
|
background-color: #FCF6D6;
|
||||||
|
padding: 20rpx 22rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 26rpx;
|
||||||
|
color: #1A1A1A;
|
||||||
|
line-height: 26rpx;
|
||||||
|
|
||||||
|
.red {
|
||||||
|
color: #DF2E26;
|
||||||
|
}
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
<style>
|
<style>
|
||||||
@import '@/common/main.css';
|
@import '@/common/main.css';
|
||||||
|
|
|
||||||
Binary file not shown.
|
After Width: | Height: | Size: 1.7 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 631 B |
Binary file not shown.
|
After Width: | Height: | Size: 106 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 84 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 87 KiB |
Loading…
Reference in New Issue