This commit is contained in:
sjl
2024-11-18 09:02:57 +08:00
parent a8eaccc53e
commit 5cdbee88b4
54 changed files with 375 additions and 836 deletions

View File

@@ -1,5 +1,4 @@
import type { Device } from './interface'
import { ADMIN as rePrefix } from '@/api/config/serviceName'
import type { Device } from '@/api/device/interface/device'
import http from '@/api'
/**

View File

@@ -0,0 +1,212 @@
import type {ErrorSystem} from "@/api/device/interface/error"
const errordata = ref<ErrorSystem.ErrorSystemList[]>([
{
id: '1',
name: 'Q/GDW 1650.2-2016-A',
standard_Name:'Q/GDW 1650.2-2016',
standard_Time:'2016',
dev_Level:'A级',
enable:1,
state:1,
},
{
id: '2',
name: 'Q/GDW 1650.2-2021-A',
standard_Name:'Q/GDW 1650.2-2021',
standard_Time:'2021',
dev_Level:'A级',
enable:1,
state:1,
},
{
id: '3',
name: 'GBT 19862-2016-A',
standard_Name:'GBT 19862-2016',
standard_Time:'2016',
dev_Level:'A级',
enable:1,
state:1,
},
])
const errordetail = ref<ErrorSystem.Error_detail[]>([
{
measured: '电压偏差',
deviceLevel: 'A',
measurementType:'电压',
condition: '10%~150%标称电压',
maxErrorValue: '±0.1%Un'
},
{
measured: '频率偏差',
deviceLevel: 'A',
measurementType:'频率',
condition: '42.5~57.5 Hz',
maxErrorValue: '±0.01Hz'
},
{
measured: '三相不平衡度',
deviceLevel: 'A',
measurementType:'电压',
condition: '0.5%~5%',
maxErrorValue: '±0.15%'
},
{
measured: '三相不平衡度',
deviceLevel: 'A',
measurementType:'电压',
condition: '5%(不包含)~ 40%',
maxErrorValue: '±0.3%'
},
{
measured: '三相不平衡度',
deviceLevel: 'A',
measurementType:'电流',
condition: '',
maxErrorValue: '±1%'
},
{
measured: '电压波动幅值',
deviceLevel: 'A',
measurementType:'电压',
condition: '',
maxErrorValue: '±0.2%Un'
},
{
measured: '电压波动持续时间',
deviceLevel: 'A',
measurementType:'时间',
condition: '',
maxErrorValue: '±1周波'
},
{
measured: '闪变',
deviceLevel: 'A',
measurementType:'短时间闪变',
condition: 'Pst0.2~10',
maxErrorValue: '±5%'
},
{
measured: '谐波和间谐波',
deviceLevel: 'A',
measurementType:'电压',
condition: 'Uh≥1%Un',
maxErrorValue: '±5%Uh'
},
{
measured: '谐波和间谐波',
deviceLevel: 'A',
measurementType:'电压',
condition: 'Uh1%Un',
maxErrorValue: '±0.05%Un'
},
{
measured: '谐波和间谐波',
deviceLevel: 'A',
measurementType:'电流',
condition: 'In≥3%In',
maxErrorValue: '±5%Ih'
},
{
measured: '谐波和间谐波',
deviceLevel: 'A',
measurementType:'电流',
condition: 'In3%In',
maxErrorValue: '±0.15%In'
},
{
measured: '谐波和间谐波',
deviceLevel: 'A',
measurementType:'相角',
condition: '',
maxErrorValue: 'h≤5,±1°*h'
},
{
measured: '谐波和间谐波',
deviceLevel: 'A',
measurementType:'相角',
condition: '',
maxErrorValue: 'h>5,±5°'
},
{
measured: '谐波和间谐波',
deviceLevel: 'A',
measurementType:'功率',
condition: 'Ph≥150W',
maxErrorValue: '±1%Ph'
},
{
measured: '谐波和间谐波',
deviceLevel: 'A',
measurementType:'功率',
condition: 'Ph150W',
maxErrorValue: '±1.5W'
},
{
measured: '高频次谐波',
deviceLevel: 'A',
measurementType:'电压',
condition: 'Uh≥1%Un',
maxErrorValue: '±5%Uh'
},
{
measured: '高频次谐波',
deviceLevel: 'A',
measurementType:'电压',
condition: 'Uh1%Un',
maxErrorValue: '±0.05%Un'
},
{
measured: '高频次谐波',
deviceLevel: 'A',
measurementType:'电流',
condition: 'In≥3%In',
maxErrorValue: '±5%Ih'
},
{
measured: '高频次谐波',
deviceLevel: 'A',
measurementType:'电流',
condition: 'In3%In',
maxErrorValue: '±0.15%In'
},
{
measured: '功率',
deviceLevel: 'A',
measurementType:'功率',
condition: '',
maxErrorValue: '±0.5%'
},
{
measured: '电流',
deviceLevel: 'A',
measurementType:'电流',
condition: 'I≥0.05In',
maxErrorValue: '±0.5%'
},
{
measured: '电流',
deviceLevel: 'A',
measurementType:'电流',
condition: '0.01In≤I0.05In',
maxErrorValue: '±1%'
},
{
measured: '暂态电压幅值',
deviceLevel: 'A',
measurementType:'电压',
condition: '',
maxErrorValue: '±0.2%Un'
},
{
measured: '暂态持续时间',
deviceLevel: 'A',
measurementType:'时间',
condition: '',
maxErrorValue: '±1周波'
},
])
export default {errordata,errordetail}

View File

@@ -0,0 +1,41 @@
// 误差体系模块
export namespace ErrorSystem {
// 误差体系列表
export interface ErrorSystemList {
id: string;//误差体系表Id
name: string;//误差体系名称
standard_Name:string;//参照标准名称
standard_Time:string;//标准推行时间
dev_Level:string;//使用设备等级
enable?:number;//状态0-不启用 1-启用
state:number;//0-删除 1-正常
create_By?:string;//创建用户
create_Time?:string;//创建时间
update_By?:string;//修改用户
update_Time?:string;//修改时间
}
// 查看详细误差体系
export interface ErrorSystemDetail {
id:string;//误差体系子表ID
error_Sys_Id:string;//所属误差体系ID
type: string;//检测脚本类型,树形字典表(没有树形表则需要拆分字段)
JudgeConditionStart?:number;//误差判断起始值(误差范围)
IsContainStart?:number;//是否包含起始值
JudgeConditionEnd?:number;//误差判断结束值(误差范围)
IsContainEnd?:number;//是否包含结束值
JudgeConditionType?:string;//判断条件值类型(包括值类型,绝对值、相对值)
MaxErrorValue:number;//误差最大值
ErrorValueType:string;//误差值类型包括值类型绝对值、相对值1、相对值2
}
// 查看详细误差体系
export interface Error_detail {
measured: string;
deviceLevel: string;
measurementType:string;
condition: string;
maxErrorValue: string;
}
}

View File

@@ -0,0 +1,41 @@
// 误差体系模块
export namespace ErrorSystem {
// 误差体系列表
export interface ErrorSystemList {
id: string;//误差体系表Id
name: string;//误差体系名称
standard_Name:string;//参照标准名称
standard_Time:string;//标准推行时间
dev_Level:string;//使用设备等级
enable?:number;//状态0-不启用 1-启用
state:number;//0-删除 1-正常
create_By?:string;//创建用户
create_Time?:string;//创建时间
update_By?:string;//修改用户
update_Time?:string;//修改时间
}
// 查看详细误差体系
export interface ErrorSystemDetail {
id:string;//误差体系子表ID
error_Sys_Id:string;//所属误差体系ID
type: string;//检测脚本类型,树形字典表(没有树形表则需要拆分字段)
JudgeConditionStart?:number;//误差判断起始值(误差范围)
IsContainStart?:number;//是否包含起始值
JudgeConditionEnd?:number;//误差判断结束值(误差范围)
IsContainEnd?:number;//是否包含结束值
JudgeConditionType?:string;//判断条件值类型(包括值类型,绝对值、相对值)
MaxErrorValue:number;//误差最大值
ErrorValueType:string;//误差值类型包括值类型绝对值、相对值1、相对值2
}
// 查看详细误差体系
export interface Error_detail {
measured: string;
deviceLevel: string;
measurementType:string;
condition: string;
maxErrorValue: string;
}
}

View File

@@ -0,0 +1,35 @@
import type { ReqPage,ResPage } from '@/api/interface'
// 被检设备模块
export namespace Monitor {
/**
* 电能质量指标字典数据表格分页查询参数
*/
export interface ReqPqMonParams extends ReqPage{
id: string; // 装置序号id 必填
devType?: string; // 设备名称
createTime?:string; //创建时间
}
/**
* 被检设备新增、修改、根据id查询返回的对象
*/
export interface ResPqMon {
id: string; //监测点ID
code: string; //默认与谐波系统监测点ID相同
devId: string; //所属设备ID
name: string; //所属母线
num: number; //监测点序号
pt: number; //PT变比
ct: number; //CT变比
ptType:string; //接线方式,字典表
}
/**
* 被检设备表格查询分页返回的对象;
*/
export interface ResPqMonPage extends ResPage<ResPqMon> {
}
}

View File

@@ -0,0 +1,21 @@
import type { ReqPage } from '@/api/interface'
// 检测脚本模块
export namespace TestScript {
// 检测脚本接口
export interface TestScriptBO {
id?: string; //检测脚本ID
name: string; //检测脚本名称
type: string; //检测脚本类型(字典表Code字段脚本还是模板)
pattern: string;//检测脚本模式(字典表Code字段数字、模拟、比对)
valueType: string;//脚本值类型(字典表Code字段相对值脚本、绝对值脚本、无)
standardName: string;//参照标准名称
standardTime: string;//标准推行时间
}
// 检测脚本+分页
export interface ReqTestScriptParams extends ReqPage,TestScriptBO {
}
}

View File

@@ -0,0 +1,20 @@
import type { ReqPage } from '@/api/interface'
// 检测源模块
export namespace TestSource {
// 检测源接口
export interface TestSourceBO {
id?: string; //检测源ID
name: string; //检测源名称
pattern: string;//检测源模式(字典表Code字段数字、模拟、比对)
type: string; //检测源类型(字典表Code字段标准源、高精度设备)
devType: string;//检测源设备类型(字典表Code字段)
parameters: string;//源参数JSON字符串
}
// 检测源+分页
export interface ReqTestSourceParams extends ReqPage,TestSourceBO {
}
}

View File

@@ -0,0 +1,28 @@
import type { Monitor } from '@/api/device/interface/monitor'
import http from '@/api'
/**
* @name 被检设备管理模块
*/
//获取被检设备
export const getPqMonList = (params: Monitor.ReqPqMonParams) => {
return http.post(`/pqMon/list`, params)
}
//添加被检设备
export const addPqMon = (params: Monitor.ResPqMon) => {
return http.post(`/pqMon/add`, params)
}
//编辑被检设备
export const updatePqMon = (params: Monitor.ResPqMon) => {
return http.post(`/pqMon/update`, params)
}
//删除被检设备
export const deletePqMon = (params: string[]) => {
return http.post(`/pqMon/delete`, params)
}

View File

@@ -0,0 +1,12 @@
import type { ResPage } from '@/api/interface'
import type { TestScript } from '@/api/device/interface/testScript'
import http from '@/api'
/**
* @name 检测脚本管理模块
*/
// 获取检测脚本列表
export const getTestScriptList = (params: TestScript.ReqTestScriptParams) => {
return http.post<ResPage<TestScript.TestScriptBO>>(`/testScript/list`, params)
// return http.post<ResPage<Role.ResRoleList>>(`${rePrefix}/testScript/list`, params)
}

View File

@@ -0,0 +1,32 @@
const data = [
{
testScriptModel:"模拟",
id: 'operatorrole',
testScriptType:"脚本",
testScriptValueType:"绝对值",
testScriptName:"国网入网检测脚本(单影响量-模拟式)",
},
{
testScriptModel:"模拟",
id: 'managerrole',
testScriptType:"脚本",
testScriptValueType:"相对值",
testScriptName:"国网入网检测脚本Q/GDW 10650.4 - 2021) 模拟式",
},
{
testScriptModel:"模拟",
id: 'superManagerrole',
testScriptType:"脚本",
testScriptValueType:"相对值",
testScriptName:"国网入网检测脚本Q/GDW 1650.4 - 2016) 模拟式",
},
{
testScriptModel:"模拟",
id: 'superManagerroletest',
testScriptType:"脚本",
testScriptValueType:"相对值",
testScriptName:"GBT 19862 - 2016 模拟式",
},
]
export default data

View File

@@ -0,0 +1,12 @@
import type { ResPage } from '@/api/interface'
import type { TestSource } from '@/api/device/interface/testSource'
import http from '@/api'
/**
* @name 检测源管理模块
*/
// 获取检测脚本列表
export const getTestSourceList = (params: TestSource.ReqTestSourceParams) => {
return http.post<ResPage<TestSource.TestSourceBO>>(`/testSource/list`, params)
// return http.post<ResPage<Role.ResRoleList>>(`${rePrefix}/testSource/list`, params)
}

View File

@@ -0,0 +1,28 @@
const data = [
{
id: 'testSource1',
testSourceName: '标准源-福禄克-6100A',
testSourceType: 'FLUKE.6100A电能功率标准源',
testSourceModel: '标准源',
},
{
id: 'testSource2',
testSourceName: '标准源-昂立-PF2',
testSourceType: 'ANGLI-FP2高性能数字信号源',
testSourceModel: '标准源',
},
{
id: 'testSource3',
testSourceName: '标准源-丹迪克-DKLN1',
testSourceType: 'DKLN-1电能质量测试分析仪智能检定装置',
testSourceModel: '标准源',
},
{
id: 'testSource4',
testSourceName: '高精度设备-PQV520-1',
testSourceType: 'PQV-520电能质量监测装置',
testSourceModel: '高精度设备',
},
]
export default data