From edd91185a11239a77f6f897557f32cf3231b58a2 Mon Sep 17 00:00:00 2001 From: tikkhun Date: Sun, 4 Jan 2026 21:32:47 +0800 Subject: [PATCH] =?UTF-8?q?feat(woocommerce):=20=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E8=AE=A2=E5=8D=95=E5=85=83=E6=95=B0=E6=8D=AE=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 添加 date_paid、utm_source、device_type 和 source_type 字段到订单数据转换逻辑中,以支持订单来源追踪功能 --- src/adapter/woocommerce.adapter.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/adapter/woocommerce.adapter.ts b/src/adapter/woocommerce.adapter.ts index 30860b3..3fd13c7 100644 --- a/src/adapter/woocommerce.adapter.ts +++ b/src/adapter/woocommerce.adapter.ts @@ -481,7 +481,10 @@ export class WooCommerceAdapter implements ISiteAdapter { ...li, productId: li.product_id, })), - + date_paid: item.date_paid ?? '', + utm_source: item?.meta_data?.find(el => el.key === '_wc_order_attribution_utm_source')?.value || '', + device_type: item?.meta_data?.find(el => el.key === '_wc_order_attribution_device_type')?.value || '', + source_type: item?.meta_data?.find(el => el.key === '_wc_order_attribution_source_type')?.value || '', billing: item.billing, shipping: item.shipping, billing_full_address: this.buildFullAddress(item.billing),