弃检逻辑修改

This commit is contained in:
Euni4U 2025-03-25 10:46:56 +08:00
parent e66d1cddac
commit 38400a3924

View File

@ -420,6 +420,7 @@ import { PacsDataApi } from '@/api/inspect/inspectpacsdata' // 导入PacsDataApi
import { getStrDictOptions } from '@/utils/dict' //
import Summary from './summary.vue' // Summary
import TemplateDrawer from './Drawer-Template.vue'
import { updateItemsAnalyse } from '@/api/summary'
const dialogTitle = ref('体检报告')
const { t } = useI18n() //
@ -2221,13 +2222,28 @@ const handleAbandonExam = async () => {
}
//
const updatedItems = currentItems.map(item => ({
id: item.id,
medicalSn: selectedPatient.value?.medicalSn,
itemStatus: '2', //
inspectdoctor: inspectDoctor.value || user.value?.nickname || '',
inspecttime: Date.now() // 使
}))
const updatedItems = currentItems.map(item => {
const baseFields = {
id: item.id,
medicalSn: selectedPatient.value?.medicalSn,
itemStatus: '2' //
}
//
if (currentTab.value === 'ultrasound' || currentTab.value === 'ecg') {
return {
...baseFields,
examDescription: '已弃检',
itemResult: '已弃检',
analyse: '检查所见:已弃检\n检查结果已弃检'
}
} else {
return {
...baseFields,
analyse: '该项目已弃检'
}
}
})
//
await PatientitemsApi.updatePatientitemsBatch(updatedItems)
@ -2235,6 +2251,21 @@ const handleAbandonExam = async () => {
//
currentItems.forEach(item => {
item.itemStatus = '2'
if (currentTab.value === 'ultrasound' || currentTab.value === 'ecg') {
item.value = '已弃检'
//
if (currentTab.value === 'ultrasound') {
conclusionData.value.ultrasound.finding = '已弃检'
conclusionData.value.ultrasound.diagnosis = '已弃检'
} else if (currentTab.value === 'ecg') {
conclusionData.value.ecg.finding = '已弃检'
conclusionData.value.ecg.diagnosis = '已弃检'
}
} else {
item.analyse = '该项目已弃检'
}
})
loading.close()