diff --git a/src/api/laboratory/equipment/config.ts b/src/api/laboratory/equipment/config.ts new file mode 100644 index 0000000..1a3d8c2 --- /dev/null +++ b/src/api/laboratory/equipment/config.ts @@ -0,0 +1,62 @@ +/** + * 设备配置 + */ +import request from '../../requestLab' +import type { IListQuery } from '@/views/laboratory/equipment/config/config-interface' +const prefix = 'device/config' + +// 列表查询 +export function getConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出 +export function exportConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/export`, + method: 'post', + data, + responseType: 'blob', + }) +} + +// 新建 +export function addConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/add`, + method: 'post', + data, + }) +} + +// 编辑 +export function updateConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/update`, + method: 'post', + data, + }) +} + +// 删除 +export function deleteConfig(data: { id: string }, type: string) { + return request({ + url: `${prefix}/${type}/delete`, + method: 'post', + data, + }) +} + +// 批量导入 +export function batchImport(data: object) { + return request({ + url: `${prefix}/import`, + method: 'post', + data, + }) +} + diff --git a/src/api/laboratory/equipment/config.ts b/src/api/laboratory/equipment/config.ts new file mode 100644 index 0000000..1a3d8c2 --- /dev/null +++ b/src/api/laboratory/equipment/config.ts @@ -0,0 +1,62 @@ +/** + * 设备配置 + */ +import request from '../../requestLab' +import type { IListQuery } from '@/views/laboratory/equipment/config/config-interface' +const prefix = 'device/config' + +// 列表查询 +export function getConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出 +export function exportConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/export`, + method: 'post', + data, + responseType: 'blob', + }) +} + +// 新建 +export function addConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/add`, + method: 'post', + data, + }) +} + +// 编辑 +export function updateConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/update`, + method: 'post', + data, + }) +} + +// 删除 +export function deleteConfig(data: { id: string }, type: string) { + return request({ + url: `${prefix}/${type}/delete`, + method: 'post', + data, + }) +} + +// 批量导入 +export function batchImport(data: object) { + return request({ + url: `${prefix}/import`, + method: 'post', + data, + }) +} + diff --git a/src/views/laboratory/data/list-interface.ts b/src/views/laboratory/data/list-interface.ts new file mode 100644 index 0000000..a79724d --- /dev/null +++ b/src/views/laboratory/data/list-interface.ts @@ -0,0 +1,102 @@ +// 温湿度网络传感器 +export interface ITemperatureHumidityList { + id: string // 主键id + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + humidity: string // 湿度(%) + locationId: string // 安装地点id + locationName: string // 安装地点 + temperature: string // 温度(℃) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 智能电量仪 +export interface IElectricQuantityList { + currentA: string // A相电流(A) + currentB: string // B相电流(A) + currentC: string // C相电流(A) + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + updateTime: string // 更新时间 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 + voltageA: string // A相电压(V) + voltageB: string // B相电压(V) + voltageC: string // C相电压(V) +} + +// 氧气传感器 +export interface IOxygenList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + oxygenDensity: string // 氧气浓度(ppm) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 烟雾报警器 +export interface ISmokeList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + smokeValue: string // 烟雾值 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// UPS电源 +export interface IUPSList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 列表请求参数 +export interface IListQuery { + deptId: string // 负责部门id(西昌组织下拉选择) + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + uploadEndTime: string // 上传结束时间 + uploadStartTime: string // 上传开始时间 + userId: string // 负责人id(西昌组织下人员下拉选择) + limit: number + offset: number +} diff --git a/src/api/laboratory/equipment/config.ts b/src/api/laboratory/equipment/config.ts new file mode 100644 index 0000000..1a3d8c2 --- /dev/null +++ b/src/api/laboratory/equipment/config.ts @@ -0,0 +1,62 @@ +/** + * 设备配置 + */ +import request from '../../requestLab' +import type { IListQuery } from '@/views/laboratory/equipment/config/config-interface' +const prefix = 'device/config' + +// 列表查询 +export function getConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出 +export function exportConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/export`, + method: 'post', + data, + responseType: 'blob', + }) +} + +// 新建 +export function addConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/add`, + method: 'post', + data, + }) +} + +// 编辑 +export function updateConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/update`, + method: 'post', + data, + }) +} + +// 删除 +export function deleteConfig(data: { id: string }, type: string) { + return request({ + url: `${prefix}/${type}/delete`, + method: 'post', + data, + }) +} + +// 批量导入 +export function batchImport(data: object) { + return request({ + url: `${prefix}/import`, + method: 'post', + data, + }) +} + diff --git a/src/views/laboratory/data/list-interface.ts b/src/views/laboratory/data/list-interface.ts new file mode 100644 index 0000000..a79724d --- /dev/null +++ b/src/views/laboratory/data/list-interface.ts @@ -0,0 +1,102 @@ +// 温湿度网络传感器 +export interface ITemperatureHumidityList { + id: string // 主键id + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + humidity: string // 湿度(%) + locationId: string // 安装地点id + locationName: string // 安装地点 + temperature: string // 温度(℃) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 智能电量仪 +export interface IElectricQuantityList { + currentA: string // A相电流(A) + currentB: string // B相电流(A) + currentC: string // C相电流(A) + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + updateTime: string // 更新时间 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 + voltageA: string // A相电压(V) + voltageB: string // B相电压(V) + voltageC: string // C相电压(V) +} + +// 氧气传感器 +export interface IOxygenList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + oxygenDensity: string // 氧气浓度(ppm) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 烟雾报警器 +export interface ISmokeList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + smokeValue: string // 烟雾值 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// UPS电源 +export interface IUPSList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 列表请求参数 +export interface IListQuery { + deptId: string // 负责部门id(西昌组织下拉选择) + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + uploadEndTime: string // 上传结束时间 + uploadStartTime: string // 上传开始时间 + userId: string // 负责人id(西昌组织下人员下拉选择) + limit: number + offset: number +} diff --git a/src/views/laboratory/data/list.vue b/src/views/laboratory/data/list.vue index 12e49d4..4b44d90 100644 --- a/src/views/laboratory/data/list.vue +++ b/src/views/laboratory/data/list.vue @@ -1,3 +1,340 @@ + + + diff --git a/src/api/laboratory/equipment/config.ts b/src/api/laboratory/equipment/config.ts new file mode 100644 index 0000000..1a3d8c2 --- /dev/null +++ b/src/api/laboratory/equipment/config.ts @@ -0,0 +1,62 @@ +/** + * 设备配置 + */ +import request from '../../requestLab' +import type { IListQuery } from '@/views/laboratory/equipment/config/config-interface' +const prefix = 'device/config' + +// 列表查询 +export function getConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出 +export function exportConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/export`, + method: 'post', + data, + responseType: 'blob', + }) +} + +// 新建 +export function addConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/add`, + method: 'post', + data, + }) +} + +// 编辑 +export function updateConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/update`, + method: 'post', + data, + }) +} + +// 删除 +export function deleteConfig(data: { id: string }, type: string) { + return request({ + url: `${prefix}/${type}/delete`, + method: 'post', + data, + }) +} + +// 批量导入 +export function batchImport(data: object) { + return request({ + url: `${prefix}/import`, + method: 'post', + data, + }) +} + diff --git a/src/views/laboratory/data/list-interface.ts b/src/views/laboratory/data/list-interface.ts new file mode 100644 index 0000000..a79724d --- /dev/null +++ b/src/views/laboratory/data/list-interface.ts @@ -0,0 +1,102 @@ +// 温湿度网络传感器 +export interface ITemperatureHumidityList { + id: string // 主键id + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + humidity: string // 湿度(%) + locationId: string // 安装地点id + locationName: string // 安装地点 + temperature: string // 温度(℃) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 智能电量仪 +export interface IElectricQuantityList { + currentA: string // A相电流(A) + currentB: string // B相电流(A) + currentC: string // C相电流(A) + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + updateTime: string // 更新时间 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 + voltageA: string // A相电压(V) + voltageB: string // B相电压(V) + voltageC: string // C相电压(V) +} + +// 氧气传感器 +export interface IOxygenList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + oxygenDensity: string // 氧气浓度(ppm) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 烟雾报警器 +export interface ISmokeList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + smokeValue: string // 烟雾值 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// UPS电源 +export interface IUPSList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 列表请求参数 +export interface IListQuery { + deptId: string // 负责部门id(西昌组织下拉选择) + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + uploadEndTime: string // 上传结束时间 + uploadStartTime: string // 上传开始时间 + userId: string // 负责人id(西昌组织下人员下拉选择) + limit: number + offset: number +} diff --git a/src/views/laboratory/data/list.vue b/src/views/laboratory/data/list.vue index 12e49d4..4b44d90 100644 --- a/src/views/laboratory/data/list.vue +++ b/src/views/laboratory/data/list.vue @@ -1,3 +1,340 @@ + + + diff --git a/src/views/laboratory/equipment/config/addElectricQuantity.vue b/src/views/laboratory/equipment/config/addElectricQuantity.vue new file mode 100644 index 0000000..6fc749a --- /dev/null +++ b/src/views/laboratory/equipment/config/addElectricQuantity.vue @@ -0,0 +1,644 @@ + + + + + diff --git a/src/api/laboratory/equipment/config.ts b/src/api/laboratory/equipment/config.ts new file mode 100644 index 0000000..1a3d8c2 --- /dev/null +++ b/src/api/laboratory/equipment/config.ts @@ -0,0 +1,62 @@ +/** + * 设备配置 + */ +import request from '../../requestLab' +import type { IListQuery } from '@/views/laboratory/equipment/config/config-interface' +const prefix = 'device/config' + +// 列表查询 +export function getConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出 +export function exportConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/export`, + method: 'post', + data, + responseType: 'blob', + }) +} + +// 新建 +export function addConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/add`, + method: 'post', + data, + }) +} + +// 编辑 +export function updateConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/update`, + method: 'post', + data, + }) +} + +// 删除 +export function deleteConfig(data: { id: string }, type: string) { + return request({ + url: `${prefix}/${type}/delete`, + method: 'post', + data, + }) +} + +// 批量导入 +export function batchImport(data: object) { + return request({ + url: `${prefix}/import`, + method: 'post', + data, + }) +} + diff --git a/src/views/laboratory/data/list-interface.ts b/src/views/laboratory/data/list-interface.ts new file mode 100644 index 0000000..a79724d --- /dev/null +++ b/src/views/laboratory/data/list-interface.ts @@ -0,0 +1,102 @@ +// 温湿度网络传感器 +export interface ITemperatureHumidityList { + id: string // 主键id + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + humidity: string // 湿度(%) + locationId: string // 安装地点id + locationName: string // 安装地点 + temperature: string // 温度(℃) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 智能电量仪 +export interface IElectricQuantityList { + currentA: string // A相电流(A) + currentB: string // B相电流(A) + currentC: string // C相电流(A) + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + updateTime: string // 更新时间 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 + voltageA: string // A相电压(V) + voltageB: string // B相电压(V) + voltageC: string // C相电压(V) +} + +// 氧气传感器 +export interface IOxygenList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + oxygenDensity: string // 氧气浓度(ppm) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 烟雾报警器 +export interface ISmokeList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + smokeValue: string // 烟雾值 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// UPS电源 +export interface IUPSList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 列表请求参数 +export interface IListQuery { + deptId: string // 负责部门id(西昌组织下拉选择) + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + uploadEndTime: string // 上传结束时间 + uploadStartTime: string // 上传开始时间 + userId: string // 负责人id(西昌组织下人员下拉选择) + limit: number + offset: number +} diff --git a/src/views/laboratory/data/list.vue b/src/views/laboratory/data/list.vue index 12e49d4..4b44d90 100644 --- a/src/views/laboratory/data/list.vue +++ b/src/views/laboratory/data/list.vue @@ -1,3 +1,340 @@ + + + diff --git a/src/views/laboratory/equipment/config/addElectricQuantity.vue b/src/views/laboratory/equipment/config/addElectricQuantity.vue new file mode 100644 index 0000000..6fc749a --- /dev/null +++ b/src/views/laboratory/equipment/config/addElectricQuantity.vue @@ -0,0 +1,644 @@ + + + + + diff --git a/src/views/laboratory/equipment/config/addOxygenSmoke.vue b/src/views/laboratory/equipment/config/addOxygenSmoke.vue new file mode 100644 index 0000000..ec965e7 --- /dev/null +++ b/src/views/laboratory/equipment/config/addOxygenSmoke.vue @@ -0,0 +1,248 @@ + + + + + diff --git a/src/api/laboratory/equipment/config.ts b/src/api/laboratory/equipment/config.ts new file mode 100644 index 0000000..1a3d8c2 --- /dev/null +++ b/src/api/laboratory/equipment/config.ts @@ -0,0 +1,62 @@ +/** + * 设备配置 + */ +import request from '../../requestLab' +import type { IListQuery } from '@/views/laboratory/equipment/config/config-interface' +const prefix = 'device/config' + +// 列表查询 +export function getConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出 +export function exportConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/export`, + method: 'post', + data, + responseType: 'blob', + }) +} + +// 新建 +export function addConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/add`, + method: 'post', + data, + }) +} + +// 编辑 +export function updateConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/update`, + method: 'post', + data, + }) +} + +// 删除 +export function deleteConfig(data: { id: string }, type: string) { + return request({ + url: `${prefix}/${type}/delete`, + method: 'post', + data, + }) +} + +// 批量导入 +export function batchImport(data: object) { + return request({ + url: `${prefix}/import`, + method: 'post', + data, + }) +} + diff --git a/src/views/laboratory/data/list-interface.ts b/src/views/laboratory/data/list-interface.ts new file mode 100644 index 0000000..a79724d --- /dev/null +++ b/src/views/laboratory/data/list-interface.ts @@ -0,0 +1,102 @@ +// 温湿度网络传感器 +export interface ITemperatureHumidityList { + id: string // 主键id + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + humidity: string // 湿度(%) + locationId: string // 安装地点id + locationName: string // 安装地点 + temperature: string // 温度(℃) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 智能电量仪 +export interface IElectricQuantityList { + currentA: string // A相电流(A) + currentB: string // B相电流(A) + currentC: string // C相电流(A) + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + updateTime: string // 更新时间 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 + voltageA: string // A相电压(V) + voltageB: string // B相电压(V) + voltageC: string // C相电压(V) +} + +// 氧气传感器 +export interface IOxygenList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + oxygenDensity: string // 氧气浓度(ppm) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 烟雾报警器 +export interface ISmokeList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + smokeValue: string // 烟雾值 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// UPS电源 +export interface IUPSList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 列表请求参数 +export interface IListQuery { + deptId: string // 负责部门id(西昌组织下拉选择) + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + uploadEndTime: string // 上传结束时间 + uploadStartTime: string // 上传开始时间 + userId: string // 负责人id(西昌组织下人员下拉选择) + limit: number + offset: number +} diff --git a/src/views/laboratory/data/list.vue b/src/views/laboratory/data/list.vue index 12e49d4..4b44d90 100644 --- a/src/views/laboratory/data/list.vue +++ b/src/views/laboratory/data/list.vue @@ -1,3 +1,340 @@ + + + diff --git a/src/views/laboratory/equipment/config/addElectricQuantity.vue b/src/views/laboratory/equipment/config/addElectricQuantity.vue new file mode 100644 index 0000000..6fc749a --- /dev/null +++ b/src/views/laboratory/equipment/config/addElectricQuantity.vue @@ -0,0 +1,644 @@ + + + + + diff --git a/src/views/laboratory/equipment/config/addOxygenSmoke.vue b/src/views/laboratory/equipment/config/addOxygenSmoke.vue new file mode 100644 index 0000000..ec965e7 --- /dev/null +++ b/src/views/laboratory/equipment/config/addOxygenSmoke.vue @@ -0,0 +1,248 @@ + + + + + diff --git a/src/views/laboratory/equipment/config/addTemperatureHumidity.vue b/src/views/laboratory/equipment/config/addTemperatureHumidity.vue new file mode 100644 index 0000000..7a3a09b --- /dev/null +++ b/src/views/laboratory/equipment/config/addTemperatureHumidity.vue @@ -0,0 +1,324 @@ + + + + + diff --git a/src/api/laboratory/equipment/config.ts b/src/api/laboratory/equipment/config.ts new file mode 100644 index 0000000..1a3d8c2 --- /dev/null +++ b/src/api/laboratory/equipment/config.ts @@ -0,0 +1,62 @@ +/** + * 设备配置 + */ +import request from '../../requestLab' +import type { IListQuery } from '@/views/laboratory/equipment/config/config-interface' +const prefix = 'device/config' + +// 列表查询 +export function getConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出 +export function exportConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/export`, + method: 'post', + data, + responseType: 'blob', + }) +} + +// 新建 +export function addConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/add`, + method: 'post', + data, + }) +} + +// 编辑 +export function updateConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/update`, + method: 'post', + data, + }) +} + +// 删除 +export function deleteConfig(data: { id: string }, type: string) { + return request({ + url: `${prefix}/${type}/delete`, + method: 'post', + data, + }) +} + +// 批量导入 +export function batchImport(data: object) { + return request({ + url: `${prefix}/import`, + method: 'post', + data, + }) +} + diff --git a/src/views/laboratory/data/list-interface.ts b/src/views/laboratory/data/list-interface.ts new file mode 100644 index 0000000..a79724d --- /dev/null +++ b/src/views/laboratory/data/list-interface.ts @@ -0,0 +1,102 @@ +// 温湿度网络传感器 +export interface ITemperatureHumidityList { + id: string // 主键id + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + humidity: string // 湿度(%) + locationId: string // 安装地点id + locationName: string // 安装地点 + temperature: string // 温度(℃) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 智能电量仪 +export interface IElectricQuantityList { + currentA: string // A相电流(A) + currentB: string // B相电流(A) + currentC: string // C相电流(A) + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + updateTime: string // 更新时间 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 + voltageA: string // A相电压(V) + voltageB: string // B相电压(V) + voltageC: string // C相电压(V) +} + +// 氧气传感器 +export interface IOxygenList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + oxygenDensity: string // 氧气浓度(ppm) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 烟雾报警器 +export interface ISmokeList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + smokeValue: string // 烟雾值 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// UPS电源 +export interface IUPSList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 列表请求参数 +export interface IListQuery { + deptId: string // 负责部门id(西昌组织下拉选择) + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + uploadEndTime: string // 上传结束时间 + uploadStartTime: string // 上传开始时间 + userId: string // 负责人id(西昌组织下人员下拉选择) + limit: number + offset: number +} diff --git a/src/views/laboratory/data/list.vue b/src/views/laboratory/data/list.vue index 12e49d4..4b44d90 100644 --- a/src/views/laboratory/data/list.vue +++ b/src/views/laboratory/data/list.vue @@ -1,3 +1,340 @@ + + + diff --git a/src/views/laboratory/equipment/config/addElectricQuantity.vue b/src/views/laboratory/equipment/config/addElectricQuantity.vue new file mode 100644 index 0000000..6fc749a --- /dev/null +++ b/src/views/laboratory/equipment/config/addElectricQuantity.vue @@ -0,0 +1,644 @@ + + + + + diff --git a/src/views/laboratory/equipment/config/addOxygenSmoke.vue b/src/views/laboratory/equipment/config/addOxygenSmoke.vue new file mode 100644 index 0000000..ec965e7 --- /dev/null +++ b/src/views/laboratory/equipment/config/addOxygenSmoke.vue @@ -0,0 +1,248 @@ + + + + + diff --git a/src/views/laboratory/equipment/config/addTemperatureHumidity.vue b/src/views/laboratory/equipment/config/addTemperatureHumidity.vue new file mode 100644 index 0000000..7a3a09b --- /dev/null +++ b/src/views/laboratory/equipment/config/addTemperatureHumidity.vue @@ -0,0 +1,324 @@ + + + + + diff --git a/src/views/laboratory/equipment/config/config-interface.ts b/src/views/laboratory/equipment/config/config-interface.ts index 8505f63..cd598c6 100644 --- a/src/views/laboratory/equipment/config/config-interface.ts +++ b/src/views/laboratory/equipment/config/config-interface.ts @@ -21,9 +21,25 @@ saveInterval: string // 保存间隔(分) } +// 温湿度网络传感器新增表单 +export interface ITemperatureHumidityForm { + deviceId: string // 设备表id + deviceName?: string // 设备名称 + deviceNo?: string // 设备编号 + humidityAlarmHigh: number // 湿度报警上限(%) + ip: string // ip + maxHumidity: number // 最高湿度(%) + maxTemperature: number // 最高温度(℃) + minHumidity: number // 最低湿度(%) + minTemperature: number // 最低温度(℃) + port: string // 端口 + saveInterval: number // 保存间隔(分) + temperatureAlarmHigh: number // 温度报警上限(℃) +} + // 智能电量仪列表 export interface IElectricQuantityList { - id: string + id?: string currentAlarmHigh: number // 电流报警上限(A) deviceId: string // 设备表id deviceName: string // 设备名称 @@ -60,32 +76,21 @@ minVoltageBc: number // 最低BC相电压(V) minVoltageC: number // 最低C相电压(V) port: string // 端口 - saveInterval: string // 保存间隔(分) + saveInterval: number // 保存间隔(分) voltageAlarmHigh: number // 电压报警上限(V) } -// 氧气传感器列表 -export interface IOxygenList { - id: string - densityAlarmHigh: number // 浓度报警上限(ppm) +// 氧气传感器列表\烟雾报警器列表 +export interface IOxygenSmokeList { + id?: string deviceId: string // 设备表id deviceName: string // 设备名称 deviceNo: string // 设备编号 ip: string // ip port: string // 端口 - saveInterval: string // 保存间隔(分) -} - -// 烟雾报警器列表 -export interface ISmokeList { - id: string - deviceId: string // 设备表id - deviceName: string // 设备名称 - deviceNo: string // 设备编号 - ip: string // ip - port: string // 端口 - saveInterval: string // 保存间隔(分) - valueAlarmHigh: number // 烟雾值报警上限(毫克/立方米) + saveInterval: number // 保存间隔(分) + densityAlarmHigh?: number // 氧气浓度报警上限(ppm) + valueAlarmHigh?: number // 烟雾值报警上限(毫克/立方米) } export interface IUPSList { diff --git a/src/api/laboratory/equipment/config.ts b/src/api/laboratory/equipment/config.ts new file mode 100644 index 0000000..1a3d8c2 --- /dev/null +++ b/src/api/laboratory/equipment/config.ts @@ -0,0 +1,62 @@ +/** + * 设备配置 + */ +import request from '../../requestLab' +import type { IListQuery } from '@/views/laboratory/equipment/config/config-interface' +const prefix = 'device/config' + +// 列表查询 +export function getConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出 +export function exportConfigList(data: IListQuery, type: string) { + return request({ + url: `${prefix}/${type}/export`, + method: 'post', + data, + responseType: 'blob', + }) +} + +// 新建 +export function addConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/add`, + method: 'post', + data, + }) +} + +// 编辑 +export function updateConfigList(data: object, type: string) { + return request({ + url: `${prefix}/${type}/update`, + method: 'post', + data, + }) +} + +// 删除 +export function deleteConfig(data: { id: string }, type: string) { + return request({ + url: `${prefix}/${type}/delete`, + method: 'post', + data, + }) +} + +// 批量导入 +export function batchImport(data: object) { + return request({ + url: `${prefix}/import`, + method: 'post', + data, + }) +} + diff --git a/src/views/laboratory/data/list-interface.ts b/src/views/laboratory/data/list-interface.ts new file mode 100644 index 0000000..a79724d --- /dev/null +++ b/src/views/laboratory/data/list-interface.ts @@ -0,0 +1,102 @@ +// 温湿度网络传感器 +export interface ITemperatureHumidityList { + id: string // 主键id + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + humidity: string // 湿度(%) + locationId: string // 安装地点id + locationName: string // 安装地点 + temperature: string // 温度(℃) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 智能电量仪 +export interface IElectricQuantityList { + currentA: string // A相电流(A) + currentB: string // B相电流(A) + currentC: string // C相电流(A) + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + updateTime: string // 更新时间 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 + voltageA: string // A相电压(V) + voltageB: string // B相电压(V) + voltageC: string // C相电压(V) +} + +// 氧气传感器 +export interface IOxygenList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + oxygenDensity: string // 氧气浓度(ppm) + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 烟雾报警器 +export interface ISmokeList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + electricQuantity: string // 电量(%) + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + smokeValue: string // 烟雾值 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// UPS电源 +export interface IUPSList { + deptId: string // 负责部门id + deptName: string // 负责部门 + deviceId: string // 设备表id + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + id: string // 主键id + locationId: string // 安装地点id + locationName: string // 安装地点 + deviceStatus: string // 状态 + uploadTime: string // 上传时间 + userId: string // 负责人id + userName: string // 负责人 +} + +// 列表请求参数 +export interface IListQuery { + deptId: string // 负责部门id(西昌组织下拉选择) + deviceName: string // 设备名称 + deviceNo: string // 设备编号 + uploadEndTime: string // 上传结束时间 + uploadStartTime: string // 上传开始时间 + userId: string // 负责人id(西昌组织下人员下拉选择) + limit: number + offset: number +} diff --git a/src/views/laboratory/data/list.vue b/src/views/laboratory/data/list.vue index 12e49d4..4b44d90 100644 --- a/src/views/laboratory/data/list.vue +++ b/src/views/laboratory/data/list.vue @@ -1,3 +1,340 @@ + + + diff --git a/src/views/laboratory/equipment/config/addElectricQuantity.vue b/src/views/laboratory/equipment/config/addElectricQuantity.vue new file mode 100644 index 0000000..6fc749a --- /dev/null +++ b/src/views/laboratory/equipment/config/addElectricQuantity.vue @@ -0,0 +1,644 @@ + + + + + diff --git a/src/views/laboratory/equipment/config/addOxygenSmoke.vue b/src/views/laboratory/equipment/config/addOxygenSmoke.vue new file mode 100644 index 0000000..ec965e7 --- /dev/null +++ b/src/views/laboratory/equipment/config/addOxygenSmoke.vue @@ -0,0 +1,248 @@ + + + + + diff --git a/src/views/laboratory/equipment/config/addTemperatureHumidity.vue b/src/views/laboratory/equipment/config/addTemperatureHumidity.vue new file mode 100644 index 0000000..7a3a09b --- /dev/null +++ b/src/views/laboratory/equipment/config/addTemperatureHumidity.vue @@ -0,0 +1,324 @@ + + + + + diff --git a/src/views/laboratory/equipment/config/config-interface.ts b/src/views/laboratory/equipment/config/config-interface.ts index 8505f63..cd598c6 100644 --- a/src/views/laboratory/equipment/config/config-interface.ts +++ b/src/views/laboratory/equipment/config/config-interface.ts @@ -21,9 +21,25 @@ saveInterval: string // 保存间隔(分) } +// 温湿度网络传感器新增表单 +export interface ITemperatureHumidityForm { + deviceId: string // 设备表id + deviceName?: string // 设备名称 + deviceNo?: string // 设备编号 + humidityAlarmHigh: number // 湿度报警上限(%) + ip: string // ip + maxHumidity: number // 最高湿度(%) + maxTemperature: number // 最高温度(℃) + minHumidity: number // 最低湿度(%) + minTemperature: number // 最低温度(℃) + port: string // 端口 + saveInterval: number // 保存间隔(分) + temperatureAlarmHigh: number // 温度报警上限(℃) +} + // 智能电量仪列表 export interface IElectricQuantityList { - id: string + id?: string currentAlarmHigh: number // 电流报警上限(A) deviceId: string // 设备表id deviceName: string // 设备名称 @@ -60,32 +76,21 @@ minVoltageBc: number // 最低BC相电压(V) minVoltageC: number // 最低C相电压(V) port: string // 端口 - saveInterval: string // 保存间隔(分) + saveInterval: number // 保存间隔(分) voltageAlarmHigh: number // 电压报警上限(V) } -// 氧气传感器列表 -export interface IOxygenList { - id: string - densityAlarmHigh: number // 浓度报警上限(ppm) +// 氧气传感器列表\烟雾报警器列表 +export interface IOxygenSmokeList { + id?: string deviceId: string // 设备表id deviceName: string // 设备名称 deviceNo: string // 设备编号 ip: string // ip port: string // 端口 - saveInterval: string // 保存间隔(分) -} - -// 烟雾报警器列表 -export interface ISmokeList { - id: string - deviceId: string // 设备表id - deviceName: string // 设备名称 - deviceNo: string // 设备编号 - ip: string // ip - port: string // 端口 - saveInterval: string // 保存间隔(分) - valueAlarmHigh: number // 烟雾值报警上限(毫克/立方米) + saveInterval: number // 保存间隔(分) + densityAlarmHigh?: number // 氧气浓度报警上限(ppm) + valueAlarmHigh?: number // 烟雾值报警上限(毫克/立方米) } export interface IUPSList { diff --git a/src/views/laboratory/equipment/config/list.vue b/src/views/laboratory/equipment/config/list.vue index 6b6037e..3ec6e70 100644 --- a/src/views/laboratory/equipment/config/list.vue +++ b/src/views/laboratory/equipment/config/list.vue @@ -2,31 +2,31 @@