Compare commits
40 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
987b6cd57f | ||
|
|
49ded8c568 | ||
|
|
a39ad579f9 | ||
|
|
3b6a7d9d5b | ||
|
|
0379e5cf2e | ||
|
|
657d357159 | ||
|
|
bc474fe17c | ||
|
|
0d7d5722c1 | ||
|
|
b50ca36024 | ||
|
|
36496e5825 | ||
|
|
38d834170a | ||
|
|
5caffc9cc9 | ||
|
|
f5f22f9635 | ||
|
|
15bef7b17f | ||
|
|
4ac32753f1 | ||
|
|
131adc81a7 | ||
|
|
3135f76a2f | ||
|
|
08d81f724f | ||
|
|
29ef22c9b7 | ||
|
|
7738d7d153 | ||
|
|
20bc6e3ab5 | ||
|
|
2ea0557f4e | ||
|
|
1a35510801 | ||
|
|
5ad3029e0b | ||
|
|
cd51cfb052 | ||
|
|
4415eb30b2 | ||
|
|
78d094e4a2 | ||
|
|
8f5642d0b5 | ||
|
|
6c191aa96f | ||
|
|
f2d7156b4f | ||
|
|
d44c79f7b8 | ||
|
|
964ba77f8a | ||
|
|
7c1f135e99 | ||
|
|
1982ccd7ff | ||
|
|
5abaa743c0 | ||
|
|
52a8095334 | ||
|
|
654c997607 | ||
|
|
b31efb9ede | ||
|
|
195b58d798 | ||
|
|
0423de2683 |
@@ -97,6 +97,8 @@ qr:
|
|||||||
db:
|
db:
|
||||||
type: mysql
|
type: mysql
|
||||||
|
|
||||||
|
icd:
|
||||||
|
txt-dir: ..\..\..\9100\DeviceControl\Config
|
||||||
|
|
||||||
# 比对录波需要的配置,晚点再做优化
|
# 比对录波需要的配置,晚点再做优化
|
||||||
# 系统配置
|
# 系统配置
|
||||||
@@ -118,3 +120,5 @@ activate:
|
|||||||
public-key: "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAnFMmIVanMxsW5S/qP8Wcxf/J3/i4631BP3UtWkRzO7jAw9HIAgK4Y7X53hXj6zMbfme1vMjQc0mq7m/KrH4WlTYpFexLO6Gnk8oH40F04tp+ABZIq93zNOydPEaVoZeTPH/LlkwrrxVGAMNNIKuebcqapp25JiWtlSFMv4kH/nDAj+2m8+P4zYVM1Ed6gO01eKDEYE3SBA1Ket2BfHTgviR/F8WKwlXh11enywsJnrHTM5dJQdlUxCjHy214TpheYOz/cv9elQnDfFAbmZW8mH5/hgMSTkm3h4uR7ITin6Erg+yc/t1kGaTWrzloyBRMSiFN/Pwr5yQjj+1wQqqUkwIDAQAB"
|
public-key: "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAnFMmIVanMxsW5S/qP8Wcxf/J3/i4631BP3UtWkRzO7jAw9HIAgK4Y7X53hXj6zMbfme1vMjQc0mq7m/KrH4WlTYpFexLO6Gnk8oH40F04tp+ABZIq93zNOydPEaVoZeTPH/LlkwrrxVGAMNNIKuebcqapp25JiWtlSFMv4kH/nDAj+2m8+P4zYVM1Ed6gO01eKDEYE3SBA1Ket2BfHTgviR/F8WKwlXh11enywsJnrHTM5dJQdlUxCjHy214TpheYOz/cv9elQnDfFAbmZW8mH5/hgMSTkm3h4uR7ITin6Erg+yc/t1kGaTWrzloyBRMSiFN/Pwr5yQjj+1wQqqUkwIDAQAB"
|
||||||
|
|
||||||
|
|
||||||
|
dataCheck:
|
||||||
|
enable: false
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo45
Normal file
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo45
Normal file
Binary file not shown.
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo46
Normal file
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo46
Normal file
Binary file not shown.
Binary file not shown.
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo47
Normal file
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo47
Normal file
Binary file not shown.
Binary file not shown.
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo48
Normal file
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo48
Normal file
Binary file not shown.
Binary file not shown.
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo49
Normal file
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo49
Normal file
Binary file not shown.
Binary file not shown.
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo50
Normal file
BIN
build/extraResources/mysql/data/#innodb_redo/#ib_redo50
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -1 +1 @@
|
|||||||
116212
|
55936
|
||||||
|
|||||||
Binary file not shown.
BIN
build/extraResources/mysql/data/binlog.000041
Normal file
BIN
build/extraResources/mysql/data/binlog.000041
Normal file
Binary file not shown.
@@ -16,3 +16,4 @@
|
|||||||
.\binlog.000038
|
.\binlog.000038
|
||||||
.\binlog.000039
|
.\binlog.000039
|
||||||
.\binlog.000040
|
.\binlog.000040
|
||||||
|
.\binlog.000041
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
build/extraResources/mysql/data/pqs9100/pq_dev_check_history.ibd
Normal file
BIN
build/extraResources/mysql/data/pqs9100/pq_dev_check_history.ibd
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
build/extraResources/mysql/data/pqs9100/pq_pqdif_path.ibd
Normal file
BIN
build/extraResources/mysql/data/pqs9100/pq_pqdif_path.ibd
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -12,3 +12,10 @@ VITE_REPORT=false
|
|||||||
|
|
||||||
# 浏览器是否显示vue的告警信息
|
# 浏览器是否显示vue的告警信息
|
||||||
VUE_APP_SILENCE_WARNINGS=true
|
VUE_APP_SILENCE_WARNINGS=true
|
||||||
|
|
||||||
|
VITE_COMPANY_WEBSITE=https://baike.baidu.com/item/%E4%BA%91%E5%8D%97%E7%94%B5%E5%8A%9B%E6%8A%80%E6%9C%AF%E6%9C%89%E9%99%90%E8%B4%A3%E4%BB%BB%E5%85%AC%E5%8F%B8/20071982
|
||||||
|
VITE_COMPANY_NAME=云南电力技术有限责任公司
|
||||||
|
|
||||||
|
VITE_IS_SHOW_RAW_DATA=true
|
||||||
|
# 开启激活验证
|
||||||
|
VITE_ACTIVATE_OPEN=true
|
||||||
|
|||||||
@@ -19,10 +19,6 @@ VITE_API_URL=/api
|
|||||||
|
|
||||||
# 开发环境跨域代理,支持配置多个
|
# 开发环境跨域代理,支持配置多个
|
||||||
|
|
||||||
VITE_PROXY=[["/api","http://127.0.0.1:18092/"]]
|
VITE_PROXY=[["/api","http://127.0.0.1:18093/"]]
|
||||||
#VITE_PROXY=[["/api","http://192.168.1.124:18092/"]]
|
#VITE_PROXY=[["/api","http://192.168.1.124:18092/"]]
|
||||||
#VITE_PROXY=[["/api","http://192.168.2.125:18092/"]]
|
#VITE_PROXY=[["/api","http://192.168.2.125:18092/"]]
|
||||||
# VITE_PROXY=[["/api","http://192.168.1.138:8080/"]]张文
|
|
||||||
VITE_IS_SHOW_RAW_DATA=true
|
|
||||||
# 开启激活验证
|
|
||||||
VITE_ACTIVATE_OPEN=false
|
|
||||||
|
|||||||
@@ -23,7 +23,5 @@ VITE_PWA=true
|
|||||||
|
|
||||||
# 线上环境接口地址
|
# 线上环境接口地址
|
||||||
#VITE_API_URL="/api" # 打包时用
|
#VITE_API_URL="/api" # 打包时用
|
||||||
VITE_API_URL="http://127.0.0.1:18092/"
|
VITE_API_URL="http://127.0.0.1:18093/"
|
||||||
VITE_IS_SHOW_RAW_DATA=true
|
|
||||||
# 开启激活验证
|
|
||||||
VITE_ACTIVATE_OPEN=false
|
|
||||||
|
|||||||
@@ -1,269 +0,0 @@
|
|||||||
const data = [
|
|
||||||
{
|
|
||||||
id: 'device1',
|
|
||||||
deviceName:"模拟装置1",
|
|
||||||
deviceType:"PQS882B4电能质量监测装置",
|
|
||||||
deviceChannels:"4",
|
|
||||||
planName: "沧州220kV留古等4座变电站电能质量检测",
|
|
||||||
deviceUn: "57.74",
|
|
||||||
deviceIn: "5",
|
|
||||||
deviceCompany: "南京灿能电力自动化股份有限公司",
|
|
||||||
deviceModel: "模拟式",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'device2',
|
|
||||||
deviceName:"模拟装置2",
|
|
||||||
deviceType:"PQS882A电能质量监测装置",
|
|
||||||
deviceChannels:"1",
|
|
||||||
planName: "邯郸220kV团城站等4座站电能质量检测",
|
|
||||||
deviceUn: "57.74",
|
|
||||||
deviceIn: "5",
|
|
||||||
deviceCompany: "南京灿能电力自动化股份有限公司",
|
|
||||||
deviceModel: "模拟式",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'device3',
|
|
||||||
deviceName:"模拟装置3",
|
|
||||||
deviceType:"PQS882A电能质量监测装置",
|
|
||||||
deviceChannels:"1",
|
|
||||||
planName: "衡水冀州光伏电站配套出口工程",
|
|
||||||
deviceUn: "57.74",
|
|
||||||
deviceIn: "1",
|
|
||||||
deviceCompany: "南京灿能电力自动化股份有限公司",
|
|
||||||
deviceModel: "模拟式",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: 'device4',
|
|
||||||
deviceName:"模拟装置4",
|
|
||||||
deviceType:"PMC-680M-22-22-00-115ANBC电能质量监测装置",
|
|
||||||
deviceChannels:"4",
|
|
||||||
planName: "深圳市中电软件有限公司委托送检",
|
|
||||||
deviceUn: "57.74",
|
|
||||||
deviceIn: "5",
|
|
||||||
deviceCompany: "深圳中电电力技术股份有限公司",
|
|
||||||
deviceModel: "模拟式",
|
|
||||||
},
|
|
||||||
]
|
|
||||||
const plan_devicedata = [
|
|
||||||
{
|
|
||||||
id: '1', //装置序号ID
|
|
||||||
name: '240001', //设备名称
|
|
||||||
dev_Type: 'PQS-882B4',//设备类型
|
|
||||||
dev_Chns: 4, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '2', //装置序号ID
|
|
||||||
name: '240002', //设备名称
|
|
||||||
dev_Type: 'PQS-882B4',//设备类型
|
|
||||||
dev_Chns: 4, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '3', //装置序号ID
|
|
||||||
name: '240003', //设备名称
|
|
||||||
dev_Type: 'PQS-882B4',//设备类型
|
|
||||||
dev_Chns: 4, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '4', //装置序号ID
|
|
||||||
name: '240004', //设备名称
|
|
||||||
dev_Type: 'PQS-882B4',//设备类型
|
|
||||||
dev_Chns: 4, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '5', //装置序号ID
|
|
||||||
name: '240005', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '不符合', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'检测完成',//检测状态
|
|
||||||
reCheck_Num: 1, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '6', //装置序号ID
|
|
||||||
name: '240006', //设备名称
|
|
||||||
dev_Type: 'PQS-882B4',//设备类型
|
|
||||||
dev_Chns: 4, //设备通道数
|
|
||||||
check_Result: '不符合', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'检测完成',//检测状态
|
|
||||||
reCheck_Num: 1, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '7', //装置序号ID
|
|
||||||
name: '240007', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '符合', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'检测完成',//检测状态
|
|
||||||
reCheck_Num: 1, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '8', //装置序号ID
|
|
||||||
name: '240008', //设备名称
|
|
||||||
dev_Type: 'PQS-882B4',//设备类型
|
|
||||||
dev_Chns: 4, //设备通道数
|
|
||||||
check_Result: '符合', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'检测完成',//检测状态
|
|
||||||
reCheck_Num: 1, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '9', //装置序号ID
|
|
||||||
name: '240009', //设备名称
|
|
||||||
dev_Type: 'PQS-882B4',//设备类型
|
|
||||||
dev_Chns: 4, //设备通道数
|
|
||||||
check_Result: '不符合', //检测结果
|
|
||||||
report_State: '已生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'检测完成',//检测状态
|
|
||||||
reCheck_Num: 1, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '10', //装置序号ID
|
|
||||||
name: '240010', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '符合', //检测结果
|
|
||||||
report_State: '已生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'检测完成',//检测状态
|
|
||||||
reCheck_Num: 2, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '11', //装置序号ID
|
|
||||||
name: '240011', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '符合', //检测结果
|
|
||||||
report_State: '已生成', //报告状态
|
|
||||||
document_State: '已归档', //归档状态
|
|
||||||
check_State:'检测完成',//检测状态
|
|
||||||
reCheck_Num: 1, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '12', //装置序号ID
|
|
||||||
name: '240012', //设备名称
|
|
||||||
dev_Type: 'PQS-882B4',//设备类型
|
|
||||||
dev_Chns: 4, //设备通道数
|
|
||||||
check_Result: '符合', //检测结果
|
|
||||||
report_State: '已生成', //报告状态
|
|
||||||
document_State: '已归档', //归档状态
|
|
||||||
check_State:'检测完成',//检测状态
|
|
||||||
reCheck_Num: 2, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '13', //装置序号ID
|
|
||||||
name: '240013', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '14', //装置序号ID
|
|
||||||
name: '240014', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '15', //装置序号ID
|
|
||||||
name: '240015', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '16', //装置序号ID
|
|
||||||
name: '240016', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '17', //装置序号ID
|
|
||||||
name: '240017', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '18', //装置序号ID
|
|
||||||
name: '240018', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '19', //装置序号ID
|
|
||||||
name: '240019', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
{
|
|
||||||
id: '20', //装置序号ID
|
|
||||||
name: '240020', //设备名称
|
|
||||||
dev_Type: 'PQS-882A',//设备类型
|
|
||||||
dev_Chns: 1, //设备通道数
|
|
||||||
check_Result: '未检', //检测结果
|
|
||||||
report_State: '未生成', //报告状态
|
|
||||||
document_State: '未归档', //归档状态
|
|
||||||
check_State:'未检',//检测状态
|
|
||||||
reCheck_Num: 0, //复检次数
|
|
||||||
},
|
|
||||||
]
|
|
||||||
export default {data,plan_devicedata}
|
|
||||||
@@ -4,34 +4,38 @@ import http from '@/api'
|
|||||||
/**
|
/**
|
||||||
* @name ICD管理模块
|
* @name ICD管理模块
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//获取ICD分页
|
|
||||||
export const getICDList = (params: ICD.ReqICDParams) => {
|
export const getICDList = (params: ICD.ReqICDParams) => {
|
||||||
return http.post(`/icd/list`,params)
|
return http.post<ICD.ResICDPage>(`/icd/list`, params)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export const getICDAllList = () => {
|
||||||
//获取ICD
|
return http.get<ICD.ResICD[]>(`/icd/listAll`)
|
||||||
export const getICDAllList = (params: ICD.ResICD) => {
|
|
||||||
return http.get(`/icd/listAll`,params)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//添加ICD
|
export const getStandardICDList = () => {
|
||||||
export const addICD = (params: ICD.ResICD) => {
|
return http.get<ICD.StandardOption[]>(`/icd/standard-list`)
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getICDById = (id: string) => {
|
||||||
|
return http.get<ICD.ResICD>(`/icd/getById`, { id })
|
||||||
|
}
|
||||||
|
|
||||||
|
export const addICD = (params: FormData) => {
|
||||||
return http.upload(`/icd/add`, params)
|
return http.upload(`/icd/add`, params)
|
||||||
}
|
}
|
||||||
|
|
||||||
//编辑ICD
|
export const updateICD = (params: FormData) => {
|
||||||
export const updateICD = (params: ICD.ResICD) => {
|
|
||||||
return http.upload(`/icd/update`, params)
|
return http.upload(`/icd/update`, params)
|
||||||
}
|
}
|
||||||
|
|
||||||
//删除ICD
|
export const importICDJson = (params: FormData) => {
|
||||||
|
return http.upload(`/icd/import/json`, params, { loading: false })
|
||||||
|
}
|
||||||
|
|
||||||
export const deleteICD = (params: string[]) => {
|
export const deleteICD = (params: string[]) => {
|
||||||
return http.post(`/icd/delete`, params)
|
return http.post(`/icd/delete`, params)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export const exportICD = (id: string) => {
|
||||||
|
return http.downloadGetWithHeaders(`/icd/export/${id}`)
|
||||||
|
}
|
||||||
|
|||||||
@@ -19,6 +19,7 @@ export namespace DevType {
|
|||||||
id: string; //设备类型ID
|
id: string; //设备类型ID
|
||||||
name: string;//设备类型名称
|
name: string;//设备类型名称
|
||||||
icd: string| null;//设备关联的ICD
|
icd: string| null;//设备关联的ICD
|
||||||
|
pqdif: string| null;//设备关联的PQDIF
|
||||||
power: string| null;//工作电源
|
power: string| null;//工作电源
|
||||||
devVolt: number; //额定电压(V)
|
devVolt: number; //额定电压(V)
|
||||||
devCurr: number; //额定电流(A)
|
devCurr: number; //额定电流(A)
|
||||||
|
|||||||
@@ -1,38 +1,36 @@
|
|||||||
import type { ReqPage, ResPage } from '@/api/interface'
|
import type { ReqPage, ResPage } from '@/api/interface'
|
||||||
|
|
||||||
// ICD模块
|
|
||||||
export namespace ICD {
|
export namespace ICD {
|
||||||
|
|
||||||
/**
|
|
||||||
* ICD表格分页查询参数
|
|
||||||
*/
|
|
||||||
export interface ReqICDParams extends ReqPage {
|
export interface ReqICDParams extends ReqPage {
|
||||||
id: string; // 装置序号id 必填
|
name?: string
|
||||||
devType?: string; // 设备名称
|
type?: number
|
||||||
createTime?: string; //创建时间
|
}
|
||||||
|
|
||||||
|
export interface StandardOption {
|
||||||
|
id: string
|
||||||
|
name: string
|
||||||
|
type?: number
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* ICD新增、修改、根据id查询返回的对象
|
|
||||||
*/
|
|
||||||
export interface ResICD {
|
export interface ResICD {
|
||||||
id: string; //icdID
|
id: string
|
||||||
name: string;//icd名称
|
name: string
|
||||||
path: string;//icd存储地址
|
state: number
|
||||||
state: number;
|
createBy?: string | null
|
||||||
createBy?: string| null; //创建用户
|
createTime?: string | null
|
||||||
createTime?: string| null; //创建时间
|
updateBy?: string | null
|
||||||
updateBy?: string| null; //更新用户
|
updateTime?: string | null
|
||||||
updateTime?: string| null; //更新时间
|
angle: number
|
||||||
angle: number; // 是否支持电压相角、电流相角指标
|
usePhaseIndex: number
|
||||||
usePhaseIndex: number; // 角型接线时是否使用相别的指标来进行检测
|
jsonStr: string
|
||||||
mappingFile: string | null;//映射文件
|
xmlStr: string
|
||||||
|
result: number
|
||||||
|
msg: string | null
|
||||||
|
type: number
|
||||||
|
referenceIcdId: string | null
|
||||||
|
referenceIcdName?: string | null
|
||||||
|
hasIcdFile?: boolean | null
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
export interface ResICDPage extends ResPage<ResICD> {}
|
||||||
* ICD表格查询分页返回的对象;
|
|
||||||
*/
|
|
||||||
export interface ResICDPage extends ResPage<ResICD> {
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
26
frontend/src/api/device/interface/pqdif.ts
Normal file
26
frontend/src/api/device/interface/pqdif.ts
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
import type { ReqPage, ResPage } from '@/api/interface'
|
||||||
|
|
||||||
|
export namespace PQDIF {
|
||||||
|
export interface ReqPQDIFParams extends ReqPage {
|
||||||
|
name?: string
|
||||||
|
result?: number
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ResPQDIF {
|
||||||
|
id: string
|
||||||
|
name: string
|
||||||
|
filePath?: string | null
|
||||||
|
recordCount?: number | null
|
||||||
|
observationCount?: number | null
|
||||||
|
sampleValueCount?: number | null
|
||||||
|
result?: number | null
|
||||||
|
msg?: string | null
|
||||||
|
state: number
|
||||||
|
createBy?: string | null
|
||||||
|
createTime?: string | null
|
||||||
|
updateBy?: string | null
|
||||||
|
updateTime?: string | null
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ResPQDIFPage extends ResPage<ResPQDIF> {}
|
||||||
|
}
|
||||||
@@ -1,39 +1,34 @@
|
|||||||
import type { ReqPage, ResPage } from '@/api/interface'
|
import type { ReqPage, ResPage } from '@/api/interface'
|
||||||
import type { UploadFile } from 'element-plus';
|
|
||||||
|
|
||||||
// 报告模版接口
|
|
||||||
export namespace PqReport {
|
export namespace PqReport {
|
||||||
|
|
||||||
/**
|
|
||||||
* 报告模版表格分页查询参数
|
|
||||||
*/
|
|
||||||
export interface ReqReportParams extends ReqPage {
|
export interface ReqReportParams extends ReqPage {
|
||||||
id: string; // 装置序号id 必填
|
id: string
|
||||||
name?: string; // 设备名称
|
name?: string
|
||||||
createTime?: string; //创建时间
|
createTime?: string
|
||||||
|
pattern: string
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* 报告模版新增、修改、根据id查询返回的对象
|
|
||||||
*/
|
|
||||||
export interface ResReport {
|
export interface ResReport {
|
||||||
id: string; //报告模板id
|
id: string
|
||||||
name: string;//报告模板名称
|
name: string
|
||||||
version:string;//版本号
|
version: string
|
||||||
baseFile?:string;//基础模板文件路径
|
pattern: string
|
||||||
detailFile?:string;//检测项模版文件路径
|
baseFile?: string
|
||||||
description:string;//描述信息
|
detailFile?: string
|
||||||
state:number;//状态:8-删除 1-正常
|
description: string
|
||||||
createBy?: string| null; //创建用户
|
state: number
|
||||||
createTime?: string| null; //创建时间
|
createBy?: string | null
|
||||||
updateBy?: string| null; //更新用户
|
createTime?: string | null
|
||||||
updateTime?: string| null; //更新时间
|
updateBy?: string | null
|
||||||
|
updateTime?: string | null
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
export interface ResReportOption {
|
||||||
* 报告模版表格查询分页返回的对象;
|
id: string
|
||||||
*/
|
name: string
|
||||||
export interface ResReportPage extends ResPage<ResReport> {
|
version: string
|
||||||
|
displayName: string
|
||||||
|
}
|
||||||
|
|
||||||
}
|
export interface ResReportPage extends ResPage<ResReport> {}
|
||||||
}
|
}
|
||||||
14
frontend/src/api/device/pqdif/index.ts
Normal file
14
frontend/src/api/device/pqdif/index.ts
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
import type { PQDIF } from '@/api/device/interface/pqdif'
|
||||||
|
import http from '@/api'
|
||||||
|
|
||||||
|
export const getPQDIFList = (params: PQDIF.ReqPQDIFParams) => {
|
||||||
|
return http.post<PQDIF.ResPQDIFPage>('/pqdif/list', params)
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getPQDIFAllList = () => {
|
||||||
|
return http.get<PQDIF.ResPQDIF[]>('/pqdif/listAll')
|
||||||
|
}
|
||||||
|
|
||||||
|
export const importPQDIFJson = (params: FormData) => {
|
||||||
|
return http.upload('/pqdif/import/json', params, { loading: false })
|
||||||
|
}
|
||||||
@@ -1,6 +1,5 @@
|
|||||||
import type { PqReport } from '@/api/device/interface/report'
|
import type { PqReport } from '@/api/device/interface/report'
|
||||||
import http from '@/api'
|
import http from '@/api'
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @name 报告模版模块
|
* @name 报告模版模块
|
||||||
*/
|
*/
|
||||||
@@ -30,9 +29,8 @@ export const updatePqReport = (params: PqReport.ResReport) => {
|
|||||||
return http.upload(`/report/update`, params)
|
return http.upload(`/report/update`, params)
|
||||||
}
|
}
|
||||||
|
|
||||||
//查询所有报告模板名称
|
export const getPqReportOptions = (params: { pattern: string }) => {
|
||||||
export const getPqReportAllName = () => {
|
return http.get(`/report/listOptions?pattern=${params.pattern}`)
|
||||||
return http.get(`/report/listAllName`)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//根据名称查询指定报告模板的所有版本
|
//根据名称查询指定报告模板的所有版本
|
||||||
|
|||||||
@@ -214,6 +214,10 @@ class RequestHttp {
|
|||||||
return this.service.post(url, params, { ..._object, responseType: 'blob' })
|
return this.service.post(url, params, { ..._object, responseType: 'blob' })
|
||||||
}
|
}
|
||||||
|
|
||||||
|
downloadGetWithHeaders(url: string, _object = {}): Promise<AxiosResponse<Blob>> {
|
||||||
|
return this.service.get(url, { ..._object, responseType: 'blob' })
|
||||||
|
}
|
||||||
|
|
||||||
upload(url: string, params?: object, _object = {}): Promise<BlobPart> {
|
upload(url: string, params?: object, _object = {}): Promise<BlobPart> {
|
||||||
return this.service.post(url, params, {
|
return this.service.post(url, params, {
|
||||||
..._object,
|
..._object,
|
||||||
|
|||||||
@@ -1,5 +1,15 @@
|
|||||||
import http from '@/api'
|
import http from '@/api'
|
||||||
|
|
||||||
|
export interface SntpTimeMessage {
|
||||||
|
type: string
|
||||||
|
deviceIp?: string
|
||||||
|
computerTime?: string
|
||||||
|
deviceTime?: string
|
||||||
|
computerTimestampMs?: number
|
||||||
|
deviceTimestampMs?: number
|
||||||
|
errorMs?: number
|
||||||
|
}
|
||||||
|
|
||||||
export const startSntpService = () => {
|
export const startSntpService = () => {
|
||||||
return http.post('/sntp/start', {})
|
return http.post('/sntp/start', {})
|
||||||
}
|
}
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 9.0 KiB |
BIN
frontend/src/assets/images/logo.png
Normal file
BIN
frontend/src/assets/images/logo.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 112 KiB |
171
frontend/src/components/JsonImportDialog/index.vue
Normal file
171
frontend/src/components/JsonImportDialog/index.vue
Normal file
@@ -0,0 +1,171 @@
|
|||||||
|
<template>
|
||||||
|
<el-dialog
|
||||||
|
v-model="dialogVisible"
|
||||||
|
:title="title"
|
||||||
|
width="460px"
|
||||||
|
destroy-on-close
|
||||||
|
:close-on-click-modal="!loading"
|
||||||
|
:show-close="!loading"
|
||||||
|
>
|
||||||
|
<div v-loading="loading" :element-loading-text="loadingText" class="json-import-content">
|
||||||
|
<el-upload
|
||||||
|
ref="uploadRef"
|
||||||
|
action="#"
|
||||||
|
class="upload"
|
||||||
|
:auto-upload="false"
|
||||||
|
:limit="1"
|
||||||
|
accept=".json,application/json"
|
||||||
|
:on-exceed="handleExceed"
|
||||||
|
:on-change="handleChange"
|
||||||
|
:on-remove="handleRemove"
|
||||||
|
:disabled="loading"
|
||||||
|
>
|
||||||
|
<el-button type="primary" :icon="Upload" :disabled="loading">选择文件</el-button>
|
||||||
|
<template #tip>
|
||||||
|
<div class="el-upload__tip">{{ tip }}</div>
|
||||||
|
</template>
|
||||||
|
</el-upload>
|
||||||
|
<div v-if="loading" class="json-import-loading-text">{{ loadingText }}</div>
|
||||||
|
</div>
|
||||||
|
<template #footer>
|
||||||
|
<div class="dialog-footer">
|
||||||
|
<el-button :disabled="loading" @click="close">取消</el-button>
|
||||||
|
<el-button type="primary" :loading="loading" @click="submit">开始导入</el-button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</el-dialog>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { ref } from 'vue'
|
||||||
|
import { Upload } from '@element-plus/icons-vue'
|
||||||
|
import {
|
||||||
|
ElMessage,
|
||||||
|
ElNotification,
|
||||||
|
genFileId,
|
||||||
|
type UploadFile,
|
||||||
|
type UploadInstance,
|
||||||
|
type UploadProps,
|
||||||
|
type UploadRawFile
|
||||||
|
} from 'element-plus'
|
||||||
|
|
||||||
|
const props = withDefaults(
|
||||||
|
defineProps<{
|
||||||
|
title: string
|
||||||
|
requestApi: (params: FormData) => Promise<unknown>
|
||||||
|
tip?: string
|
||||||
|
loadingText?: string
|
||||||
|
successMessage?: string
|
||||||
|
}>(),
|
||||||
|
{
|
||||||
|
tip: '请上传 .json 文件',
|
||||||
|
loadingText: '导入中,请稍候...',
|
||||||
|
successMessage: '导入成功'
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
const emit = defineEmits<{
|
||||||
|
(e: 'success'): void
|
||||||
|
}>()
|
||||||
|
|
||||||
|
const dialogVisible = ref(false)
|
||||||
|
const loading = ref(false)
|
||||||
|
const uploadRef = ref<UploadInstance | null>(null)
|
||||||
|
const selectedFile = ref<File | null>(null)
|
||||||
|
|
||||||
|
const open = () => {
|
||||||
|
dialogVisible.value = true
|
||||||
|
}
|
||||||
|
|
||||||
|
const close = () => {
|
||||||
|
if (loading.value) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
dialogVisible.value = false
|
||||||
|
selectedFile.value = null
|
||||||
|
uploadRef.value?.clearFiles()
|
||||||
|
}
|
||||||
|
|
||||||
|
const isJsonFile = (file: UploadRawFile | File) => {
|
||||||
|
return file.name.toLowerCase().endsWith('.json') || file.type === 'application/json'
|
||||||
|
}
|
||||||
|
|
||||||
|
const notifyInvalidFile = () => {
|
||||||
|
ElNotification({
|
||||||
|
title: '温馨提示',
|
||||||
|
message: '上传文件只能是 json 格式!',
|
||||||
|
type: 'warning'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const setSelectedFile = (file: UploadRawFile | File | undefined) => {
|
||||||
|
if (!file) {
|
||||||
|
selectedFile.value = null
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (!isJsonFile(file)) {
|
||||||
|
notifyInvalidFile()
|
||||||
|
selectedFile.value = null
|
||||||
|
uploadRef.value?.clearFiles()
|
||||||
|
return
|
||||||
|
}
|
||||||
|
selectedFile.value = file
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleExceed: UploadProps['onExceed'] = files => {
|
||||||
|
uploadRef.value?.clearFiles()
|
||||||
|
const file = files[0] as UploadRawFile
|
||||||
|
file.uid = genFileId()
|
||||||
|
uploadRef.value?.handleStart(file)
|
||||||
|
setSelectedFile(file)
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleChange = (uploadFile: UploadFile) => {
|
||||||
|
setSelectedFile(uploadFile.raw as File | undefined)
|
||||||
|
}
|
||||||
|
|
||||||
|
const handleRemove = () => {
|
||||||
|
selectedFile.value = null
|
||||||
|
}
|
||||||
|
|
||||||
|
const submit = async () => {
|
||||||
|
if (loading.value) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (!selectedFile.value) {
|
||||||
|
ElMessage.warning('请选择文件!')
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
const formData = new FormData()
|
||||||
|
formData.append('file', selectedFile.value)
|
||||||
|
loading.value = true
|
||||||
|
try {
|
||||||
|
await props.requestApi(formData)
|
||||||
|
ElMessage.success(props.successMessage)
|
||||||
|
dialogVisible.value = false
|
||||||
|
selectedFile.value = null
|
||||||
|
uploadRef.value?.clearFiles()
|
||||||
|
emit('success')
|
||||||
|
} finally {
|
||||||
|
loading.value = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
defineExpose({
|
||||||
|
open,
|
||||||
|
close
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.json-import-content {
|
||||||
|
min-height: 120px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.json-import-loading-text {
|
||||||
|
margin-top: 12px;
|
||||||
|
color: var(--el-text-color-secondary);
|
||||||
|
font-size: 13px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -10,7 +10,7 @@
|
|||||||
padding: 0 15px 0 0;
|
padding: 0 15px 0 0;
|
||||||
border-bottom: 1px solid var(--el-header-border-color);
|
border-bottom: 1px solid var(--el-header-border-color);
|
||||||
// background-color: var(--el-header-bg-color);
|
// background-color: var(--el-header-bg-color);
|
||||||
background-color: var(--el-color-primary); //默认蓝色风格背景
|
background-color: #fff; //默认蓝色风格背景
|
||||||
.logo {
|
.logo {
|
||||||
padding:0 10px 0 15px;
|
padding:0 10px 0 15px;
|
||||||
margin-right: 30px;
|
margin-right: 30px;
|
||||||
@@ -23,7 +23,7 @@
|
|||||||
font-size: 21.5px;
|
font-size: 21.5px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
// color: var(--el-header-logo-text-color);
|
// color: var(--el-header-logo-text-color);
|
||||||
color: #fff; // logo文字颜色
|
color: var(--el-color-primary); // logo文字颜色
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -33,15 +33,14 @@
|
|||||||
height: 100%;
|
height: 100%;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
border-bottom: none;
|
border-bottom: none;
|
||||||
background-color: var(--el-color-primary); //导航蓝色背景
|
background-color: #fff; //导航蓝色背景
|
||||||
.el-menu-item {
|
.el-menu-item {
|
||||||
color: #fff;
|
color: var(--el-color-primary);
|
||||||
}
|
}
|
||||||
.el-menu-item:hover {
|
.el-menu-item:hover {
|
||||||
color: #fff; //一级导航划过颜色
|
color: #fff; //一级导航划过颜色
|
||||||
//background-color: #5274a5 !important; //一级导航划过背景色
|
//background-color: #5274a5 !important; //一级导航划过背景色
|
||||||
background-color:var(--el-color-primary-light-3) !important;
|
background-color:var(--el-color-primary-light-4) !important;
|
||||||
|
|
||||||
}
|
}
|
||||||
.el-sub-menu__hide-arrow {
|
.el-sub-menu__hide-arrow {
|
||||||
width: 65px;
|
width: 65px;
|
||||||
@@ -50,15 +49,19 @@
|
|||||||
.el-menu-item.is-active {
|
.el-menu-item.is-active {
|
||||||
color: #fff !important; //一级导航文字选中颜色
|
color: #fff !important; //一级导航文字选中颜色
|
||||||
//background-color: #5274a5 !important; //一级导航选中背景色
|
//background-color: #5274a5 !important; //一级导航选中背景色
|
||||||
background-color: var(--el-color-primary-light-3) !important;
|
background-color: var(--el-color-primary-light-4) !important;
|
||||||
|
|
||||||
border-bottom: 0 !important;
|
border-bottom: 0 !important;
|
||||||
}
|
}
|
||||||
|
.el-sub-menu__title:hover {
|
||||||
|
color: #fff !important;
|
||||||
|
background-color: var(--el-color-primary-light-4) !important;
|
||||||
|
}
|
||||||
.el-sub-menu__title {
|
.el-sub-menu__title {
|
||||||
color: #fff;
|
color: var(--el-color-primary);
|
||||||
}
|
}
|
||||||
.is-opened:hover {
|
.is-opened:hover {
|
||||||
color: #fff;
|
color: var(--el-color-primary);
|
||||||
}
|
}
|
||||||
.is-active {
|
.is-active {
|
||||||
background-color: var(--el-color-primary) !important;
|
background-color: var(--el-color-primary) !important;
|
||||||
@@ -68,12 +71,12 @@
|
|||||||
width: 0;
|
width: 0;
|
||||||
}
|
}
|
||||||
.el-sub-menu__title {
|
.el-sub-menu__title {
|
||||||
color: #fff !important; //二级导航文字选中颜色
|
color: var(--el-color-primary) !important; //二级导航文字选中颜色
|
||||||
// background-color: var(--el-color-primary) !important;
|
// background-color: var(--el-color-primary) !important;
|
||||||
// background-color: #5274a5 !important;//二级导航选中背景色
|
// background-color: #5274a5 !important;//二级导航选中背景色
|
||||||
|
|
||||||
//background-color: #7588e5 !important;
|
//background-color: #7588e5 !important;
|
||||||
background-color: var(--el-color-primary-light-3) !important;
|
background-color: var(--el-color-primary-light-4) !important;
|
||||||
border-bottom-color: var(--el-color-primary) !important;
|
border-bottom-color: var(--el-color-primary) !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<el-header>
|
<el-header>
|
||||||
<div class="logo flx-center">
|
<div class="logo flx-center">
|
||||||
<!-- <img class="logo-img" src="@/assets/images/logo.svg" alt="logo" /> -->
|
<!-- <img class="logo-img" src="@/assets/images/logo.svg" alt="logo" /> -->
|
||||||
<img class="logo-img" src="@/assets/images/cn_pms9100_logo.png" alt="logo" />
|
<img class="logo-img" src="@/assets/images/logo.png" alt="logo" />
|
||||||
<span class="logo-text">{{ title }}</span>
|
<span class="logo-text">{{ title }}</span>
|
||||||
</div>
|
</div>
|
||||||
<el-menu v-if="showMenuFlag" trigger="click" mode="horizontal" :router="false" :default-active="activeMenu">
|
<el-menu v-if="showMenuFlag" trigger="click" mode="horizontal" :router="false" :default-active="activeMenu">
|
||||||
|
|||||||
@@ -20,10 +20,11 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-dropdown>
|
</el-dropdown>
|
||||||
<p style="margin: 0">
|
<p style="margin: 0">
|
||||||
<a href="http://www.shining-electric.com/" target="_blank">2024 © 南京灿能电力自动化股份有限公司</a>
|
<a :href="companyWebsite" target="_blank" rel="noopener noreferrer">{{new Date().getFullYear()}} ©{{companyName}}</a>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { computed } from 'vue'
|
import { computed } from 'vue'
|
||||||
import { useAuthStore } from '@/stores/modules/auth'
|
import { useAuthStore } from '@/stores/modules/auth'
|
||||||
@@ -42,6 +43,10 @@ const title = computed(() => {
|
|||||||
})
|
})
|
||||||
const activateInfo = authStore.activateInfo
|
const activateInfo = authStore.activateInfo
|
||||||
const isActivateOpen = import.meta.env.VITE_ACTIVATE_OPEN
|
const isActivateOpen = import.meta.env.VITE_ACTIVATE_OPEN
|
||||||
|
const companyWebsite = import.meta.env.VITE_COMPANY_WEBSITE
|
||||||
|
const companyName = import.meta.env.VITE_COMPANY_NAME
|
||||||
|
console.log(companyWebsite,companyName)
|
||||||
|
|
||||||
const modeList = [
|
const modeList = [
|
||||||
{
|
{
|
||||||
name: '模拟式模块',
|
name: '模拟式模块',
|
||||||
@@ -62,6 +67,7 @@ const modeList = [
|
|||||||
activated: isActivateOpen === 'true' ? activateInfo.contrast.permanently === 1 : true
|
activated: isActivateOpen === 'true' ? activateInfo.contrast.permanently === 1 : true
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
const handelOpen = async (item: string, key: string) => {
|
const handelOpen = async (item: string, key: string) => {
|
||||||
if (isActivateOpen === 'true' && activateInfo[key].permanently !== 1) {
|
if (isActivateOpen === 'true' && activateInfo[key].permanently !== 1) {
|
||||||
ElMessage.warning(`${item}模块未激活`)
|
ElMessage.warning(`${item}模块未激活`)
|
||||||
@@ -80,11 +86,12 @@ const handelOpen = async (item: string, key: string) => {
|
|||||||
// 如果已在目标页面,手动触发组件更新
|
// 如果已在目标页面,手动触发组件更新
|
||||||
window.location.reload() // 或者采用其他方式刷新数据
|
window.location.reload() // 或者采用其他方式刷新数据
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
@use './index.scss';
|
@use './index.scss';
|
||||||
|
|
||||||
.footer {
|
.footer {
|
||||||
position: relative;
|
position: relative;
|
||||||
background-color: var(--el-color-primary);
|
background-color: var(--el-color-primary);
|
||||||
@@ -101,30 +108,37 @@ const handelOpen = async (item: string, key: string) => {
|
|||||||
height: 100%;
|
height: 100%;
|
||||||
width: auto;
|
width: auto;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
|
|
||||||
.change_mode_down {
|
.change_mode_down {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
.change_mode_up {
|
.change_mode_up {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.change_mode:hover {
|
.change_mode:hover {
|
||||||
.change_mode_down {
|
.change_mode_down {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.change_mode_up {
|
.change_mode_up {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-dropdown {
|
.el-dropdown {
|
||||||
z-index: 1001;
|
z-index: 1001;
|
||||||
}
|
}
|
||||||
|
|
||||||
p {
|
p {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
text-align: right;
|
text-align: right;
|
||||||
line-height: 40px;
|
line-height: 40px;
|
||||||
|
|
||||||
a {
|
a {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
margin-right: 25px; // 增加右边距
|
margin-right: 25px; // 增加右边距
|
||||||
|
|||||||
@@ -56,7 +56,8 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-dropdown>
|
</el-dropdown>
|
||||||
<div class="avatar">
|
<div class="avatar">
|
||||||
<img src="@/assets/icons/out_login.svg" alt="avatar" @click="logout" />
|
<el-button type="text" style="font-size: 18px;color:#fff;" icon="SwitchButton" @click="logout"/>
|
||||||
|
<!-- <img src="@/assets/icons/out_login.svg" alt="avatar" @click="logout" />-->
|
||||||
</div>
|
</div>
|
||||||
<!-- infoDialog -->
|
<!-- infoDialog -->
|
||||||
<InfoDialog ref="infoRef"></InfoDialog>
|
<InfoDialog ref="infoRef"></InfoDialog>
|
||||||
|
|||||||
@@ -45,6 +45,7 @@ import { useTabsStore } from '@/stores/modules/tabs'
|
|||||||
import { useGlobalStore } from '@/stores/modules/global'
|
import { useGlobalStore } from '@/stores/modules/global'
|
||||||
import { useKeepAliveStore } from '@/stores/modules/keepAlive'
|
import { useKeepAliveStore } from '@/stores/modules/keepAlive'
|
||||||
import { useRoute, useRouter } from 'vue-router'
|
import { useRoute, useRouter } from 'vue-router'
|
||||||
|
import mittBus, { TAB_CLOSED_EVENT } from '@/utils/mittBus'
|
||||||
|
|
||||||
const route = useRoute()
|
const route = useRoute()
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
@@ -73,6 +74,7 @@ const maximize = () => {
|
|||||||
// Close Current
|
// Close Current
|
||||||
const closeCurrentTab = () => {
|
const closeCurrentTab = () => {
|
||||||
if (route.meta.isAffix) return
|
if (route.meta.isAffix) return
|
||||||
|
mittBus.emit(TAB_CLOSED_EVENT, route.fullPath)
|
||||||
tabStore.removeTabs(route.fullPath)
|
tabStore.removeTabs(route.fullPath)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -31,6 +31,7 @@ import { useTabsStore } from '@/stores/modules/tabs'
|
|||||||
import { useAuthStore } from '@/stores/modules/auth'
|
import { useAuthStore } from '@/stores/modules/auth'
|
||||||
import { TabPaneName, TabsPaneContext } from 'element-plus'
|
import { TabPaneName, TabsPaneContext } from 'element-plus'
|
||||||
import MoreButton from './components/MoreButton.vue'
|
import MoreButton from './components/MoreButton.vue'
|
||||||
|
import mittBus, { TAB_CLOSED_EVENT } from '@/utils/mittBus'
|
||||||
|
|
||||||
const route = useRoute()
|
const route = useRoute()
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
@@ -110,6 +111,7 @@ const tabClick = (tabItem: TabsPaneContext) => {
|
|||||||
|
|
||||||
// Remove Tab
|
// Remove Tab
|
||||||
const tabRemove = (fullPath: TabPaneName) => {
|
const tabRemove = (fullPath: TabPaneName) => {
|
||||||
|
mittBus.emit(TAB_CLOSED_EVENT, fullPath as string)
|
||||||
tabStore.removeTabs(fullPath as string, fullPath == route.fullPath || '/machine/testScriptAdd' == route.fullPath)
|
tabStore.removeTabs(fullPath as string, fullPath == route.fullPath || '/machine/testScriptAdd' == route.fullPath)
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -7,75 +7,60 @@ import { useModeStore } from '@/stores/modules/mode'
|
|||||||
import { getLicense } from '@/api/activate'
|
import { getLicense } from '@/api/activate'
|
||||||
import type { Activate } from '@/api/activate/interface'
|
import type { Activate } from '@/api/activate/interface'
|
||||||
|
|
||||||
|
const CONTRAST_MODE_NAME = '比对式'
|
||||||
|
|
||||||
export const useAuthStore = defineStore(AUTH_STORE_KEY, {
|
export const useAuthStore = defineStore(AUTH_STORE_KEY, {
|
||||||
state: (): AuthState => ({
|
state: (): AuthState => ({
|
||||||
// 按钮权限列表
|
|
||||||
authButtonList: {},
|
authButtonList: {},
|
||||||
// 菜单权限列表
|
|
||||||
authMenuList: [],
|
authMenuList: [],
|
||||||
// 当前页面的 router name,用来做按钮权限筛选
|
|
||||||
routeName: '',
|
routeName: '',
|
||||||
//登录不显示菜单栏和导航栏,点击进入测试的时候显示
|
|
||||||
showMenuFlag: JSON.parse(localStorage.getItem('showMenuFlag') as string),
|
showMenuFlag: JSON.parse(localStorage.getItem('showMenuFlag') as string),
|
||||||
activateInfo: {} as Activate.ActivationCodePlaintext
|
activateInfo: {} as Activate.ActivationCodePlaintext
|
||||||
}),
|
}),
|
||||||
getters: {
|
getters: {
|
||||||
// 按钮权限列表
|
|
||||||
authButtonListGet: state => state.authButtonList,
|
authButtonListGet: state => state.authButtonList,
|
||||||
// 菜单权限列表 ==> 这里的菜单没有经过任何处理
|
|
||||||
authMenuListGet: state => state.authMenuList,
|
authMenuListGet: state => state.authMenuList,
|
||||||
// 菜单权限列表 ==> 左侧菜单栏渲染,需要剔除 isHide == true
|
|
||||||
showMenuListGet: state => getShowMenuList(state.authMenuList),
|
showMenuListGet: state => getShowMenuList(state.authMenuList),
|
||||||
// 菜单权限列表 ==> 扁平化之后的一维数组菜单,主要用来添加动态路由
|
|
||||||
flatMenuListGet: state => getFlatMenuList(state.authMenuList),
|
flatMenuListGet: state => getFlatMenuList(state.authMenuList),
|
||||||
// 递归处理后的所有面包屑导航列表
|
|
||||||
breadcrumbListGet: state => getAllBreadcrumbList(state.authMenuList),
|
breadcrumbListGet: state => getAllBreadcrumbList(state.authMenuList),
|
||||||
//是否显示菜单和导航栏
|
|
||||||
showMenuFlagGet: state => state.showMenuFlag,
|
showMenuFlagGet: state => state.showMenuFlag,
|
||||||
// 获取激活信息
|
|
||||||
activateInfoGet: state => state.activateInfo
|
activateInfoGet: state => state.activateInfo
|
||||||
},
|
},
|
||||||
actions: {
|
actions: {
|
||||||
// Get AuthButtonList
|
|
||||||
async getAuthButtonList() {
|
async getAuthButtonList() {
|
||||||
const { data } = await getAuthButtonListApi()
|
const { data } = await getAuthButtonListApi()
|
||||||
this.authButtonList = data
|
this.authButtonList = data
|
||||||
},
|
},
|
||||||
// Get AuthMenuList
|
|
||||||
async getAuthMenuList() {
|
async getAuthMenuList() {
|
||||||
const modeStore = useModeStore()
|
const modeStore = useModeStore()
|
||||||
|
|
||||||
const { data: menuData } = await getAuthMenuListApi()
|
const { data: menuData } = await getAuthMenuListApi()
|
||||||
// 根据不同模式过滤菜单
|
|
||||||
const filteredMenu =
|
const isContrastMode = modeStore.currentMode === CONTRAST_MODE_NAME
|
||||||
modeStore.currentMode === '比对式'
|
const filteredMenu = isContrastMode
|
||||||
? filterMenuByExcludedNames(menuData, ['testSource', 'testScript', 'controlSource'])
|
? filterMenuByExcludedNames(menuData, ['testSource', 'testScript', 'controlSource'])
|
||||||
: filterMenuByExcludedNames(menuData, ['standardDevice'])
|
: filterMenuByExcludedNames(menuData, ['standardDevice'])
|
||||||
|
|
||||||
this.authMenuList = filteredMenu
|
this.authMenuList = filterMenuByExcludedNames(filteredMenu, ['sntp'])
|
||||||
},
|
},
|
||||||
// Set RouteName
|
|
||||||
async setRouteName(name: string) {
|
async setRouteName(name: string) {
|
||||||
this.routeName = name
|
this.routeName = name
|
||||||
},
|
},
|
||||||
//重置权限
|
|
||||||
async resetAuthStore() {
|
async resetAuthStore() {
|
||||||
this.showMenuFlag = false
|
this.showMenuFlag = false
|
||||||
localStorage.removeItem('showMenuFlag')
|
localStorage.removeItem('showMenuFlag')
|
||||||
},
|
},
|
||||||
//修改判断菜单栏/导航栏显示条件
|
|
||||||
async setShowMenu() {
|
async setShowMenu() {
|
||||||
this.showMenuFlag = true
|
this.showMenuFlag = true
|
||||||
localStorage.setItem('showMenuFlag', 'true')
|
localStorage.setItem('showMenuFlag', 'true')
|
||||||
},
|
},
|
||||||
//更改模式
|
|
||||||
changeModel() {
|
changeModel() {
|
||||||
this.showMenuFlag = false
|
this.showMenuFlag = false
|
||||||
localStorage.removeItem('showMenuFlag')
|
localStorage.removeItem('showMenuFlag')
|
||||||
},
|
},
|
||||||
async setActivateInfo() {
|
async setActivateInfo() {
|
||||||
const license_result = await getLicense()
|
const licenseResult = await getLicense()
|
||||||
const licenseData = license_result.data as Activate.ActivationCodePlaintext
|
const licenseData = licenseResult.data as Activate.ActivationCodePlaintext
|
||||||
|
|
||||||
if (!licenseData.simulate) {
|
if (!licenseData.simulate) {
|
||||||
licenseData.simulate = {
|
licenseData.simulate = {
|
||||||
permanently: 0
|
permanently: 0
|
||||||
@@ -91,24 +76,18 @@ export const useAuthStore = defineStore(AUTH_STORE_KEY, {
|
|||||||
permanently: 0
|
permanently: 0
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
this.activateInfo = licenseData
|
this.activateInfo = licenseData
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
/**
|
function filterMenuByExcludedNames(menuList: Menu.MenuOptions[], excludedNames: string[]): Menu.MenuOptions[] {
|
||||||
* 通用菜单过滤函数
|
|
||||||
* @param menuList 菜单列表
|
|
||||||
* @param excludedNames 需要排除的菜单名称数组
|
|
||||||
* @returns 过滤后的菜单列表
|
|
||||||
*/
|
|
||||||
function filterMenuByExcludedNames(menuList: any[], excludedNames: string[]): any[] {
|
|
||||||
return menuList.filter(menu => {
|
return menuList.filter(menu => {
|
||||||
// 如果当前项有 children,递归处理子项
|
|
||||||
if (menu.children && menu.children.length > 0) {
|
if (menu.children && menu.children.length > 0) {
|
||||||
menu.children = filterMenuByExcludedNames(menu.children, excludedNames)
|
menu.children = filterMenuByExcludedNames(menu.children, excludedNames)
|
||||||
}
|
}
|
||||||
// 过滤掉在排除列表中的菜单项
|
|
||||||
return !excludedNames.includes(menu.name)
|
return !excludedNames.includes(menu.name)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
4
frontend/src/types/env.d.ts
vendored
4
frontend/src/types/env.d.ts
vendored
@@ -27,7 +27,11 @@ declare interface ViteEnv {
|
|||||||
VITE_PWA: boolean;
|
VITE_PWA: boolean;
|
||||||
VITE_PUBLIC_PATH: string;
|
VITE_PUBLIC_PATH: string;
|
||||||
VITE_API_URL: string;
|
VITE_API_URL: string;
|
||||||
|
VITE_COMPANY_WEBSITE: string;
|
||||||
|
VITE_COMPANY_NAME:string;
|
||||||
VITE_PROXY: [string, string][];
|
VITE_PROXY: [string, string][];
|
||||||
|
VITE_IS_SHOW_RAW_DATA:boolean;
|
||||||
|
VITE_ACTIVATE_OPEN:boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
interface ImportMetaEnv extends ViteEnv {
|
interface ImportMetaEnv extends ViteEnv {
|
||||||
|
|||||||
@@ -1,10 +1,12 @@
|
|||||||
import mitt from "mitt";
|
import mitt from "mitt";
|
||||||
|
|
||||||
export const STOP_DETECTION_TIMER_EVENT = "stopDetectionTimer";
|
export const STOP_DETECTION_TIMER_EVENT = "stopDetectionTimer";
|
||||||
|
export const TAB_CLOSED_EVENT = "tabClosed";
|
||||||
|
|
||||||
type MittBusEvents = {
|
type MittBusEvents = {
|
||||||
openThemeDrawer: undefined;
|
openThemeDrawer: undefined;
|
||||||
[STOP_DETECTION_TIMER_EVENT]: undefined;
|
[STOP_DETECTION_TIMER_EVENT]: undefined;
|
||||||
|
[TAB_CLOSED_EVENT]: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
const mittBus = mitt<MittBusEvents>();
|
const mittBus = mitt<MittBusEvents>();
|
||||||
|
|||||||
@@ -192,8 +192,7 @@ export default class SocketService {
|
|||||||
* WebSocket连接配置
|
* WebSocket连接配置
|
||||||
*/
|
*/
|
||||||
private config: SocketConfig = {
|
private config: SocketConfig = {
|
||||||
// url: 'ws://127.0.0.1:7778/hello',
|
url: `ws://127.0.0.1:7778/hello`,
|
||||||
url: 'ws://127.0.0.1:7778/hello',
|
|
||||||
heartbeatInterval: 9000, // 9秒心跳间隔
|
heartbeatInterval: 9000, // 9秒心跳间隔
|
||||||
reconnectDelay: 5000, // 5秒重连延迟
|
reconnectDelay: 5000, // 5秒重连延迟
|
||||||
maxReconnectAttempts: 5, // 最多重连5次
|
maxReconnectAttempts: 5, // 最多重连5次
|
||||||
|
|||||||
@@ -6,9 +6,9 @@
|
|||||||
style="width: 100%;">
|
style="width: 100%;">
|
||||||
<el-table-column type="index" label="序号" width="70" fixed="left"/>
|
<el-table-column type="index" label="序号" width="70" fixed="left"/>
|
||||||
<el-table-column prop="time" label="数据时间"/>
|
<el-table-column prop="time" label="数据时间"/>
|
||||||
<el-table-column v-if="!isThreePhase && phaseA==1" prop="dataA" :label="'A相'+(unit==''?'':'('+unit+')')"/>
|
<el-table-column v-if="!isThreePhase && phaseA==1" prop="dataA" :label="labelA+(unit==''?'':'('+unit+')')"/>
|
||||||
<el-table-column v-if="!isThreePhase && phaseB==1" prop="dataB" :label="'B相'+(unit==''?'':'('+unit+')')"/>
|
<el-table-column v-if="!isThreePhase && phaseB==1" prop="dataB" :label="labelB+(unit==''?'':'('+unit+')')"/>
|
||||||
<el-table-column v-if="!isThreePhase && phaseC==1" prop="dataC" :label="'C相'+(unit==''?'':'('+unit+')')"/>
|
<el-table-column v-if="!isThreePhase && phaseC==1" prop="dataC" :label="labelC+(unit==''?'':'('+unit+')')"/>
|
||||||
<el-table-column v-if="!isThreePhase && phaseT === 1" prop="dataT" :label="tableHeader+(unit==''?'':'('+unit+')')"/>
|
<el-table-column v-if="!isThreePhase && phaseT === 1" prop="dataT" :label="tableHeader+(unit==''?'':'('+unit+')')"/>
|
||||||
<el-table-column v-if="isThreePhase" prop="dataB" :label="'负序不平衡度'+(unit==''?'':'('+unit+')')"/>
|
<el-table-column v-if="isThreePhase" prop="dataB" :label="'负序不平衡度'+(unit==''?'':'('+unit+')')"/>
|
||||||
</el-table>
|
</el-table>
|
||||||
@@ -20,13 +20,30 @@
|
|||||||
import {CheckData} from "@/api/check/interface";
|
import {CheckData} from "@/api/check/interface";
|
||||||
import {computed} from "vue";
|
import {computed} from "vue";
|
||||||
|
|
||||||
const {tableData, currentScriptTypeName} = defineProps<{
|
const {tableData, currentCheckItem} = defineProps<{
|
||||||
tableData: CheckData.RawDataItem[]
|
tableData: CheckData.RawDataItem[]
|
||||||
currentScriptTypeName: string
|
currentCheckItem: string
|
||||||
}>()
|
}>()
|
||||||
|
|
||||||
const emit = defineEmits(['exportRawDataHandler'])
|
const emit = defineEmits(['exportRawDataHandler'])
|
||||||
|
const labelA = computed(() => {
|
||||||
|
if(currentCheckItem.includes('电压序分量')){
|
||||||
|
return '正序分量'
|
||||||
|
}
|
||||||
|
return 'A相'
|
||||||
|
})
|
||||||
|
const labelB = computed(() => {
|
||||||
|
if(currentCheckItem.includes('电压序分量')){
|
||||||
|
return '负序分量'
|
||||||
|
}
|
||||||
|
return 'B相'
|
||||||
|
})
|
||||||
|
const labelC = computed(() => {
|
||||||
|
if(currentCheckItem.includes('电压序分量')){
|
||||||
|
return '零序分量'
|
||||||
|
}
|
||||||
|
return 'C相'
|
||||||
|
})
|
||||||
const unit = computed(() => {
|
const unit = computed(() => {
|
||||||
return tableData.length > 0 ? tableData[0].unit : '';
|
return tableData.length > 0 ? tableData[0].unit : '';
|
||||||
})
|
})
|
||||||
@@ -46,15 +63,16 @@ const phaseT = computed(() => {
|
|||||||
})
|
})
|
||||||
|
|
||||||
const tableHeader = computed(() => {
|
const tableHeader = computed(() => {
|
||||||
if (phaseT.value === 1) {
|
if(currentCheckItem.includes('三相电压负序不平衡度')){
|
||||||
let index = currentScriptTypeName.indexOf('=');
|
return '三相电压不平衡度'
|
||||||
return currentScriptTypeName.substring(0, index);
|
|
||||||
}
|
}
|
||||||
return currentScriptTypeName
|
if(currentCheckItem.includes('三相电流负序不平衡度')){
|
||||||
|
return '三相电流不平衡度'
|
||||||
|
}
|
||||||
|
return currentCheckItem
|
||||||
})
|
})
|
||||||
|
|
||||||
const isThreePhase = computed(() => {
|
const isThreePhase = computed(() => {
|
||||||
return currentScriptTypeName.includes('三相电压不平衡度') || currentScriptTypeName.includes('三相电流不平衡度')
|
return currentCheckItem.includes('三相电压负序不平衡度') || currentCheckItem.includes('三相电流负序不平衡度')
|
||||||
})
|
})
|
||||||
|
|
||||||
const exportData = () => {
|
const exportData = () => {
|
||||||
|
|||||||
@@ -12,10 +12,10 @@
|
|||||||
<!-- {{ '通道' + row.chnNum }}-->
|
<!-- {{ '通道' + row.chnNum }}-->
|
||||||
<!-- </template>-->
|
<!-- </template>-->
|
||||||
<!-- </el-table-column>-->
|
<!-- </el-table-column>-->
|
||||||
<el-table-column label="A相" v-if="phaseA === 1">
|
<el-table-column :label="labelA" v-if="phaseA === 1">
|
||||||
<el-table-column prop="stdA" :label="'标准值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
<el-table-column prop="stdA" :label="'标准值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
||||||
<el-table-column prop="dataA" :label="'被检值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
<el-table-column prop="dataA" :label="'被检值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
||||||
<el-table-column prop="isDataA" label="检测结果">
|
<el-table-column prop="isDataA" label="检测结果" width="90px">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<template v-if="scope.row.isDataA === 4 || scope.row.isDataA === 5">
|
<template v-if="scope.row.isDataA === 4 || scope.row.isDataA === 5">
|
||||||
<el-tag type="warning" v-if="scope.row.isDataA === 4">/</el-tag>
|
<el-tag type="warning" v-if="scope.row.isDataA === 4">/</el-tag>
|
||||||
@@ -33,10 +33,10 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="B相" v-if="phaseB === 1">
|
<el-table-column :label="labelB" v-if="phaseB === 1">
|
||||||
<el-table-column prop="stdB" :label="'标准值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
<el-table-column prop="stdB" :label="'标准值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
||||||
<el-table-column prop="dataB" :label="'被检值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
<el-table-column prop="dataB" :label="'被检值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
||||||
<el-table-column prop="isDataB" label="检测结果">
|
<el-table-column prop="isDataB" label="检测结果" width="90px">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<template v-if="scope.row.isDataB === 4 || scope.row.isDataB === 5">
|
<template v-if="scope.row.isDataB === 4 || scope.row.isDataB === 5">
|
||||||
<el-tag type="warning" v-if="scope.row.isDataB === 4">/</el-tag>
|
<el-tag type="warning" v-if="scope.row.isDataB === 4">/</el-tag>
|
||||||
@@ -55,10 +55,10 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="C相" v-if="phaseC === 1">
|
<el-table-column :label="labelC" v-if="phaseC === 1">
|
||||||
<el-table-column prop="stdC" :label="'标准值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
<el-table-column prop="stdC" :label="'标准值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
||||||
<el-table-column prop="dataC" :label="'被检值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
<el-table-column prop="dataC" :label="'被检值' + (outerUnit == '' ? '' : '(' + outerUnit + ')')" />
|
||||||
<el-table-column prop="isDataC" label="检测结果">
|
<el-table-column prop="isDataC" label="检测结果" width="90px">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<template v-if="scope.row.isDataC === 4 || scope.row.isDataC === 5">
|
<template v-if="scope.row.isDataC === 4 || scope.row.isDataC === 5">
|
||||||
<el-tag type="warning" v-if="scope.row.isDataC === 4">/</el-tag>
|
<el-tag type="warning" v-if="scope.row.isDataC === 4">/</el-tag>
|
||||||
@@ -107,9 +107,9 @@
|
|||||||
import { computed } from 'vue'
|
import { computed } from 'vue'
|
||||||
import { CheckData } from '@/api/check/interface'
|
import { CheckData } from '@/api/check/interface'
|
||||||
|
|
||||||
const { tableData, currentScriptTypeName } = defineProps<{
|
const { tableData, currentCheckItem } = defineProps<{
|
||||||
tableData: CheckData.CheckResult[]
|
tableData: CheckData.CheckResult[]
|
||||||
currentScriptTypeName: string
|
currentCheckItem: string
|
||||||
}>()
|
}>()
|
||||||
|
|
||||||
const outerUnit = computed(() => {
|
const outerUnit = computed(() => {
|
||||||
@@ -129,6 +129,25 @@ const innerUnitT = computed(() => {
|
|||||||
return tableData.length > 0 ? tableData[0].unitT : ''
|
return tableData.length > 0 ? tableData[0].unitT : ''
|
||||||
})
|
})
|
||||||
|
|
||||||
|
const labelA = computed(() => {
|
||||||
|
if(currentCheckItem.includes('电压序分量')){
|
||||||
|
return '正序分量'
|
||||||
|
}
|
||||||
|
return 'A相'
|
||||||
|
})
|
||||||
|
const labelB = computed(() => {
|
||||||
|
if(currentCheckItem.includes('电压序分量')){
|
||||||
|
return '负序分量'
|
||||||
|
}
|
||||||
|
return 'B相'
|
||||||
|
})
|
||||||
|
const labelC = computed(() => {
|
||||||
|
if(currentCheckItem.includes('电压序分量')){
|
||||||
|
return '零序分量'
|
||||||
|
}
|
||||||
|
return 'C相'
|
||||||
|
})
|
||||||
|
|
||||||
const phaseA = computed(() => {
|
const phaseA = computed(() => {
|
||||||
return tableData.length <= 0 || tableData[0].dataA == null || tableData[0].dataA == '/' ? 0 : 1
|
return tableData.length <= 0 || tableData[0].dataA == null || tableData[0].dataA == '/' ? 0 : 1
|
||||||
})
|
})
|
||||||
@@ -144,11 +163,13 @@ const phaseT = computed(() => {
|
|||||||
})
|
})
|
||||||
|
|
||||||
const tableHeader = computed(() => {
|
const tableHeader = computed(() => {
|
||||||
if (phaseT.value === 1) {
|
if(currentCheckItem.includes('三相电压负序不平衡度')){
|
||||||
let index = currentScriptTypeName.indexOf('=')
|
return '三相电压不平衡度'
|
||||||
return currentScriptTypeName.substring(0, index)
|
|
||||||
}
|
}
|
||||||
return currentScriptTypeName
|
if(currentCheckItem.includes('三相电流负序不平衡度')){
|
||||||
|
return '三相电流不平衡度'
|
||||||
|
}
|
||||||
|
return currentCheckItem
|
||||||
})
|
})
|
||||||
|
|
||||||
// const maxErrorStr = computed((data) => {
|
// const maxErrorStr = computed((data) => {
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user