调整云南曲靖问题

This commit is contained in:
guanj
2026-01-16 14:03:40 +08:00
parent 0b76347853
commit a19952b771
21 changed files with 856 additions and 855 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 263 KiB

After

Width:  |  Height:  |  Size: 243 KiB

View File

@@ -1,441 +1,441 @@
<template>
<div v-loading="loading">
<div>
<div id="boxi" :style="`height:${vh};overflow: hidden;`">
<div class="bx" id="wave"></div>
</div>
<el-tabs type="border-card">
<el-tab-pane label="暂态波形上送" :style="'height:' + vhh">
<el-table stripe :data="Data" :height="height" border style="width: 100%"
header-cell-class-name="table_header">
<el-table-column align="center" prop="number" label="事件段"></el-table-column>
<el-table-column align="center" prop="number" label="波形起始点相位(°)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="跳变段电压变化率(V/ms)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="相位跳变(°)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="总分段数目"></el-table-column>
<el-table-column align="center" prop="number" label="三相电压不平衡度(%)" width="180"></el-table-column>
<el-table-column align="center" prop="number" label="暂降类型"></el-table-column>
<el-table-column align="center" prop="number" label="暂降原因"></el-table-column>
</el-table>
</el-tab-pane>
</el-tabs>
</div>
</div>
</template>
<script>
import { downloadWaveFile, getMonitorEventAnalyseWave } from '@/api/event-boot/transient'
import { mainHeight } from '@/utils/layout'
import * as echarts from 'echarts'
import url from '@/assets/img/point.png'
import $ from 'jquery'
export default {
props: {
flag: {
type: Boolean,
default: false
},
DColor: {
type: Boolean,
default: false
},
boxoList: {
type: [Object, Array]
},
GJList: {
type: [Object, Array]
}
},
data() {
return {
loading: true,
valA: 0,
isOpen: false,
time: '',
type: '',
severity: '',
iphasic: '',
eventValue: '',
persistTime: '',
lineName: '',
subName: '',
waveDatas: [],
Data: [],
height: null,
vhh: null,
ptpass: '',
waveHeight: undefined,
$wave: undefined,
color: '#006565',
charts: {},
arrpoints: [],
titles: '',
vh: null,
vw: null,
zoom: ''
}
},
created() { },
watch: {
value: function (a, b) {
if (a == 2) {
// $("#wave1").remove();
this.initWaves()
} else {
$('#wave1').remove()
this.initWaves()
}
}
},
mounted() {
this.setHeight()
window.addEventListener('resize', this.setHeight)
this.$wave = $('#wave').eq(0)
this.$nextTick(() => {
this.query()
})
},
beforeDestroy() {
window.removeEventListener('resize', this.setHeight)
},
methods: {
setHeight() {
this.zoom = 1 / document.body.style.zoom
if (this.flag) {
// console.log(123);
this.vh = mainHeight(250).height
} else {
// console.log(3333);
this.vh = mainHeight(270).height
}
},
query() {
this.loading = true
this.initWave()
},
//开始画图
initWave() {
//清除之前增加的div
// $("#wave ~ .bx1").remove();
$('div.bx1').remove()
//设置暂降触发点的位置 一次值与二次值Y轴不同不是计算出来的
// var height = $(window).height() - 90;
var picHeight
var show = true
//var v = $("#interval").val();
var isvisible = false
picHeight = this.vh
// this.$wave.css('height', picHeight)
// this.$wave.css('width', '100%')
$('#wave').css('height', picHeight)
$('#wave').css('width', this.vw)
var adata = []
var bdata = []
var cdata = []
var max = 0
var min = 0
//绘制横向第一个波形图
this.GJList.smp_x.forEach((item, ind) => {
if (this.GJList.smp_a[ind] > max) {
max = this.GJList.smp_a[ind]
} else if (this.GJList.smp_a[ind] < min) {
min = this.GJList.smp_a[ind]
}
if (this.GJList.smp_b[ind] > max) {
max = this.GJList.smp_b[ind]
} else if (this.GJList.smp_b[ind] < min) {
min = this.GJList.smp_b[ind]
}
if (this.GJList.smp_c[ind] > max) {
max = this.GJList.smp_c[ind]
} else if (this.GJList.smp_c[ind] < min) {
min = this.GJList.smp_c[ind]
}
adata.push([item, this.GJList.smp_a[ind]])
bdata.push([item, this.GJList.smp_b[ind]])
cdata.push([item, this.GJList.smp_c[ind]])
})
//绘制瞬时波形图
// const echarts = require('echarts')
let wave = document.getElementById('wave')
let _this = this
var myChartes = echarts.init(wave)
let echartsColor = {
WordColor: '#000',
thread: '#000000',
FigureColor: [
'#07CCCA ',
'#00BFF5',
'#FFBF00',
'#77DA63',
'#D5FF6B',
'#Ff6600',
'#FF9100',
'#5B6E96',
'#66FFCC',
'#B3B3B3',
'#FF00FF',
'#CC00FF',
'#FF9999'
]
}
var option = {
tooltip: {
top: '10px',
trigger: 'axis',
borderColor: 'grey',
backgroundColor: '#fff',
style: {
color: '#000',
fontSize: '15px',
padding: 10
},
formatter: function (params) {
// console.log(params)
var tips = ''
tips += '时刻:' + params[0].data[0] + '</br/>'
for (var i = 0; i < params.length; i++) {
if (params[i].seriesName != '暂降触发点') {
tips += params[i].seriesName + ':' + params[i].value[1] + '<br/>'
}
}
return tips
},
// axisPointer: {
// type: "cross",
// label: {
// color: "#fff",
// fontSize: 16,
// },
// },
textStyle: {
color: '#fff',
fontStyle: 'normal',
opacity: 0.35,
fontSize: 14
},
backgroundColor: 'rgba(0,0,0,0.55)',
borderWidth: 0
},
title: {
left: 'center',
text: '发生时刻:' + this.boxoList.startTime + ' PT变化:' + this.boxoList.measurementPointName,
textStyle: {
fontSize: 16,
color: _this.DColor ? '#fff' : echartsColor.WordColor
}
},
legend: {
left: '5%',
top: '20',
verticalAlign: 'top',
enabled: true,
itemDistance: 5,
textStyle: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
rich: {
a: {
verticalAlign: 'middle'
}
},
padding: [2, 0, 0, 0] //[上、右、下、左]
}
},
toolbox: {
show: false,
feature: {
//restore: {},
saveAsImage: {
iconStyle: {
borderColor: _this.DColor ? '#fff' : echartsColor.WordColor
}
}
}
},
xAxis: {
type: 'value',
name: '时刻',
boundaryGap: false,
min: this.GJList.smp_x[0],
max: this.GJList.smp_x[this.GJList.smp_x.length - 1] + 1,
title: {
text: 'ms',
textStyle: {
fontSize: 12,
color: _this.DColor ? '#fff' : echartsColor.WordColor
},
enabled: true,
align: 'high'
},
splitLine: {
show: false
},
axisTick: {
alignWithLabel: true
},
axisLine: {
lineStyle: {
color: _this.DColor ? '#fff' : echartsColor.thread
},
onZero: false //-----------重点
},
axisLabel: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
formatter: function (value, index) {
if (_this.valA != (value - 0).toFixed(0)) {
_this.valA = (value - 0).toFixed(0)
return (value - 0).toFixed(0)
}
}
//rotate:39
}
// data: this.syncExtremes,
},
yAxis: {
type: 'value',
name: 'kV',
title: {
align: 'high',
offset: 0,
text: 'kV',
rotation: 0,
y: -10
},
boundaryGap: [0, '100%'],
showLastLabel: true,
max: (max + 10).toFixed(2),
min: (min - 10).toFixed(2),
opposite: false,
nameTextStyle: {
color: _this.DColor ? '#fff' : echartsColor.WordColor
},
//minInterval: 1,
type: 'value',
axisLine: {
show: true,
lineStyle: {
color: _this.DColor ? '#fff' : echartsColor.thread
},
onZero: false //-----------重点
},
axisLabel: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
formatter: function (value, index) {
return (value - 0).toFixed(2)
}
},
splitLine: {
lineStyle: {
// 使用深浅的间隔色
color: [_this.DColor ? '#fff' : echartsColor.thread],
type: 'dashed',
opacity: 0.5
}
}
},
grid: {
left: '1%',
right: '40px',
bottom: '40px',
top: '55px',
containLabel: true
},
dataZoom: [
{
type: 'inside',
height: 13,
start: 0,
bottom: '20px',
end: 100
},
{
start: 0,
height: 13,
bottom: '20px',
end: 100
}
],
series: [
{
name: 'A相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#DAA520'
},
data: adata
},
{
name: 'B相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#2E8B57'
},
data: bdata
},
{
name: 'C相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#A52a2a'
},
data: cdata
},
{
name: '暂降触发点',
type: 'scatter',
symbol: 'image://' + url,
itemStyle: {
width: 16,
height: 16
},
data: [[0, min]]
}
]
}
myChartes.setOption(option)
// window.echartsArr.push(myChartes)
setTimeout(() => {
myChartes.resize()
this.loading = false
}, 400)
//第一个波形图数据绘制完毕后,绘制后续的波形图
// let waveDatasTemp = waveDatas.slice(1);
// waveDatasTemp.reverse();
}
}
}
</script>
<template>
<div v-loading="loading">
<div>
<div id="boxi" :style="`height:${vh};overflow: hidden;`">
<div class="bx" id="wave"></div>
</div>
<el-tabs type="border-card">
<el-tab-pane label="暂态波形上送" :style="'height:' + vhh">
<el-table stripe :data="Data" :height="height" border style="width: 100%"
header-cell-class-name="table_header">
<el-table-column align="center" prop="number" label="事件段"></el-table-column>
<el-table-column align="center" prop="number" label="波形起始点相位(°)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="跳变段电压变化率(V/ms)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="相位跳变(°)">
<el-table-column align="center" prop="number" label="A相"></el-table-column>
<el-table-column align="center" prop="number" label="B相"></el-table-column>
<el-table-column align="center" prop="number" label="C相"></el-table-column>
</el-table-column>
<el-table-column align="center" prop="number" label="总分段数目"></el-table-column>
<el-table-column align="center" prop="number" label="三相电压不平衡度(%)" width="180"></el-table-column>
<el-table-column align="center" prop="number" label="触发类型"></el-table-column>
<el-table-column align="center" prop="number" label="暂降原因"></el-table-column>
</el-table>
</el-tab-pane>
</el-tabs>
</div>
</div>
</template>
<script>
import { downloadWaveFile, getMonitorEventAnalyseWave } from '@/api/event-boot/transient'
import { mainHeight } from '@/utils/layout'
import * as echarts from 'echarts'
import url from '@/assets/img/point.png'
import $ from 'jquery'
export default {
props: {
flag: {
type: Boolean,
default: false
},
DColor: {
type: Boolean,
default: false
},
boxoList: {
type: [Object, Array]
},
GJList: {
type: [Object, Array]
}
},
data() {
return {
loading: true,
valA: 0,
isOpen: false,
time: '',
type: '',
severity: '',
iphasic: '',
eventValue: '',
persistTime: '',
lineName: '',
subName: '',
waveDatas: [],
Data: [],
height: null,
vhh: null,
ptpass: '',
waveHeight: undefined,
$wave: undefined,
color: '#006565',
charts: {},
arrpoints: [],
titles: '',
vh: null,
vw: null,
zoom: ''
}
},
created() { },
watch: {
value: function (a, b) {
if (a == 2) {
// $("#wave1").remove();
this.initWaves()
} else {
$('#wave1').remove()
this.initWaves()
}
}
},
mounted() {
this.setHeight()
window.addEventListener('resize', this.setHeight)
this.$wave = $('#wave').eq(0)
this.$nextTick(() => {
this.query()
})
},
beforeDestroy() {
window.removeEventListener('resize', this.setHeight)
},
methods: {
setHeight() {
this.zoom = 1 / document.body.style.zoom
if (this.flag) {
// console.log(123);
this.vh = mainHeight(250).height
} else {
// console.log(3333);
this.vh = mainHeight(270).height
}
},
query() {
this.loading = true
this.initWave()
},
//开始画图
initWave() {
//清除之前增加的div
// $("#wave ~ .bx1").remove();
$('div.bx1').remove()
//设置暂降触发点的位置 一次值与二次值Y轴不同不是计算出来的
// var height = $(window).height() - 90;
var picHeight
var show = true
//var v = $("#interval").val();
var isvisible = false
picHeight = this.vh
// this.$wave.css('height', picHeight)
// this.$wave.css('width', '100%')
$('#wave').css('height', picHeight)
$('#wave').css('width', this.vw)
var adata = []
var bdata = []
var cdata = []
var max = 0
var min = 0
//绘制横向第一个波形图
this.GJList.smp_x.forEach((item, ind) => {
if (this.GJList.smp_a[ind] > max) {
max = this.GJList.smp_a[ind]
} else if (this.GJList.smp_a[ind] < min) {
min = this.GJList.smp_a[ind]
}
if (this.GJList.smp_b[ind] > max) {
max = this.GJList.smp_b[ind]
} else if (this.GJList.smp_b[ind] < min) {
min = this.GJList.smp_b[ind]
}
if (this.GJList.smp_c[ind] > max) {
max = this.GJList.smp_c[ind]
} else if (this.GJList.smp_c[ind] < min) {
min = this.GJList.smp_c[ind]
}
adata.push([item, this.GJList.smp_a[ind]])
bdata.push([item, this.GJList.smp_b[ind]])
cdata.push([item, this.GJList.smp_c[ind]])
})
//绘制瞬时波形图
// const echarts = require('echarts')
let wave = document.getElementById('wave')
let _this = this
var myChartes = echarts.init(wave)
let echartsColor = {
WordColor: '#000',
thread: '#000000',
FigureColor: [
'#07CCCA ',
'#00BFF5',
'#FFBF00',
'#77DA63',
'#D5FF6B',
'#Ff6600',
'#FF9100',
'#5B6E96',
'#66FFCC',
'#B3B3B3',
'#FF00FF',
'#CC00FF',
'#FF9999'
]
}
var option = {
tooltip: {
top: '10px',
trigger: 'axis',
borderColor: 'grey',
backgroundColor: '#fff',
style: {
color: '#000',
fontSize: '15px',
padding: 10
},
formatter: function (params) {
// console.log(params)
var tips = ''
tips += '时刻:' + params[0].data[0] + '</br/>'
for (var i = 0; i < params.length; i++) {
if (params[i].seriesName != '暂降触发点') {
tips += params[i].seriesName + ':' + params[i].value[1] + '<br/>'
}
}
return tips
},
// axisPointer: {
// type: "cross",
// label: {
// color: "#fff",
// fontSize: 16,
// },
// },
textStyle: {
color: '#fff',
fontStyle: 'normal',
opacity: 0.35,
fontSize: 14
},
backgroundColor: 'rgba(0,0,0,0.55)',
borderWidth: 0
},
title: {
left: 'center',
text: '发生时刻:' + this.boxoList.startTime + ' PT变化:' + this.boxoList.measurementPointName,
textStyle: {
fontSize: 16,
color: _this.DColor ? '#fff' : echartsColor.WordColor
}
},
legend: {
left: '5%',
top: '20',
verticalAlign: 'top',
enabled: true,
itemDistance: 5,
textStyle: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
rich: {
a: {
verticalAlign: 'middle'
}
},
padding: [2, 0, 0, 0] //[上、右、下、左]
}
},
toolbox: {
show: false,
feature: {
//restore: {},
saveAsImage: {
iconStyle: {
borderColor: _this.DColor ? '#fff' : echartsColor.WordColor
}
}
}
},
xAxis: {
type: 'value',
name: '时刻',
boundaryGap: false,
min: this.GJList.smp_x[0],
max: this.GJList.smp_x[this.GJList.smp_x.length - 1] + 1,
title: {
text: 'ms',
textStyle: {
fontSize: 12,
color: _this.DColor ? '#fff' : echartsColor.WordColor
},
enabled: true,
align: 'high'
},
splitLine: {
show: false
},
axisTick: {
alignWithLabel: true
},
axisLine: {
lineStyle: {
color: _this.DColor ? '#fff' : echartsColor.thread
},
onZero: false //-----------重点
},
axisLabel: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
formatter: function (value, index) {
if (_this.valA != (value - 0).toFixed(0)) {
_this.valA = (value - 0).toFixed(0)
return (value - 0).toFixed(0)
}
}
//rotate:39
}
// data: this.syncExtremes,
},
yAxis: {
type: 'value',
name: 'kV',
title: {
align: 'high',
offset: 0,
text: 'kV',
rotation: 0,
y: -10
},
boundaryGap: [0, '100%'],
showLastLabel: true,
max: (max + 10).toFixed(2),
min: (min - 10).toFixed(2),
opposite: false,
nameTextStyle: {
color: _this.DColor ? '#fff' : echartsColor.WordColor
},
//minInterval: 1,
type: 'value',
axisLine: {
show: true,
lineStyle: {
color: _this.DColor ? '#fff' : echartsColor.thread
},
onZero: false //-----------重点
},
axisLabel: {
color: _this.DColor ? '#fff' : echartsColor.WordColor,
formatter: function (value, index) {
return (value - 0).toFixed(2)
}
},
splitLine: {
lineStyle: {
// 使用深浅的间隔色
color: [_this.DColor ? '#fff' : echartsColor.thread],
type: 'dashed',
opacity: 0.5
}
}
},
grid: {
left: '1%',
right: '40px',
bottom: '40px',
top: '55px',
containLabel: true
},
dataZoom: [
{
type: 'inside',
height: 13,
start: 0,
bottom: '20px',
end: 100
},
{
start: 0,
height: 13,
bottom: '20px',
end: 100
}
],
series: [
{
name: 'A相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#DAA520'
},
data: adata
},
{
name: 'B相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#2E8B57'
},
data: bdata
},
{
name: 'C相',
type: 'line',
smooth: true,
symbol: 'none',
sampling: 'lttb',
itemStyle: {
color: '#A52a2a'
},
data: cdata
},
{
name: '暂降触发点',
type: 'scatter',
symbol: 'image://' + url,
itemStyle: {
width: 16,
height: 16
},
data: [[0, min]]
}
]
}
myChartes.setOption(option)
// window.echartsArr.push(myChartes)
setTimeout(() => {
myChartes.resize()
this.loading = false
}, 400)
//第一个波形图数据绘制完毕后,绘制后续的波形图
// let waveDatasTemp = waveDatas.slice(1);
// waveDatasTemp.reverse();
}
}
}
</script>

View File

@@ -25,7 +25,7 @@
{{ Math.floor(row.eventValue * 10000) / 100 }}
</template>
</vxe-column>
<vxe-column field="eventType" width="100px" title="暂降类型">
<vxe-column field="eventType" width="100px" title="触发类型">
<template #default="{ row }">
{{ event.filter(item => item.id == row.eventType)[0]?.name || '/' }}
</template>
@@ -79,7 +79,7 @@ const init = async () => {
// 设置消息接收回调
mqttClient.onMessage((topic, message) => {
const msg = JSON.parse(message.toString())
// console.log('🚀 ~ init ~ msg:', msg)
console.log('🚀 ~ init ~ msg:', msg)
if (msg.deptList.includes(adminInfo.$state.deptId)) {
drawer.value = true
isLoading.value = true

View File

@@ -1,49 +1,49 @@
import { createRouter, createWebHashHistory } from 'vue-router'
import staticRoutes from '@/router/static'
import { useAdminInfo } from '@/stores/adminInfo'
import NProgress from 'nprogress'
import { loading } from '@/utils/loading'
import { ElMessage } from 'element-plus'
const router = createRouter({
history: createWebHashHistory(),
routes: staticRoutes
})
router.beforeEach((to, from, next) => {
NProgress.configure({ showSpinner: false })
NProgress.start()
if (!window.existLoading) {
loading.show()
window.existLoading = true
}
if (to.path == '/login' || to.path == '/404') {
// 登录或者注册才可以往下进行
next()
} else if (to.path == '/admin/center/homePage') {
window.open(window.location.origin + '/homePage/#/')
} else {
// 获取 token
const adminInfo = useAdminInfo()
const token = adminInfo.getToken()
// token 不存在
if (token === null || token === '') {
ElMessage.error('您还没有登录,请先登录')
next('/login')
} else {
next()
}
}
// next()
})
// 路由加载后
router.afterEach(() => {
if (window.existLoading) {
loading.hide()
}
NProgress.done()
})
export default router
import { createRouter, createWebHashHistory } from 'vue-router'
import staticRoutes from '@/router/static'
import { useAdminInfo } from '@/stores/adminInfo'
import NProgress from 'nprogress'
import { loading } from '@/utils/loading'
import { ElMessage } from 'element-plus'
const router = createRouter({
history: createWebHashHistory(),
routes: staticRoutes
})
router.beforeEach((to, from, next) => {
NProgress.configure({ showSpinner: false })
NProgress.start()
if (!window.existLoading) {
loading.show()
window.existLoading = true
}
if (to.path == '/login' || to.path == '/404') {
// 登录或者注册才可以往下进行
next()
} else if (to.path == '/admin/center/homePage') {
window.open(window.location.origin + '/homePage/#/')
} else {
// 获取 token
const adminInfo = useAdminInfo()
const token = adminInfo.getToken()
// token 不存在
if (token === null || token === '') {
// ElMessage.error('您还没有登录,请先登录')
next('/login')
} else {
next()
}
}
// next()
})
// 路由加载后
router.afterEach(() => {
if (window.existLoading) {
loading.hide()
}
NProgress.done()
})
export default router

View File

@@ -83,7 +83,7 @@
v-else
class="box-item"
title="确定重启吗?"
placement="bottom"
placement="left"
@confirm="restart(data)"
>
<template #actions="{ confirm, cancel }">

View File

@@ -131,7 +131,7 @@ const tableStore = new TableStore({
{ field: 'scale', title: '电压等级', minWidth: '110' },
// {
// field: 'advanceType',
// title: '暂降类型',
// title: '触发类型',
// minWidth: '90',
// formatter: (row: any) => {
// return row.cellValue || '其他'
@@ -147,7 +147,7 @@ const tableStore = new TableStore({
},
{
field: 'eventType',
title: '暂态统计类型',
title: '触发类型',
minWidth: '120',
formatter: (row: any) => {
return eventList.filter(item => item.id === row.cellValue)[0]?.name

View File

@@ -109,9 +109,10 @@ const handleNodeClick = (data: any, node: any) => {
}
// 上传
const choose = (files: any) => {
const isJPG = files.raw.type === 'image/jpeg'
const isJPG = files.raw.type === 'image/jpg'
const isJPEG = files.raw.type === 'image/jpeg'
const isPNG = files.raw.type === 'image/png'
if (!isJPG && !isPNG) {
if (!isJPG && !isPNG && !isJPEG) {
ElMessage.warning('上传文件只能是 jpg/png 格式!')
return false
}

View File

@@ -1,153 +1,153 @@
<!-- 暂态 -->
<template>
<el-dialog draggable title="暂态电能质量水平评估统计" v-model="dialogVisible" width="1400px">
<div>
<vxe-table v-bind="defaultAttribute" ref="vxeRef" height="360px" :data="tableData">
<vxe-column field="name" title="区域" />
<vxe-column sortable field="sagTimes" title="暂降次数" />
<vxe-column sortable field="swellTimes" title="暂升次数" />
<vxe-column sortable field="interruptTimes" title="短时中断次数" />
<vxe-colgroup title="暂态严重度占比">
<vxe-column sortable field="rate90" title="SARFI-90" />
<vxe-column sortable field="rate50" title="SARFI-50" />
<vxe-column sortable field="rate20" title="SARFI-20" />
</vxe-colgroup>
</vxe-table>
</div>
<div style="margin-top: 10px; display: flex">
<!--
-->
<div class="statistics-main">
<div class="statistics-box">
<MyEChart style="height: 250px" :options="picEChart" />
<el-table size="small" height="250px" :data="descentData">
<el-table-column prop="name" label="暂降原因" width="80px" align="center" />
<el-table-column prop="value" label="暂降次数" width="80px" align="center" />
</el-table>
</div>
<div class="statistics-box">
<MyEChart style="height: 250px" :options="picEChart1" />
<el-table size="small" height="250px" :data="resembleData">
<el-table-column prop="name" label="暂降类型" width="80px" align="center" />
<el-table-column prop="value" label="暂降次数" width="80px" align="center" />
</el-table>
</div>
</div>
</div>
</el-dialog>
</template>
<script setup lang="ts">
import { ref } from 'vue'
import MyEChart from '@/components/echarts/MyEchart.vue'
import { defaultAttribute } from '@/components/table/defaultAttribute'
import { getEventReason, getEventDetailByList } from '@/api/device-boot/panorama'
const dialogVisible: any = ref(false)
const tableData: any = ref([])
const descentData = ref([])
const resembleData = ref([])
const picEChart = ref({})
const picEChart1 = ref({})
const open = async (row: any) => {
getEventDetailByList({ ...row, deviceInfoParam: row }).then((res: any) => {
tableData.value = res.data
})
getEventReason(row).then(res => {
descentData.value = res.data.reason
resembleData.value = res.data.type
picEChart.value = {
tooltip: {
trigger: 'item'
},
legend: {
orient: 'vertical',
left: '10px'
},
xAxis: {
show: false
},
yAxis: {
show: false
},
options: {
dataZoom: null,
series: [
{
type: 'pie',
center: ['60%', '50%'],
radius: '50%',
label: {
show: false,
position: 'outside',
textStyle: {
//数值样式
}
},
data: res.data.reason
}
]
}
}
picEChart1.value = {
tooltip: {
trigger: 'item'
},
legend: {
orient: 'vertical',
left: '10px'
},
xAxis: {
show: false
},
yAxis: {
show: false
},
options: {
dataZoom: null,
series: [
{
type: 'pie',
center: ['60%', '50%'],
radius: '50%',
label: {
show: false,
position: 'outside',
textStyle: {
//数值样式
}
},
data: res.data.type
}
]
}
}
})
dialogVisible.value = true
}
defineExpose({ open })
</script>
<style lang="scss" scoped>
.statistics-main {
// height: 300px;
display: grid;
width: 100%;
grid-template-columns: 1fr 1fr;
.statistics-box {
// height: 300px;
// display: flex;
display: grid;
grid-template-columns: 2fr 1fr;
}
}
:deep(.el-dialog__body) {
max-height: none !important;
}
</style>
<!-- 暂态 -->
<template>
<el-dialog draggable title="暂态电能质量水平评估统计" v-model="dialogVisible" width="1400px">
<div>
<vxe-table v-bind="defaultAttribute" ref="vxeRef" height="360px" :data="tableData">
<vxe-column field="name" title="区域" />
<vxe-column sortable field="sagTimes" title="暂降次数" />
<vxe-column sortable field="swellTimes" title="暂升次数" />
<vxe-column sortable field="interruptTimes" title="短时中断次数" />
<vxe-colgroup title="暂态严重度占比">
<vxe-column sortable field="rate90" title="SARFI-90" />
<vxe-column sortable field="rate50" title="SARFI-50" />
<vxe-column sortable field="rate20" title="SARFI-20" />
</vxe-colgroup>
</vxe-table>
</div>
<div style="margin-top: 10px; display: flex">
<!--
-->
<div class="statistics-main">
<div class="statistics-box">
<MyEChart style="height: 250px" :options="picEChart" />
<el-table size="small" height="250px" :data="descentData">
<el-table-column prop="name" label="暂降原因" width="80px" align="center" />
<el-table-column prop="value" label="暂降次数" width="80px" align="center" />
</el-table>
</div>
<div class="statistics-box">
<MyEChart style="height: 250px" :options="picEChart1" />
<el-table size="small" height="250px" :data="resembleData">
<el-table-column prop="name" label="触发类型" width="80px" align="center" />
<el-table-column prop="value" label="暂降次数" width="80px" align="center" />
</el-table>
</div>
</div>
</div>
</el-dialog>
</template>
<script setup lang="ts">
import { ref } from 'vue'
import MyEChart from '@/components/echarts/MyEchart.vue'
import { defaultAttribute } from '@/components/table/defaultAttribute'
import { getEventReason, getEventDetailByList } from '@/api/device-boot/panorama'
const dialogVisible: any = ref(false)
const tableData: any = ref([])
const descentData = ref([])
const resembleData = ref([])
const picEChart = ref({})
const picEChart1 = ref({})
const open = async (row: any) => {
getEventDetailByList({ ...row, deviceInfoParam: row }).then((res: any) => {
tableData.value = res.data
})
getEventReason(row).then(res => {
descentData.value = res.data.reason
resembleData.value = res.data.type
picEChart.value = {
tooltip: {
trigger: 'item'
},
legend: {
orient: 'vertical',
left: '10px'
},
xAxis: {
show: false
},
yAxis: {
show: false
},
options: {
dataZoom: null,
series: [
{
type: 'pie',
center: ['60%', '50%'],
radius: '50%',
label: {
show: false,
position: 'outside',
textStyle: {
//数值样式
}
},
data: res.data.reason
}
]
}
}
picEChart1.value = {
tooltip: {
trigger: 'item'
},
legend: {
orient: 'vertical',
left: '10px'
},
xAxis: {
show: false
},
yAxis: {
show: false
},
options: {
dataZoom: null,
series: [
{
type: 'pie',
center: ['60%', '50%'],
radius: '50%',
label: {
show: false,
position: 'outside',
textStyle: {
//数值样式
}
},
data: res.data.type
}
]
}
}
})
dialogVisible.value = true
}
defineExpose({ open })
</script>
<style lang="scss" scoped>
.statistics-main {
// height: 300px;
display: grid;
width: 100%;
grid-template-columns: 1fr 1fr;
.statistics-box {
// height: 300px;
// display: flex;
display: grid;
grid-template-columns: 2fr 1fr;
}
}
:deep(.el-dialog__body) {
max-height: none !important;
}
</style>

View File

@@ -53,7 +53,7 @@
<div class="statistics-box">
<MyEChart style="height: 250px" :options="picEChart1" />
<el-table size="small" height="250px" :data="resembleData">
<el-table-column prop="name" label="暂降类型" width="80px" align="center" />
<el-table-column prop="name" label="触发类型" width="80px" align="center" />
<el-table-column prop="value" label="暂降次数" width="80px" align="center" />
</el-table>
</div>

View File

@@ -1,144 +1,144 @@
<template>
<span style="color: red; font-size: 12px">:暂降类型仅统计暂降原因为短路故障事件</span>
<div class="statistics-main">
<template v-if="flag">
<div>
<my-echart :options="descent" />
</div>
<div>
<vxe-table height="auto" auto-resize :data="descentData" v-bind="defaultAttribute">
<vxe-column field="name" title="暂降原因"></vxe-column>
<vxe-column field="value" title="暂降次数"></vxe-column>
</vxe-table>
</div>
<div>
<my-echart :options="resemble" />
</div>
<div>
<vxe-table height="auto" auto-resize :data="resembleData" v-bind="defaultAttribute">
<vxe-column field="name" title="暂降类型"></vxe-column>
<vxe-column field="value" title="暂降次数"></vxe-column>
</vxe-table>
</div>
</template>
</div>
</template>
<script setup lang="ts">
import { ref, reactive } from 'vue'
import MyEchart from '@/components/echarts/MyEchart.vue'
import { defaultAttribute } from '@/components/table/defaultAttribute'
import { mainHeight } from '@/utils/layout'
const descent = ref({})
const descentData = ref([])
const resemble = ref({})
const resembleData = ref([])
const flag = ref(true)
const info = (res: any) => {
flag.value = false
descentData.value = res.reason
resembleData.value = res.type
descent.value = {
title: {
text: '暂降原因'
},
legend: {
type: 'scroll',
orient: 'vertical',
top:null,
left: 25,
bottom: 40,
},
xAxis: {
show: false
},
yAxis: {
show: false
},
dataZoom: { show: false },
tooltip: {
trigger: 'item',
formatter: '{a} <br/>{b} : {c} (次)'
},
options: {
series: [
{
name: '暂降原因',
type: 'pie',
center: ['50%', '50%'],
selectedOffset: 30,
clockwise: true,
label: {
show: false,
position: 'outside',
textStyle: {
//数值样式
}
},
data: res.reason?.filter((item: any) => item.name != '总计')
}
]
}
}
resemble.value = {
title: {
text: '暂降类型'
},
legend: {
type: 'scroll',
orient: 'vertical',
top:null,
left: 25,
bottom: 40,
},
tooltip: {
trigger: 'item',
formatter: '{a} <br/>{b} : {c} (次)',
},
xAxis: {
show: false
},
yAxis: {
show: false
},
dataZoom: { show: false },
options: {
series: [
{
name: '暂降类型',
type: 'pie',
center: ['50%', '50%'],
selectedOffset: 30,
clockwise: true,
label: {
show: false,
position: 'outside'
},
data: res.type?.filter((item: any) => item.name != '总计')
}
]
}
}
flag.value = true
}
defineExpose({ info })
const layout = mainHeight(175) as any
</script>
<style lang="scss" scoped>
.statistics-main {
box-sizing: border-box;
height: v-bind('layout.height');
padding: 0 10px 10px;
display: grid;
grid-template-columns: 1fr 600px;
grid-template-rows: 1fr 1fr;
grid-gap: 10px;
}
</style>
<template>
<span style="color: red; font-size: 12px">:触发类型仅统计暂降原因为短路故障事件</span>
<div class="statistics-main">
<template v-if="flag">
<div>
<my-echart :options="descent" />
</div>
<div>
<vxe-table height="auto" auto-resize :data="descentData" v-bind="defaultAttribute">
<vxe-column field="name" title="暂降原因"></vxe-column>
<vxe-column field="value" title="暂降次数"></vxe-column>
</vxe-table>
</div>
<div>
<my-echart :options="resemble" />
</div>
<div>
<vxe-table height="auto" auto-resize :data="resembleData" v-bind="defaultAttribute">
<vxe-column field="name" title="触发类型"></vxe-column>
<vxe-column field="value" title="暂降次数"></vxe-column>
</vxe-table>
</div>
</template>
</div>
</template>
<script setup lang="ts">
import { ref, reactive } from 'vue'
import MyEchart from '@/components/echarts/MyEchart.vue'
import { defaultAttribute } from '@/components/table/defaultAttribute'
import { mainHeight } from '@/utils/layout'
const descent = ref({})
const descentData = ref([])
const resemble = ref({})
const resembleData = ref([])
const flag = ref(true)
const info = (res: any) => {
flag.value = false
descentData.value = res.reason
resembleData.value = res.type
descent.value = {
title: {
text: '暂降原因'
},
legend: {
type: 'scroll',
orient: 'vertical',
top:null,
left: 25,
bottom: 40,
},
xAxis: {
show: false
},
yAxis: {
show: false
},
dataZoom: { show: false },
tooltip: {
trigger: 'item',
formatter: '{a} <br/>{b} : {c} (次)'
},
options: {
series: [
{
name: '暂降原因',
type: 'pie',
center: ['50%', '50%'],
selectedOffset: 30,
clockwise: true,
label: {
show: false,
position: 'outside',
textStyle: {
//数值样式
}
},
data: res.reason?.filter((item: any) => item.name != '总计')
}
]
}
}
resemble.value = {
title: {
text: '触发类型'
},
legend: {
type: 'scroll',
orient: 'vertical',
top:null,
left: 25,
bottom: 40,
},
tooltip: {
trigger: 'item',
formatter: '{a} <br/>{b} : {c} (次)',
},
xAxis: {
show: false
},
yAxis: {
show: false
},
dataZoom: { show: false },
options: {
series: [
{
name: '触发类型',
type: 'pie',
center: ['50%', '50%'],
selectedOffset: 30,
clockwise: true,
label: {
show: false,
position: 'outside'
},
data: res.type?.filter((item: any) => item.name != '总计')
}
]
}
}
flag.value = true
}
defineExpose({ info })
const layout = mainHeight(175) as any
</script>
<style lang="scss" scoped>
.statistics-main {
box-sizing: border-box;
height: v-bind('layout.height');
padding: 0 10px 10px;
display: grid;
grid-template-columns: 1fr 600px;
grid-template-rows: 1fr 1fr;
grid-gap: 10px;
}
</style>

View File

@@ -85,8 +85,8 @@
></el-input>
</el-form-item>
<!-- <el-form-item label="暂降类型:">
<el-select v-model="tableStore.table.params.eventType" placeholder="请选择暂降类型" clearable multiple
<!-- <el-form-item label="触发类型:">
<el-select v-model="tableStore.table.params.eventType" placeholder="请选择触发类型" clearable multiple
collapse-tags style="width: 100%">
<el-option v-for="item in typeoptions" :key="item.id" :label="item.name"
:value="item.id"></el-option>
@@ -251,7 +251,7 @@ const tableStore = new TableStore({
return triggeroptions.filter(item => item.id == row.eventType)[0]?.name
}
},
// { field: 'advanceType', title: '暂降类型', minWidth: '100', },
// { field: 'advanceType', title: '触发类型', minWidth: '100', },
{ field: 'advanceReason', title: '暂态原因', minWidth: '100' },
{
field: 'depth',

View File

@@ -56,7 +56,7 @@
<vxe-table-column field="duration" title="持续时间(s)" align="center" width="120"></vxe-table-column>
<vxe-table-column
field="advanceType"
title="暂降类型"
title="触发类型"
align="center"
width="120"
:formatter="formFilter"

View File

@@ -39,7 +39,7 @@
</template>
</vxe-table-column>
<vxe-table-column field="duration" title="持续时间(s)" align="center" width="120"></vxe-table-column>
<vxe-table-column field="advanceType" title="暂降类型" align="center" width="120"
<vxe-table-column field="advanceType" title="触发类型" align="center" width="120"
:formatter="formFilter"></vxe-table-column>
<vxe-table-column field="advanceReason" title="暂降原因" align="center" width="120"
:formatter="formFilter"></vxe-table-column>

View File

@@ -249,7 +249,7 @@ const initThird = () => {
backgroundColor: '#fff', //背景色,
animation: false,
title: {
text: '暂降类型',
text: '触发类型',
x: 'center'
},
@@ -277,7 +277,7 @@ const initThird = () => {
},
series: [
{
name: '暂降类型',
name: '触发类型',
type: 'pie',
radius: '65%',
center: ['50%', '60%'],

View File

@@ -61,7 +61,7 @@ const tableStore = new TableStore({
{ title: '网络参数', field: 'ip', width: '120px' },
{ title: '电压等级(kV)', field: 'voltageScale', width: '120' },
{ title: '暂降发生时刻', field: 'startTime', width: '200' },
// { title: '暂降类型', field: 'advanceType', minWidth: '130' },
// { title: '触发类型', field: 'advanceType', minWidth: '130' },
{ title: '暂降原因', field: 'advanceReason', minWidth: '130' },
{
title: '触发类型',

View File

@@ -109,7 +109,7 @@
<el-row>
<el-col :span="12" class="mTop">
<div class="grid-content">
<div class="divBox">暂降类型</div>
<div class="divBox">触发类型</div>
</div>
</el-col>
<el-col :span="12" class="mTop">

View File

@@ -10,7 +10,7 @@
placeholder="请输入监测点名称"
/>
</el-form-item>
<el-form-item label="暂降类型">
<el-form-item label="触发类型">
<el-select v-model.trim="tableStore.table.params.dicData" placeholder="请选择" clearable>
<el-option
v-for="item in triggerType"
@@ -79,7 +79,7 @@ const tableStore: any = new TableStore({
{ field: 'objName', title: '监测对象', minWidth: '170' },
// {
// field: 'advanceType',
// title: '暂降类型',
// title: '触发类型',
// minWidth: '90',
// formatter: (row: any) => {
// return row.cellValue || '其他'
@@ -95,7 +95,7 @@ const tableStore: any = new TableStore({
},
{
field: 'eventType',
title: '暂态统计类型',
title: '触发类型',
minWidth: '120',
formatter: (row: any) => {
return triggerType.filter(item => item.id === row.cellValue)[0]?.name

View File

@@ -1,45 +1,45 @@
<template>
<el-dialog draggable width="1100px" v-model="dialogVisible" title="暂降事件列表">
<div style="height: 40vh">
<vxe-table v-loading="loading" height="auto" auto-resize :data="tableData" v-bind="defaultAttribute">
<vxe-column type="seq" title="序号" width="80px"></vxe-column>
<vxe-column field="startTime" title="发生时间" width="180"></vxe-column>
<vxe-column field="duration" title="持续时间(s)" width="100"></vxe-column>
<vxe-column field="gdName" title="供电公司" min-width="150"></vxe-column>
<vxe-column field="subName" title="变电站" min-width="150"></vxe-column>
<vxe-column field="lineName" title="监测点" min-width="150"></vxe-column>
<vxe-column field="advanceType" title="暂降类型" width="100">
<template #default="{ row }">
{{ type.find(item => item.id === row.advanceType)?.name }}
</template>
</vxe-column>
<vxe-column field="featureAmplitude" title="暂降(骤升)幅值(%)" width="150">
<template #default="{ row }">
{{ (row.featureAmplitude * 100).toFixed(2) }}
</template>
</vxe-column>
</vxe-table>
</div>
</el-dialog>
</template>
<script lang="ts" setup>
import { ref, inject } from 'vue'
import { defaultAttribute } from '@/components/table/defaultAttribute'
import { getNoDealEventsByLineId } from '@/api/event-boot/areaInfo'
import { useDictData } from '@/stores/dictData'
const dictData = useDictData()
const type = dictData.getBasicData('Event_Type')
const dialogVisible = ref(false)
const tableData = ref([])
const loading = ref(true)
const open = (params: any) => {
dialogVisible.value = true
loading.value = true
getNoDealEventsByLineId(params).then(res => {
tableData.value = res.data
loading.value = false
})
}
defineExpose({ open })
</script>
<template>
<el-dialog draggable width="1100px" v-model="dialogVisible" title="暂降事件列表">
<div style="height: 40vh">
<vxe-table v-loading="loading" height="auto" auto-resize :data="tableData" v-bind="defaultAttribute">
<vxe-column type="seq" title="序号" width="80px"></vxe-column>
<vxe-column field="startTime" title="发生时间" width="180"></vxe-column>
<vxe-column field="duration" title="持续时间(s)" width="100"></vxe-column>
<vxe-column field="gdName" title="供电公司" min-width="150"></vxe-column>
<vxe-column field="subName" title="变电站" min-width="150"></vxe-column>
<vxe-column field="lineName" title="监测点" min-width="150"></vxe-column>
<vxe-column field="advanceType" title="触发类型" width="100">
<template #default="{ row }">
{{ type.find(item => item.id === row.advanceType)?.name }}
</template>
</vxe-column>
<vxe-column field="featureAmplitude" title="暂降(骤升)幅值(%)" width="150">
<template #default="{ row }">
{{ (row.featureAmplitude * 100).toFixed(2) }}
</template>
</vxe-column>
</vxe-table>
</div>
</el-dialog>
</template>
<script lang="ts" setup>
import { ref, inject } from 'vue'
import { defaultAttribute } from '@/components/table/defaultAttribute'
import { getNoDealEventsByLineId } from '@/api/event-boot/areaInfo'
import { useDictData } from '@/stores/dictData'
const dictData = useDictData()
const type = dictData.getBasicData('Event_Type')
const dialogVisible = ref(false)
const tableData = ref([])
const loading = ref(true)
const open = (params: any) => {
dialogVisible.value = true
loading.value = true
getNoDealEventsByLineId(params).then(res => {
tableData.value = res.data
loading.value = false
})
}
defineExpose({ open })
</script>

View File

@@ -117,7 +117,7 @@
<el-row>
<el-col :span="12" class="mTop">
<div class="grid-content">
<div class="divBox">暂降类型</div>
<div class="divBox">触发类型</div>
</div>
</el-col>
<el-col :span="12" class="mTop">

View File

@@ -122,7 +122,7 @@
<el-row>
<el-col :span="12">
<div class="grid-content">
<div class="divBox">暂降类型</div>
<div class="divBox">触发类型</div>
</div>
</el-col>
<el-col :span="12">

View File

@@ -107,7 +107,7 @@ const list = ref([
}
},
{ field: 'duration', title: '持续时间(s)', width: '120' },
{ field: 'advanceType', title: '暂降类型(机器判断)', width: '150' }
{ field: 'advanceType', title: '触发类型(机器判断)', width: '150' }
]
},
{