From 15e86e0f4fdea84f506e3cd15b0987d00dbc56b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B5=85=E5=BF=B5?= Date: Tue, 9 Dec 2025 15:02:43 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=87=E8=B4=A7=E5=8D=95=20=E6=89=93?= =?UTF-8?q?=E5=8D=B0=E9=A2=84=E8=A7=88=20=E6=B7=BB=E5=8A=A0=20=E5=86=85?= =?UTF-8?q?=E5=8B=A4=E6=9F=A5=E7=9C=8B=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/crmpc/stocking/final_list.vue | 47 +++++++++++++++++++++ src/views/crmpc/stocking/stocking_list.vue | 48 ++++++++++++++++++++++ 2 files changed, 95 insertions(+) diff --git a/src/views/crmpc/stocking/final_list.vue b/src/views/crmpc/stocking/final_list.vue index 0f47bec..f67b3ce 100644 --- a/src/views/crmpc/stocking/final_list.vue +++ b/src/views/crmpc/stocking/final_list.vue @@ -166,6 +166,13 @@ style="flex: 1; width: 100%; border: 1px solid #eee; border-radius: 6px" /> +
+ +
([]) const timelineDialogVisible = ref(false) const isFinites = ref(false) const approvalRecords = ref([]) @@ -293,6 +303,36 @@ console.log(err) }) } + const handleViewnq = async (row: any) => { + const res = await manageService.checkStock({ id: row.id }) + // 默认币种来自 currency_symbol + if (res?.currency_symbol) { + nqCurrency.value = res.currency_symbol + } else { + nqCurrency.value = 'USD' + } + const list = Array.isArray(res?.veh_list) ? res.veh_list : [] + nqData.value = list.map((it: any) => ({ + model_snapshot: it.model_snapshot, + qty: 1, + clearance_price: it.clearance_price, + clearance_price_currency: it.clearance_price?.currency || it.clearance_price_currency, + fob_transport_fee: it.fob_transport_fee, + fob_fee_currency: it.fob_transport_fee?.currency || it.fob_fee_currency, + car_price: it.car_price, + car_price_currency: it.car_price?.currency || it.car_price_currency, + ocean_freight: it.ocean_freight, + ocean_freight_currency: it.ocean_freight?.currency || it.ocean_freight_currency, + commission: it.commission, + commission_currency: it.commission?.currency || it.commission_currency, + retention_price: it.retention_price, + retention_price_currency: it.retention_price?.currency || it.retention_price_currency, + port_misc_fee: it.port_misc_fee, + port_fee_currency: it.port_misc_fee?.currency || it.port_fee_currency, + model: it.model_snapshot + })) + // nqDialogVisible.value = true + } // PDF 预览/打印(公共) const { pdf, frameRef, openWithResponse, download, preparePreview, prepareImages } = usePdfPreview() @@ -303,6 +343,7 @@ } else { isFinites.value = false } + handleViewnq(row) CrmService.printStock({ id: row.id }) .then((res) => { openWithResponse(res) @@ -503,4 +544,10 @@ word-break: break-all; max-width: 100%; } + .inter-view { + margin-top: 10px; + padding: 10px; + border: 1px solid #ccc; + border-radius: 10px; + } \ No newline at end of file diff --git a/src/views/crmpc/stocking/stocking_list.vue b/src/views/crmpc/stocking/stocking_list.vue index 231d283..c4abcbd 100644 --- a/src/views/crmpc/stocking/stocking_list.vue +++ b/src/views/crmpc/stocking/stocking_list.vue @@ -207,6 +207,13 @@ style="flex: 1; width: 100%; border: 1px solid #eee; border-radius: 6px" /> +
+ +
@@ -261,9 +268,12 @@ import OrderDetailContent from '@/components/custom/OrderDetailContent.vue' import type { OrderData } from '@/composables/useOrderDetailDialog' import ApprovalTimeline from '@/components/custom/ApprovalTimeline.vue' + import InternalStaffViews from '@/components/custom/InternalStaffViews.vue' import FilePreview from '@/components/custom/FilePreview.vue' import { usePdfPreview } from '@/composables/usePdfPreview' import { manageService } from '@/api/adminApi' + const nqCurrency = ref('') + const nqData = ref([]) const timelineDialogVisible = ref(false) const approvalRecords = ref([]) const isFinites = ref(false) @@ -462,6 +472,37 @@ .catch((err) => { console.log(err) }) + } + const handleViewnq = async (row: any) => { + const res = await manageService.checkStock({ id: row.id }) + // 设置默认币种为数据中的 currency_symbol + if (res?.currency_symbol) { + nqCurrency.value = res.currency_symbol + } else { + nqCurrency.value = 'USD' // 兜底默认值 + } + // 取车辆明细列表作为行 + const list = Array.isArray(res?.veh_list) ? res.veh_list : [] + nqData.value = list.map((it: any) => ({ + model_snapshot: it.model_snapshot, + qty: 1, + clearance_price: it.clearance_price, + clearance_price_currency: it.clearance_price?.currency || it.clearance_price_currency, + fob_transport_fee: it.fob_transport_fee, + fob_fee_currency: it.fob_transport_fee?.currency || it.fob_fee_currency, + car_price: it.car_price, + car_price_currency: it.car_price?.currency || it.car_price_currency, + ocean_freight: it.ocean_freight, + ocean_freight_currency: it.ocean_freight?.currency || it.ocean_freight_currency, + commission: it.commission, + commission_currency: it.commission?.currency || it.commission_currency, + retention_price: it.retention_price, + retention_price_currency: it.retention_price?.currency || it.retention_price_currency, + port_misc_fee: it.port_misc_fee, + port_fee_currency: it.port_misc_fee?.currency || it.port_fee_currency, + model: it.model_snapshot + })) + // nqDialogVisible.value = true } // PDF 预览/打印(公共) const { pdf, frameRef, openWithResponse, download, preparePreview, prepareImages } = @@ -473,6 +514,7 @@ } else { isFinites.value = false } + handleViewnq(row) CrmService.printStock({ id: row.id }) .then((res) => { openWithResponse(res) @@ -608,4 +650,10 @@ color: #ff0000; font-weight: bold; } + .inter-view { + margin-top: 10px; + padding: 10px; + border: 1px solid #ccc; + border-radius: 10px; + }