yxh
2026-10-03 d553a4be94d4f6ee162cc353a28b220403909cfc
src/views/ecg/doctor/Routine.vue
@@ -7,6 +7,7 @@
import TitlePanel from '@/views/ecg/doctor/components/TitlePanel.vue'
import QueuePanel from '@/views/ecg/doctor/components/QueuePanel.vue'
import DoctorPageLayout from '@/components/DoctorPageLayout/src/DoctorPageLayout.vue'
import { DoctorApi, PatientStatisticVO, RoomBedVO, } from '@/api/ecg/doctor'
import { QueueVO } from '@/api/ecg/queue'
import { ElMessage, ElMessageBox, ElNotification } from 'element-plus'
@@ -129,8 +130,8 @@
  }
  try {
    await ElMessageBox.confirm(
      `确定撤销「${last.patName || last.patId}」的检查完成吗?该患者将回到候诊区。`,
      '撤销检查完成',
      `确定撤销「${last.patName || last.patId}」的「完成」状态吗?该患者将回到候诊区。`,
      '撤销',
      { type: 'warning', confirmButtonText: '确定撤销', cancelButtonText: '取消' }
    )
  } catch {
@@ -143,7 +144,7 @@
      patId: last.patId,
      checkType: last.bookCheckType
    } as any)
    ElMessage.success(msg || '已撤销检查完成')
    ElMessage.success(msg || '已撤销')
    await initLoad()
  } finally {
    undoFlag.value = false
@@ -170,6 +171,35 @@
  try {
    patientList.value = await DoctorApi.passNextPatient(roomBedVO)
    patientStat.value = await DoctorApi.getPatientStatistic(roomBedVO)
    // ========================================================================
    // 【修复】过号后同样要**清空左上方患者信息**,表示可以叫下一位了。
    //
    // 原先只调 getOnstagePatient(),而该方法在找不到 status===30 的患者时
    // **什么都不做**(它内部那行 setOnStagePatient(undefined) 是被注释掉的),
    // 于是过号后左上角仍留着上一位患者的信息,医生会以为还在处理他。
    // 这里与「检查完成」(onEventRoutine) 保持一致的收尾动作。
    // ========================================================================
    onStagePatient = {
      id: 0,
      patId: '',
      patName: '',
      patGender: 0,
      bookTimeslot: 0,
      bookCheckType: 0,
      isVip: 0,
      seqNum: 0,
      bookSeqNum: 0,
      passed: 0,
      expired: 0,
      jumpFlag: 0,
      roomId: 0,
      roomName: '',
      bedNo: '',
      status: 0
    }
    routimePanelRef.value?.setPatient(undefined)
    getOnstagePatient()
  } finally {
    passFlag.value = false
@@ -313,23 +343,37 @@
</script>
<template>
  <el-container>
    <el-header style="background-color: var(--el-color-primary-light-7); font-size: 24px">
  <!--
    布局优化:功能按钮固定在页面底部,不再用 position:absolute 浮在内容上。
    · 标题栏固定在顶部
    · 中间区(患者信息 + 已完成记录列表)为滚动区,患者信息由 RoutinePanel 内部设为
      sticky 钉在顶部,只有记录列表滚动
    · 右侧患者队列独立滚动
    · 「叫号/过号/重叫/暂停/撤销叫号」等按钮进 #footer,固定在底部,永不被记录列表遮挡
    详见 components/DoctorPageLayout。
  -->
  <DoctorPageLayout>
    <template #header>
      <TitlePanel :titleType="0" :room="roomBedVO" :patientStatistic="patientStat" />
    </el-header>
    <el-container style="height: 100%">
      <el-main style="border: solid var(--el-color-primary-light-7)">
        <RoutinePanel :room="roomBedVO" :setappointmentId="setappointmentId" ref="routimePanelRef" @event_routine="onEventRoutine" />
      </el-main>
      <el-aside width="400px" style="border: solid var(--el-color-primary-light-7)">
        <QueuePanel
          :room="roomBedVO"
          :queue="patientList"
          @event_RecallFinish="onEventRecallFinish"
        />
      </el-aside>
    </el-container>
    <el-container class="right-bottom">
    </template>
    <RoutinePanel
      :room="roomBedVO"
      :setappointmentId="setappointmentId"
      ref="routimePanelRef"
      :undo-disabled="undoFlag"
      :undo-loading="undoFlag"
      @event_routine="onEventRoutine"
      @event_undo_finish="undoFinish"
    />
    <template #aside>
      <QueuePanel :room="roomBedVO" :queue="patientList" @event_RecallFinish="onEventRecallFinish" />
    </template>
    <!-- 底部控件:自动 + 功能按钮 + 停止候诊,整组靠右 -->
    <template #footer>
      <!-- 自动 复选框 -->
      <el-checkbox label="自动&nbsp;" v-model="autoCall" />
      <el-button :disabled="finishFlag" type="primary" @click="finishNextPatient">叫号</el-button>
      <el-button :disabled="passFlag" type="primary" @click="passNextPatient">过号</el-button>
@@ -344,23 +388,18 @@
        active-text="停止候诊"
        inactive-text="正常接诊"
        inline-prompt
        style="margin-left: 12px; --el-switch-on-color: #e6a23c"
        style="--el-switch-on-color: #e6a23c"
        @change="onStopReadyChange"
      />
      <!-- 需求2:撤销误点叫号 / 撤销检查完成(均回到候诊区) -->
      <!-- 需求2:撤销误点叫号(回到候诊区)。
           需求11:「撤销完成」已改名为「撤销」,并移到「已完成检查记录列表」的最前面。 -->
      <el-button :disabled="undoFlag" type="warning" plain @click="undoCall">撤销叫号</el-button>
      <el-button :disabled="undoFlag" type="warning" plain @click="undoFinish">撤销完成</el-button>
    </el-container>
  </el-container>
    </template>
  </DoctorPageLayout>
</template>
<style scoped lang="scss">
.right-bottom {
  position: absolute;
  bottom: 50px;
  right: 80px;
  //background-color: #f00;
  //color: #fff;
  //padding: 10px;
}
</style>
<!--
  原先这里有 .right-bottom { position:absolute; bottom:50px; right:80px },
  正是"记录列表变长后盖住功能按钮"的根因(按钮脱离文档流、不占布局空间)。
  现改由 DoctorPageLayout 的 #footer 承载:正常文档流中的固定底栏,无需偏移。
-->