diff --git a/src/components/cockpit/F47Curve/index.vue b/src/components/cockpit/F47Curve/index.vue
index e2e2818..4323007 100644
--- a/src/components/cockpit/F47Curve/index.vue
+++ b/src/components/cockpit/F47Curve/index.vue
@@ -409,7 +409,7 @@ onMounted(() => {
})
// 点击事件处理函数
-const handleChartClick = (params: any) => {
+const handleChartClick = (params: any, e: any) => {
if (params.seriesName === '可容忍事件') {
// 处理可容忍事件点击
dialogTitle.value = '可容忍事件波形分析'
diff --git a/src/components/cockpit/transientDetails/components/transientList.vue b/src/components/cockpit/transientDetails/components/transientList.vue
index 3e1b9fd..c88768a 100644
--- a/src/components/cockpit/transientDetails/components/transientList.vue
+++ b/src/components/cockpit/transientDetails/components/transientList.vue
@@ -1,15 +1,11 @@
-
-
-
+
+
-
-
+
+
- -->
-
+
+
+
+
+
+
@@ -30,21 +43,37 @@ import Table from '@/components/table/index.vue'
import TableHeader from '@/components/table/header/index.vue'
import TableStore from '@/utils/tableStore'
import { mainHeight } from '@/utils/layout'
+import waveFormAnalysis from '@/views/govern/device/control/tabs/components/waveFormAnalysis.vue'
+import { analyseWave } from '@/api/common'
+import { getSimpleLine } from '@/api/harmonic-boot/cockpit/cockpit'
+
const dialogVisible: any = ref(false)
-const harmonicRatioRef: any = ref(null)
-const options = [
- {
- value: '35kV进线',
- label: '35kV进线'
- }
-]
-const height = mainHeight(0, 2).height as any
+const waveFormAnalysisRef: any = ref(null)
+// 波形
+const isWaveCharts = ref(false)
+const loading = ref(false)
+const wp = ref({})
+const boxoList: any = ref({})
+
+const tableHeaderRef = ref()
+
+const options = ref()
+const heightRef = ref(mainHeight(168, 2.1).height)
+const selectChange = (flag: boolean, h: any) => {
+ heightRef.value = mainHeight(h, 2.1).height
+}
+
+const getSimpleLineList = async () => {
+ const res = await getSimpleLine()
+ options.value = res.data
+}
+
+
const tableStore: any = new TableStore({
- url: '/user-boot/role/selectRoleDetail?id=0',
+ url: '/cs-harmonic-boot/event/pageEvent',
method: 'POST',
- publicHeight: 30,
- showPage: false,
- exportName: '主要监测点列表',
+ showPage: true,
+ exportName: '暂态事件详情',
column: [
{
field: 'index',
@@ -56,76 +85,142 @@ const tableStore: any = new TableStore({
},
{
title: '暂态时间',
- field: 'time',
+ field: 'startTime',
+ minWidth: '150'
},
{
title: '测点名称',
- field: 'name',
+ field: 'lineName',
width: '150'
},
{
title: '暂态类型',
- field: 'flicker',
- width: '100',
+ field: 'tag',
+ width: '100'
},
{
title: '特征幅值(%)',
- field: 'flicker',
+ field: 'amplitude',
width: '100'
},
{
title: '暂降深度(%)',
- field: 'flicker',
- width: '100'
+ field: 'depth',
+ width: '100',
+ formatter: (row: any) => {
+ // 当暂态类型不是电压暂升时,计算暂降深度 = 100 - 特征幅值
+ if (row.tag !== '电压暂升') {
+ const amplitude = parseFloat(row.row.amplitude)
+ if (!isNaN(amplitude)) {
+ return 100 - amplitude
+ }
+ return '-'
+ } else {
+ // 电压暂升时不显示暂降深度
+ return '/'
+ }
+ }
},
{
title: '持续时间(S)',
- field: 'flicker',
+ field: 'persistTime',
width: '100'
},
- {
+ {
title: '严重度',
- field: 'flicker',
+ field: 'severity',
width: '80'
},
+ {
+ title: '波形',
+ width: '100',
+ render: 'buttons',
+ buttons: [
+ {
+ name: 'edit',
+ text: '波形分析',
+ type: 'primary',
+ icon: 'el-icon-DataLine',
+ render: 'basicButton',
+ disabled: row => {
+ return !row.wavePath
+ },
+
+ click: async row => {
+ row.loading1 = true
+ loading.value = true
+ isWaveCharts.value = true
+ dialogVisible.value = false
+ // 在打开弹窗时立即设置高度
+ nextTick(() => {
+ if (waveFormAnalysisRef.value) {
+ // waveFormAnalysisRef.value.setHeight(false, 360)
+ waveFormAnalysisRef.value.setHeight(999, 130, 1.6666666)
+ }
+ })
+ await analyseWave(row.id)
+ .then(res => {
+ row.loading1 = false
+ if (res != undefined) {
+ boxoList.value = row
+ // boxoList.value = {
+ // ...row,
+ // duration: row.persistTime // 将 persistTime 值赋给 duration
+ // }
+ boxoList.value.featureAmplitude =
+ row.evtParamVVaDepth != '-' ? row.evtParamVVaDepth - 0 : null
+ boxoList.value.systemType = 'YPT'
+ wp.value = res.data
+ }
+ loading.value = false
+ })
+ .catch(() => {
+ row.loading1 = false
+ loading.value = false
+ })
+
+ nextTick(() => {
+ waveFormAnalysisRef.value &&
+ waveFormAnalysisRef.value.getWpData(wp.value, boxoList.value, true)
+ })
+ }
+ },
+ {
+ name: 'edit',
+ text: '暂无波形',
+ type: 'info',
+ icon: 'el-icon-DataLine',
+ render: 'basicButton',
+ disabled: row => {
+ return !(!row.wavePath && row.evtParamTm < 20)
+ }
+ }
+ ]
+ }
],
beforeSearchFun: () => {},
- loadCallback: () => {
- tableStore.table.data = [
- {
- time: '2024-01-01 00:00:00',
- name: '35kV进线',
- flicker: '0'
- },
- {
- time: '2024-01-01 00:00:00',
- name: '35kV进线',
- flicker: '0'
- },
- {
- time: '2024-01-01 00:00:00',
- name: '35kV进线',
- flicker: '0'
- }
- ]
- }
+ loadCallback: () => {}
})
-tableStore.table.params.searchValue = ''
provide('tableStore', tableStore)
-const open = async (row: any) => {
+const open = async (time: any) => {
dialogVisible.value = true
- tableStore.index()
+ getSimpleLineList()
+ tableStore.table.params.lineId = ''
+ nextTick(() => {
+ tableHeaderRef.value.setInterval(5)
+ tableHeaderRef.value.setTimeInterval([time, time])
+ tableStore.table.params.searchBeginTime = time
+ tableStore.table.params.searchEndTime = time
+ tableStore.index()
+ })
}
-// 点击行
-const cellClickEvent = ({ row, column }: any) => {
- if (column.field != 'name') {
- harmonicRatioRef.value.openDialog(row)
- }
+const handleHideCharts = () => {
+ isWaveCharts.value = false
+ dialogVisible.value = true
}
-
defineExpose({ open })
diff --git a/src/components/cockpit/transientDetails/index.vue b/src/components/cockpit/transientDetails/index.vue
index 0a08a33..618bd90 100644
--- a/src/components/cockpit/transientDetails/index.vue
+++ b/src/components/cockpit/transientDetails/index.vue
@@ -41,8 +41,9 @@
style="text-decoration: underline"
class="details"
v-for="item in list?.filter((item:any) => item.name == data.day)"
+ @click="descentClick(item)"
>
-
电压暂降:{{ item.eventDown || 0 }}
+ 电压暂降:{{ item.eventDown || 0 }}
电压中断:{{ item.eventOff || 0 }}
电压暂升:{{ item.eventUp || 0 }}
@@ -182,8 +183,8 @@ watch(
)
// 电压暂降点击事件
-const descentClick = () => {
- transientListRef.value.open()
+const descentClick = (item:any) => {
+ transientListRef.value.open(item.name)
}