From 09a423b8dc9b1716ef07c0ab5cf2f02641bb3c94 Mon Sep 17 00:00:00 2001 From: lq Date: Sat, 8 Nov 2025 15:05:52 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=90=84=E7=A7=8D=E6=8F=90=E4=BA=A4?= =?UTF-8?q?=EF=BC=88=E6=97=A5=E5=BF=97=E7=9B=B8=E5=85=B3=E3=80=81=E7=BB=84?= =?UTF-8?q?=E4=BB=B6=E5=B0=81=E8=A3=85=E7=9B=B8=E5=85=B3=E3=80=81=E8=AE=A2?= =?UTF-8?q?=E5=8D=95=E7=9B=B8=E5=85=B3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../form/components/input-select.vue | 33 ++ apps/web-antd/src/store/prescription.ts | 16 +- .../chat/components/MessageBubble.vue | 355 ++++++++++++------ .../chat/components/PrescriptionModal.vue | 139 ++++++- .../src/views/business/chat/stores/chat.ts | 3 +- .../order/product-order/components/detail.vue | 12 +- .../order/product-order/config/search.ts | 20 + .../business/order/product-order/index.vue | 25 +- .../product/western-medicine/config/form.ts | 39 ++ .../product/western-medicine/config/table.ts | 2 +- .../product/western-medicine/index.vue | 1 + .../business/store/settings/api/index.ts | 7 + .../settings/components/SalespersonCard.vue | 156 ++++---- .../components/SalespersonCreateModal.vue | 15 +- .../business/store/settings/config/form.ts | 35 +- .../warehouse-drug-management/admin/index.vue | 19 +- .../store/api/index.ts | 14 + .../warehouse-drug-management/store/index.vue | 27 +- .../src/views/dashboard/workspace/index.vue | 15 +- .../components/WesternModal.vue | 10 +- .../finance/withdrawal/api/settlement.ts | 8 + .../withdrawal/components/statistics.vue | 8 + .../withdrawal/config/settlement-search.ts | 9 + .../withdrawal/config/settlement-table.ts | 60 ++- .../src/views/finance/withdrawal/index.vue | 75 +++- .../views/log/api-log/components/modal.vue | 3 +- .../src/views/log/api-log/config/search.ts | 16 +- .../src/views/log/api-log/config/table.ts | 1 + .../src/views/system/admin/config/form.ts | 2 +- 29 files changed, 885 insertions(+), 240 deletions(-) create mode 100644 apps/web-antd/src/components/form/components/input-select.vue diff --git a/apps/web-antd/src/components/form/components/input-select.vue b/apps/web-antd/src/components/form/components/input-select.vue new file mode 100644 index 00000000..2aae5548 --- /dev/null +++ b/apps/web-antd/src/components/form/components/input-select.vue @@ -0,0 +1,33 @@ + + + diff --git a/apps/web-antd/src/store/prescription.ts b/apps/web-antd/src/store/prescription.ts index c50479e8..1a20127c 100644 --- a/apps/web-antd/src/store/prescription.ts +++ b/apps/web-antd/src/store/prescription.ts @@ -16,6 +16,7 @@ import { getProcessRuleList, getProductListDoctorReception, } from '#/views/doctor/doctor-reception/api'; +import traditionalJson from '#/views/business/chat/config/traditional.json'; export const usePrescriptionStore = defineStore('prescription', () => { // 基础数据 @@ -73,6 +74,11 @@ export const usePrescriptionStore = defineStore('prescription', () => { const isInitialized = ref(false); const isPatientInfoLoaded = ref(false); + const traditionalChineseMedicine = ref(traditionalJson); + const diseasesSelected = ref(); + const methodSelected = ref(); + const syndromeSelected = ref(); + // 获取localStorage key const getStorageKey = () => `prescriptionData-chat-${currentRegisterId.value}`; @@ -590,6 +596,7 @@ export const usePrescriptionStore = defineStore('prescription', () => { // 发送处方 const sendPrescription = async (doctorSecondSignValue = 0) => { + if (currentDrugs.value.length === 0) { message.error('请选择药品'); return false; @@ -625,7 +632,6 @@ export const usePrescriptionStore = defineStore('prescription', () => { message.error('医嘱不能为空'); return false; } - try { await addWestPrescription({ patient: activePatient.value, @@ -647,6 +653,10 @@ export const usePrescriptionStore = defineStore('prescription', () => { dosage: dosage.value, day_dosage: dayDosage.value, doctor_second_sign: doctorSecondSignValue, + // 中医在线问诊所需的东西 + diseases_id: diseasesSelected.value, + method_id: methodSelected.value, + syndrome_id: syndromeSelected.value, }).then((res) => { message.success('处方已发送'); sendMessage({ @@ -798,5 +808,9 @@ export const usePrescriptionStore = defineStore('prescription', () => { syncToLocalStorage, loadFromLocalStorage, updateCurrentDrugs, + traditionalChineseMedicine, + diseasesSelected, + methodSelected, + syndromeSelected, }; }); diff --git a/apps/web-antd/src/views/business/chat/components/MessageBubble.vue b/apps/web-antd/src/views/business/chat/components/MessageBubble.vue index e9f7af68..a9f088ef 100644 --- a/apps/web-antd/src/views/business/chat/components/MessageBubble.vue +++ b/apps/web-antd/src/views/business/chat/components/MessageBubble.vue @@ -1,25 +1,39 @@