eight
2024-10-23 83bc7f6d33934f56fd1df80c7e8975e7c887d606
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
import request from '@/config/axios'
 
// 诊室和诊疗床 VO
export interface RoomVO {
  id: number | null  //
  roomId: number | null // 诊室编号
  roomName: string | null // 诊室名称
  bedNo: string | null // 诊疗床编号
  ip: string | null // 诊室IP
  status: number | null //开诊状态  0-关闭 1-关闭中 10-已开通 20-有医生 30-暂停
  docId: number | null
  docName: string | null
  checkTypes: number[]
  opType: number
}
 
export interface MonitorInfo {
  queueNum : number
  activeQueueNum : number
  priorityQueueNum : number
  openingFlag : number
  checkTypeBedInfo: object
}
 
// 诊室和诊疗床 API
export const RoomApi = {
  // 查询诊室和诊疗床分页
  getRoomPage: async (params: any) => {
    return await request.get({ url: `/clinic/room/page`, params })
  },
 
  // 查询诊室和诊疗床详情
  getRoom: async (id: number) => {
    return await request.get({ url: `/clinic/room/get?id=` + id })
  },
 
  // 查询诊室和诊疗床详情
  getRoomByIP: async () => {
    return await request.get({ url: `/clinic/room/get-room-by-ip`})
  },
 
  // 新增诊室和诊疗床
  createRoom: async (data: RoomVO) => {
    return await request.post({ url: `/clinic/room/create`, data })
  },
 
  // 修改诊室和诊疗床
  updateRoom: async (data: RoomVO) => {
    return await request.put({ url: `/clinic/room/update`, data })
  },
 
  // 删除诊室和诊疗床
  deleteRoom: async (id: number) => {
    return await request.delete({ url: `/clinic/room/delete?id=` + id })
  },
 
  // 导出诊室和诊疗床 Excel
  exportRoom: async (params) => {
    return await request.download({ url: `/clinic/room/export-excel`, params })
  },
 
  // 获取部门精简信息列表 ECG 子部门
  getSimpleRoomList: async () => {
    return await request.get({ url: `/clinic/room/simple-list` })
  },
 
  // 获取诊室精简信息列表,用于医生选择登录的诊室
  getOpeningBedMap: async () => {
    return await request.get({ url: `/clinic/room/list-simple-room` })
  },
 
  // 获取诊床Map
  getAllBedMap: async () => {
    return await request.get({ url: `/clinic/room/list-all-bed` })
  },
 
  //
  resetRoom: async () => {
    return await request.get({ url: `/clinic/room/reset-room` })
  },
 
  //
  getMonitorInfo: async () => {
    return await request.get({ url: `/clinic/room/monitor` })
  },
 
  // 手动开诊
  startBiz: async () => {
    return await request.get({ url: `/clinic/room/start-biz` })
  },
 
  // 手动闭诊
  closeBiz: async () => {
    return await request.get({ url: `/clinic/room/close-biz` })
  }
 
}