| | |
| | | </div> |
| | | |
| | | <div style="display: flex; flex-wrap: wrap; justify-content: center; margin-bottom: 20px"> |
| | | <div v-for="_appointment in appointmentVOList" :key="_appointment.applyNo"> |
| | | <CheckItemPanel :appointment="_appointment" /> |
| | | <div v-for="(_appointment, index) in appointmentVOList" :key="index"> |
| | | <CheckItemPanel :appointment="_appointment" @event_appoint_confirm="onEventAppointConfirm"/> |
| | | </div> |
| | | </div> |
| | | |
| | |
| | | <el-radio |
| | | v-for="dict in getIntDictOptions(DICT_TYPE.SYSTEM_USER_SEX)" |
| | | :key="dict.value" |
| | | :value="dict.value" |
| | | > |
| | | :value="dict.value"> |
| | | {{ dict.label }} |
| | | </el-radio> |
| | | </el-radio-group> |
| | |
| | | <script setup lang="ts"> |
| | | import {DICT_TYPE, getIntDictOptions} from '@/utils/dict' |
| | | import { AppointmentApi, AppointmentVO } from '@/api/ecg/appointment' |
| | | import {useCheckTypeStore} from "@/store/modules/checkType"; |
| | | import CheckItemPanel from "@/views/ecg/appointment/CheckItemPanel.vue"; |
| | | import {getCheckTypeName} from "@/utils/checkTypeFormatter"; |
| | | |
| | | /** 预约确认 表单 */ |
| | | defineOptions({ name: 'AppointmentConfirm' }) |
| | | |
| | | const checkTypeStore = useCheckTypeStore(); |
| | | |
| | | const queryParams = reactive({ |
| | | patId: '' |
| | |
| | | const formData = ref<AppointmentVO>({ |
| | | id: 0, |
| | | applyNo: "", |
| | | episodeId: "", |
| | | patSrc: 0, |
| | | patId: "", |
| | | patName: "", |
| | |
| | | patWardCode: "", |
| | | patWardDesc: "", |
| | | patBedNo: "", |
| | | bookId: "", |
| | | bookTime: new Date(), |
| | | bookDate: new Date(), |
| | | bookTimeslot: 9301030, |
| | | bookCheckType: checkTypeStore.getCheckTypeName(100), |
| | | bookCheckType: getCheckTypeName(100), |
| | | paid: 0, |
| | | bookSeqNum: 0, |
| | | }) |
| | | const formRef = ref() // 表单 Ref |
| | | |
| | | const searchBookInfo = async () => { |
| | | resetForm() |
| | | |
| | | if (null === queryParams.patId || "" === queryParams.patId) |
| | | if (null === queryParams.patId || "" === queryParams.patId.trim()) |
| | | return |
| | | |
| | | const data = await AppointmentApi.queryAndCreateAppointmentByPatId(queryParams.patId) // 对应数据库中 pat_id |
| | | const _patId = queryParams.patId.trim() |
| | | console.warn("===" + _patId + "===") |
| | | |
| | | const data = await AppointmentApi.queryAndCreateAppointmentByPatId(_patId) // 对应数据库中 pat_id |
| | | console.info( data ) |
| | | appointmentVOList.value = data |
| | | if (null !== data) { |
| | | if (null !== data && data.length > 0) { |
| | | formData.value = data[0] |
| | | appointmentVOList.value = data |
| | | console.info( formData.value ) |
| | | return |
| | | } |
| | |
| | | |
| | | /** 重置表单 */ |
| | | const resetForm = () => { |
| | | appointmentVOList.value.length=0; |
| | | formData.value = { |
| | | id: 0, |
| | | applyNo: "", |
| | | episodeId: "", |
| | | patSrc: 0, |
| | | patId: "", |
| | | patName: "", |
| | |
| | | patWardCode: "", |
| | | patWardDesc: "", |
| | | patBedNo: "", |
| | | bookId: "", |
| | | bookTime: new Date(), |
| | | bookDate: new Date(), |
| | | bookTimeslot: 9301030, |
| | | bookCheckType: checkTypeStore.getCheckTypeName(100), |
| | | bookCheckType: getCheckTypeName(100), |
| | | paid: 0, |
| | | bookSeqNum: 0, |
| | | } |
| | | formRef.value?.resetFields() |
| | | } |
| | | |
| | | const onEventAppointConfirm = () => { |
| | | /* |
| | | if (null !== appointmentVOList.value && appointmentVOList.value.length === 1) { |
| | | queryParams.patId = "" |
| | | } |
| | | */ |
| | | queryParams.patId = "" |
| | | } |
| | | |
| | | /** 初始化 **/ |
| | | onMounted(() => { |
| | | resetForm() |