diff --git a/src/components/outpatient/Case.vue b/src/components/outpatient/Case.vue index 9154e11..c473412 100644 --- a/src/components/outpatient/Case.vue +++ b/src/components/outpatient/Case.vue @@ -77,7 +77,7 @@ import PopoverInput from "@/components/PopoverInput.vue"; import DiagnosisSearchInput from "@/components/outpatient/DiagnosisSearchInput.vue"; import PhysiqueExamInput from "@/components/outpatient/PhysiqueExamInput.vue"; import {apiConfig} from "@/assets/config/apiConfig.ts"; - +import {API} from "@/assets/config/API.ts"; const props = defineProps({ disabled: { type: Boolean, diff --git a/src/components/outpatient/MedicalHistory.vue b/src/components/outpatient/MedicalHistory.vue index d9cb250..a6bf1c1 100644 --- a/src/components/outpatient/MedicalHistory.vue +++ b/src/components/outpatient/MedicalHistory.vue @@ -27,7 +27,7 @@ import DiseaseDetails from './DiseaseDetails.vue'; import {post} from "@/utils/request.ts"; import {ref} from "vue"; import {formatListTime} from "@/utils/dateUtils.ts"; -import {API} from "@/assets/config/API.ts"; +import {API, Base} from "@/assets/config/API.ts"; const props = defineProps({ status: { @@ -37,7 +37,7 @@ const props = defineProps({ }) const list = ref([]) const init = (patientId: any) => { - post(API.Diagnosis.ListByPatient, {patientId: patientId}).then((res: any) => { + post(API.Diagnosis.Base.ListByPatient, {patientId: patientId}).then((res: any) => { list.value = res }) } diff --git a/src/components/outpatient/MedicalQueue.vue b/src/components/outpatient/MedicalQueue.vue index 9374286..3dd6fb2 100644 --- a/src/components/outpatient/MedicalQueue.vue +++ b/src/components/outpatient/MedicalQueue.vue @@ -105,7 +105,7 @@ onMounted(() => { } // 启动定时器,每秒更新一次 refreshInterval = setInterval(() => { - initList() + init() }, 60 * 1000); // 每1000毫秒(即1秒)执行一次 }) onUnmounted(() => { @@ -115,30 +115,6 @@ onUnmounted(() => { refreshInterval = null; } }); -const initList = async () => { - selectedDateStr.value = setDateTip() - try { - let data: any = await post(API.Patient.Registration.AllList, { - query: { - status: curStatus.value, - beginTime: selectedDate.value, - endTime: getEndOfDay(new Date(selectedDate.value)) - } - }, {catch_error: true}); - list.value = data.list - if (itemId.value != null) { - list.value.forEach((item: any, index: any) => { - if (item.id == itemId.value && curStatus.value == 2) { - clickLi(item, false) - } - }) - } - } catch (e) { - - } finally { - } - initStatusList() -} const loading = ref(true) const init = async () => { selectedDateStr.value = setDateTip() @@ -169,7 +145,7 @@ const init = async () => { initStatusList() } const initStatusList = () => { - post(API.Patient.Registration.ChangeStatus, { + post(API.Statistics.Base.GetQueueCount, { beginTime: selectedDate.value, endTime: getEndOfDay(new Date(selectedDate.value)) }).then((res: any) => { diff --git a/src/components/registration/Edit.vue b/src/components/registration/Edit.vue index f4ca63c..d4bb0c5 100644 --- a/src/components/registration/Edit.vue +++ b/src/components/registration/Edit.vue @@ -312,7 +312,7 @@ const save = () => { } if (edit_data.value.id) { - post(API.Patient.Base.Update, { + post(API.Patient.Registration.Edit, { data: data, mdtrtCertNo: socialCard.value?.mdtrtCertNo, mdtrtCertType: socialCard.value?.mdtrtCertType }).then(() => { @@ -320,7 +320,7 @@ const save = () => { close() }) } else { - post(API.Patient.Base.Create, { + post(API.Patient.Registration.Add, { data: data, mdtrtCertNo: socialCard.value?.mdtrtCertNo, mdtrtCertType: socialCard.value?.mdtrtCertType