From 7b91cb4230ca59fc79837ebdbbe52a573244fa5c Mon Sep 17 00:00:00 2001 From: v6ole Date: Sun, 12 Jul 2026 20:34:34 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E7=A7=BB=E5=8A=A8=E7=AB=AF=E7=BC=96?= =?UTF-8?q?=E8=BE=91=E8=A1=A8=E5=8D=95=E8=87=AA=E5=8A=A8=E8=A1=A5=E5=85=85?= =?UTF-8?q?=E5=AE=A2=E6=88=B7=E5=88=B0=E9=80=89=E9=A1=B9=E5=88=97=E8=A1=A8?= =?UTF-8?q?=EF=BC=8C=E9=81=BF=E5=85=8D=E6=98=BE=E7=A4=BAUUID?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude --- frontend/src/views/mobile/KeyVisitForm.vue | 3 +++ frontend/src/views/mobile/MiniBusinessForm.vue | 3 +++ frontend/src/views/mobile/WorkPlanForm.vue | 3 +++ 3 files changed, 9 insertions(+) diff --git a/frontend/src/views/mobile/KeyVisitForm.vue b/frontend/src/views/mobile/KeyVisitForm.vue index 251db30..586868f 100644 --- a/frontend/src/views/mobile/KeyVisitForm.vue +++ b/frontend/src/views/mobile/KeyVisitForm.vue @@ -46,6 +46,9 @@ onMounted(async () => { try { const res = await api.get(`/key-visits/${route.params.id}`) const d = res.data + if (d.customer_id && d.customer_name && !customers.value.find((c: any) => c.id === d.customer_id)) { + customers.value.unshift({ id: d.customer_id, name: d.customer_name }) + } form.value = { customer_id: d.customer_id, urgency_level: d.urgency_level, description: d.description || '', progress_status: d.progress_status, planned_date: d.planned_date, planned_visitor: d.planned_visitor, visit_target: d.visit_target, manager_id: d.manager_id || auth.userId || '' } } catch (_) {} } diff --git a/frontend/src/views/mobile/MiniBusinessForm.vue b/frontend/src/views/mobile/MiniBusinessForm.vue index 7d508ec..261a843 100644 --- a/frontend/src/views/mobile/MiniBusinessForm.vue +++ b/frontend/src/views/mobile/MiniBusinessForm.vue @@ -34,6 +34,9 @@ onMounted(async () => { try { const res = await api.get(`/mini-business/${route.params.id}`) const d = res.data + if (d.customer_id && d.customer_name && !customers.value.find((c: any) => c.id === d.customer_id)) { + customers.value.unshift({ id: d.customer_id, name: d.customer_name }) + } form.value = { customer_id: d.customer_id, product_type: d.product_type, amount: d.amount, follow_up_detail: d.follow_up_detail || '', status: d.status, expected_revenue_date: d.expected_revenue_date, manager_id: d.manager_id || auth.userId || '' } } catch (_) {} } diff --git a/frontend/src/views/mobile/WorkPlanForm.vue b/frontend/src/views/mobile/WorkPlanForm.vue index 2792c83..647a2bb 100644 --- a/frontend/src/views/mobile/WorkPlanForm.vue +++ b/frontend/src/views/mobile/WorkPlanForm.vue @@ -33,6 +33,9 @@ onMounted(async () => { try { const res = await api.get(`/work-plans/${route.params.id}`) const d = res.data + if (d.customer_id && d.customer_name && !customers.value.find((c: any) => c.id === d.customer_id)) { + customers.value.unshift({ id: d.customer_id, name: d.customer_name }) + } form.value = { customer_id: d.customer_id, plan_content: d.plan_content || '', plan_date: d.plan_date, status: d.status, manager_id: d.manager_id || auth.userId || '' } } catch (_) {} }