add product sku
This commit is contained in:
@@ -96,7 +96,7 @@
|
||||
</div>
|
||||
<div class="main">
|
||||
<div class="title">
|
||||
<span class="name text-bold" v-text="item.productNameSnapshot" />
|
||||
<span class="name text-bold" v-text="getItemTitle(item)" />
|
||||
<t-tag
|
||||
:content="getItemFulfillmentStatus(item).text"
|
||||
:theme="getItemFulfillmentStatus(item).theme"
|
||||
@@ -110,6 +110,13 @@
|
||||
v-text="`¥${formatPackageAmount(item.lineAmount)}`"
|
||||
/>
|
||||
<t-tag v-else size="small" content="套餐权益" />
|
||||
<t-tag
|
||||
v-if="item.skuCodeSnapshot || item.skuNameSnapshot || item.specSummarySnapshot"
|
||||
size="small"
|
||||
theme="primary"
|
||||
variant="light"
|
||||
:content="item.skuCodeSnapshot || item.skuNameSnapshot || item.specSummarySnapshot"
|
||||
/>
|
||||
<t-tag size="small" theme="primary" variant="light" :content="item.unitSnapshot" />
|
||||
</div>
|
||||
</div>
|
||||
@@ -250,6 +257,11 @@ const canCancel = computed(() => !!order.value && order.value.status === "ACTIVE
|
||||
const canFulfillByPayment = computed(() => order.value?.paymentStatus === "PAID" || (order.value?.paymentStatus === "PARTIALLY_PAID" && canOperateStock.value));
|
||||
const photoURLList = computed(() => photoItems.value.map(item => item.url));
|
||||
|
||||
function getItemTitle(item: GaoSalesOrderItem): string {
|
||||
const skuText = item.skuNameSnapshot || item.specSummarySnapshot;
|
||||
return `${item.productNameSnapshot || "未命名产品"}${skuText ? ` · ${skuText}` : ""}`;
|
||||
}
|
||||
|
||||
function toPhotoItems(attachmentList?: readonly Partial<Attachment>[]): PhotoItem[] {
|
||||
return (attachmentList || [])
|
||||
.filter(item => !!item.id)
|
||||
|
||||
Reference in New Issue
Block a user