摸大红支持购物车多选一起结账
下单支持多商品行快照与一次支付;支付后整单复制文案,前台提供购物车加购与结账。
This commit is contained in:
@@ -148,14 +148,27 @@ async function copyText() {
|
||||
</div>
|
||||
<div>
|
||||
<h2>{{ order.product_title }}</h2>
|
||||
<p>
|
||||
<p v-if="!order.items?.length">
|
||||
¥{{ order.unit_price || formatCent(order.unit_price_cent) }} × {{ order.quantity }}
|
||||
{{ order.product_unit }}
|
||||
</p>
|
||||
<p v-else>共 {{ order.items.length }} 种 · {{ order.quantity }} 件</p>
|
||||
<strong>合计 ¥{{ order.amount || formatCent(order.amount_cent) }}</strong>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-if="order.items?.length" class="items-box">
|
||||
<h3>商品明细</h3>
|
||||
<div v-for="item in order.items" :key="item.product_id" class="item-row">
|
||||
<span class="item-title">{{ item.title }}</span>
|
||||
<span
|
||||
>¥{{ item.unit_price || formatCent(item.unit_price_cent) }} × {{ item.quantity }}
|
||||
{{ item.unit }}</span
|
||||
>
|
||||
<strong>¥{{ item.amount || formatCent(item.amount_cent) }}</strong>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-if="order.copy_text" class="copy-box">
|
||||
<div class="copy-head">
|
||||
<h3>订单信息(发给客服)</h3>
|
||||
@@ -396,6 +409,36 @@ async function copyText() {
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.items-box {
|
||||
margin-top: 4px;
|
||||
padding: 12px 0 4px;
|
||||
border-top: 1px solid #eef1f5;
|
||||
}
|
||||
.items-box h3 {
|
||||
margin: 0 0 10px;
|
||||
font-size: 14px;
|
||||
color: #17233d;
|
||||
}
|
||||
.item-row {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) auto auto;
|
||||
gap: 10px;
|
||||
padding: 8px 0;
|
||||
border-bottom: 1px solid #f1f5f9;
|
||||
font-size: 13px;
|
||||
color: #475569;
|
||||
}
|
||||
.item-row:last-child {
|
||||
border-bottom: 0;
|
||||
}
|
||||
.item-title {
|
||||
color: #0f172a;
|
||||
font-weight: 600;
|
||||
}
|
||||
.item-row strong {
|
||||
color: #ff6a00;
|
||||
}
|
||||
|
||||
.copy-box,
|
||||
.qr-box {
|
||||
margin-top: 16px;
|
||||
|
||||
Reference in New Issue
Block a user