eight
2024-08-30 943d2875938ca95f7c1071cd242d67e19e03a613
update
已修改5个文件
78 ■■■■■ 文件已修改
src/api/ecg/doctor/index.ts 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/api/ecg/queue/index.ts 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/ecg/doctor/index.vue 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/ecg/queue/index.vue 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/ecg/room/RoomLoginSelect.vue 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/api/ecg/doctor/index.ts
@@ -22,6 +22,31 @@
// 医生 API
export const DoctorApi = {
  // 医生暂停,暂时不接收患者
  bedDoctorPause: async (params) => {
    return await request.get({ url: `/ecg/doctor/bed-doctor-pause`, params })
  },
  // 医生恢复,恢复接收患者
  bedDoctorResume: async (params) => {
    return await request.get({ url: `/ecg/doctor/bed-doctor-resume`, params })
  },
  // 医生入座,
  bedDoctorOn: async (params) => {
    return await request.get({ url: `/ecg/doctor/bed-doctor-on`, params })
  },
  // 医生离座,
  bedDoctorOff: async (params) => {
    return await request.get({ url: `/ecg/doctor/bed-doctor-off`, params })
  },
  // 获取医生的工位信息
  bedDoctorGet: async (params) => {
    return await request.get({ url: `/ecg/doctor/bed-doctor-get`, params })
  },
  // 看完,取下一位患者
  finishNextPatient: async (params: RoomBedVO) => {
    return await request.get({ url: `/ecg/doctor/finish-next-patient`, params })
src/api/ecg/queue/index.ts
@@ -70,31 +70,6 @@
    return await request.get({ url: `/ecg/queue/bed-close`, params })
  },
  // 医生暂停,暂时不接收患者
  bedDoctorPause: async (params) => {
    return await request.get({ url: `/ecg/queue/bed-doctor-pause`, params })
  },
  // 医生恢复,恢复接收患者
  bedDoctorResume: async (params) => {
    return await request.get({ url: `/ecg/queue/bed-doctor-resume`, params })
  },
  // 医生入座,
  bedDoctorOn: async (params) => {
    return await request.get({ url: `/ecg/queue/bed-doctor-on`, params })
  },
  // 医生离座,
  bedDoctorOff: async (params) => {
    return await request.get({ url: `/ecg/queue/bed-doctor-off`, params })
  },
  // 获取医生的工位信息
  bedDoctorGet: async (params) => {
    return await request.get({ url: `/ecg/queue/bed-doctor-get`, params })
  },
  //
  resetSchedule: async () => {
    return await request.get({ url: `/ecg/queue/reset-scheduler` })
src/views/ecg/doctor/index.vue
@@ -3,7 +3,7 @@
import QueuePanel from "@/views/ecg/doctor/components/QueuePanel.vue";
import {DoctorApi, PatientStatisticVO, RoomBedVO} from '@/api/ecg/doctor';
import {useUserStore} from "@/store/modules/user";
import {QueueApi, QueueVO} from "@/api/ecg/queue";
import {QueueVO} from "@/api/ecg/queue";
const userStore = useUserStore();
@@ -45,7 +45,7 @@
const initLoad = async () => {
  list.value = await DoctorApi.getPatientList(roomBedVO)
  patientStat.value = await DoctorApi.getPatientStatistic(roomBedVO)
  const queueVO2 = await QueueApi.bedDoctorGet(roomBedVO)
  const queueVO2 = await DoctorApi.bedDoctorGet(roomBedVO)
  if (queueVO2.status === 20)
    state.value = true
  else if (queueVO2.status === 30)
@@ -55,10 +55,10 @@
const bedControl = async () => {
  bedControlFlag.value = true
  if (state.value) {
    await QueueApi.bedDoctorPause(roomBedVO)
    await DoctorApi.bedDoctorPause(roomBedVO)
    state.value = false
  } else {
    await QueueApi.bedDoctorResume(roomBedVO)
    await DoctorApi.bedDoctorResume(roomBedVO)
    state.value = true
  }
  bedControlFlag.value = false
src/views/ecg/queue/index.vue
@@ -98,17 +98,6 @@
          class="!w-240px"
        />
      </el-form-item>
      <el-form-item label="创建时间" prop="createTime">
        <el-date-picker
          v-model="queryParams.createTime"
          value-format="YYYY-MM-DD HH:mm:ss"
          type="daterange"
          start-placeholder="开始日期"
          end-placeholder="结束日期"
          :default-time="[new Date('1 00:00:00'), new Date('1 23:59:59')]"
          class="!w-220px"
        />
      </el-form-item>
      <el-form-item>
        <el-button @click="handleQuery"><Icon icon="ep:search" class="mr-5px" /> 搜索</el-button>
        <el-button @click="resetQuery"><Icon icon="ep:refresh" class="mr-5px" /> 重置</el-button>
@@ -241,7 +230,6 @@
  expired: undefined,
  roomId: undefined,
  bedNo: undefined,
  createTime: []
})
const queryFormRef = ref() // 搜索的表单
const exportLoading = ref(false) // 导出的加载中
src/views/ecg/room/RoomLoginSelect.vue
@@ -16,11 +16,11 @@
<script setup lang="ts">
import {RoomBedSelect} from "@/components/RoomBedSelect"
import { RoomApi, RoomVO } from '@/api/ecg/room'
import { QueueApi } from '@/api/ecg/queue'
import {useUserStore} from "@/store/modules/user";
import {ElMessage, ElMessageBox} from "element-plus";
import {isStringEmpty} from "@/utils/stringUtil";
import {cloneDeep} from "lodash-es";
import {DoctorApi} from "@/api/ecg/doctor";
const {  push } = useRouter()
defineOptions({ name: 'RoomLoginSelect' })
@@ -76,7 +76,7 @@
  if (newRoomVO !== curSel.value) {
    let data;
    if (curSel.value.docId !== null) {
      data = await QueueApi.bedDoctorOff(curSel.value)
      data = await DoctorApi.bedDoctorOff(curSel.value)
      if (data !== 0) {
        ElMessage({
          message: '内部错误!' + data,
@@ -92,7 +92,7 @@
    const tempRoomVO = cloneDeep(newRoomVO)
    tempRoomVO.docId = curUser.id
    tempRoomVO.docName = curUser.nickname
    data = await QueueApi.bedDoctorOn(tempRoomVO)
    data = await DoctorApi.bedDoctorOn(tempRoomVO)
    if (data !== 0) {
      ElMessage({
        message: '内部错误!' + data,
@@ -118,7 +118,7 @@
const leaveSeatConfirm = async () => {
  if (curSel.value.docId !== null) {
      let data = await QueueApi.bedDoctorOff(curSel.value)
      let data = await DoctorApi.bedDoctorOff(curSel.value)
      if (data !== 0) {
          ElMessage({
              message: '内部错误!' + data,