From 6f1b2cf3dc89059104ca0eedebf5f3ec4d1147f0 Mon Sep 17 00:00:00 2001
From: WXL <wl_5969728@163.com>
Date: 星期三, 26 十一月 2025 11:08:17 +0800
Subject: [PATCH] 打印
---
src/api/ecg/devmanage/index.ts | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++------
1 files changed, 52 insertions(+), 6 deletions(-)
diff --git a/src/api/ecg/devmanage/index.ts b/src/api/ecg/devmanage/index.ts
index 486c4f5..f71f887 100644
--- a/src/api/ecg/devmanage/index.ts
+++ b/src/api/ecg/devmanage/index.ts
@@ -9,12 +9,34 @@
// 璁惧 VO
export interface DeviceVO {
- id: number // id
- devId: string // 璁惧缂栧彿
- category: string // 鍒嗙被鍚�
- brand: string // 鍝佺墝
- model: string // 鍨嬪彿
- purchaseDate: Date // 閲囪喘鏃ユ湡
+ id?: number // id
+ devCodeIntrinsic?: string
+ devCodeHosp?: string
+ devCodeDept?: string
+ devId?: string // 璁惧缂栧彿
+ category?: string // 鍒嗙被鍚�
+ brand?: string // 鍝佺墝
+ model?: string // 鍨嬪彿
+ purchaseDate?: number // 閲囪喘鏃ユ湡
+ state?: number //鐘舵��
+ comment?: string // 澶囨敞
+}
+
+// 璁惧缁熻 VO
+export interface DeviceStatisticVO {
+ id: number // id
+ devId: string // 璁惧缂栧彿
+ category: string // 鍒嗙被鍚�
+ brand: string // 鍝佺墝
+ model: string // 鍨嬪彿
+ purchaseDate: number // 閲囪喘鏃ユ湡
+ state: number // 鐘舵��
+ devCount: number // 缁熻鏁伴噺
+}
+
+export interface OptionsVO {
+ label: string
+ value: string
}
// 璁惧鍨嬪彿 API
@@ -47,6 +69,15 @@
// 瀵煎嚭璁惧鍨嬪彿 Excel
exportDevModel: async (params) => {
return await request.download({ url: `/ecg/dev-model/export-excel`, params })
+ },
+
+ //
+ getBrandOption: async (category: string) => {
+ return await request.get({ url: `/ecg/dev-model/brand-option?category=` + category })
+ },
+
+ getModelOption: async (category: string, brand: string) => {
+ return await request.get({ url: `/ecg/dev-model/model-option?category=` + category + `&brand=` + brand })
}
}
@@ -57,9 +88,19 @@
return await request.get({ url: `/ecg/device/page`, params })
},
+ // 璁惧缁熻
+ deviceStatistic: async (params: any) => {
+ return await request.get({ url: `/ecg/device/dev-statistic`, params })
+ },
+
// 鏌ヨ璁惧璇︽儏
getDevice: async (id: number) => {
return await request.get({ url: `/ecg/device/get?id=` + id })
+ },
+
+ // 鏌ヨ璁惧璇︽儏
+ getDeviceByDevId: async (devId: string) => {
+ return await request.get({ url: `/ecg/device/get-by-dev-id?dev-id=` + devId })
},
// 鏂板璁惧
@@ -72,6 +113,11 @@
return await request.put({ url: `/ecg/device/update`, data })
},
+ // 淇敼璁惧鐘舵��
+ updateDeviceState: async (data: DeviceVO) => {
+ return await request.post({ url: `/ecg/device/update-dev-state`, data })
+ },
+
// 鍒犻櫎璁惧
deleteDevice: async (id: number) => {
return await request.delete({ url: `/ecg/device/delete?id=` + id })
--
Gitblit v1.9.3