修改治理测试用例

This commit is contained in:
GGJ
2025-01-06 21:01:49 +08:00
parent 439a129589
commit 51782b09c2
10 changed files with 166 additions and 68 deletions

View File

@@ -233,7 +233,7 @@ const search = () => {
}
},
xAxis: {
name: '时间',
name: '',
type: 'time',
axisLabel: {
formatter: {

View File

@@ -3,10 +3,20 @@
<div class="analyze-dvr" v-show="!isWaveCharts" :style="{ height: pageHeight.height }" v-loading="loading">
<DeviceTree @node-click="nodeClick" @init="nodeClick"></DeviceTree>
<div class="analyze-dvr-right" v-if="tableStore.table.params.deviceId">
<TableHeader :showReset="false" showExport>
<TableHeader datePicker showExport>
<template v-slot:select>
<el-form-item label="关键字">
<el-input v-model.trim="tableStore.table.params.searchValue" placeholder="请输入关键字" />
<el-form-item label="事件类型">
<el-select v-model.trim="tableStore.table.params.eventType" clearable placeholder="请选择事件类型">
<el-option v-for="item in eventList" :key="item.value" :label="item.label"
:value="item.value" />
</el-select>
</el-form-item>
<el-form-item label="位置">
<el-select v-model.trim="tableStore.table.params.location" clearable placeholder="请选择位置">
<el-option v-for="item in locationList" :key="item.value" :label="item.label"
:value="item.value" />
</el-select>
</el-form-item>
</template>
</TableHeader>
@@ -64,7 +74,7 @@ import TableHeader from '@/components/table/header/index.vue'
import { getFileZip } from '@/api/cs-harmonic-boot/datatrend'
import { ElMessage } from 'element-plus'
defineOptions({
name: 'govern/analyze/DVR'
name: 'analyze/DVR/index'
})
const pageHeight = mainHeight(20)
const loading = ref(false)
@@ -75,23 +85,33 @@ const isWaveCharts = ref(false)
const bxactiveName = ref('ssbx')
const boxoList: any = ref({})
const wp = ref({})
const value = ref(1)
const eventList = ref([{
value: 'Evt_Sys_DipStr',
label: '电压暂降'
},
{
value: 'Evt_Sys_IntrStr',
label: '电压暂升'
},
{
value: 'Evt_Sys_IntrStr',
label: '电压中断'
}])
const locationList = ref([{
value: 'grid',
label: '电网侧'
},
{
value: 'load',
label: '负载侧'
}])
const waveFormAnalysisRef = ref()
const options = ref([
{
value: 1,
label: '一次值'
},
{
value: 2,
label: '二次值'
}
])
const tableStore = new TableStore({
url: '/cs-harmonic-boot/eventUser/queryEventpageWeb',
method: 'POST',
column: [
{ title: '事件描述', field: 'showName', sortable: true },
{ title: '事件描述', field: 'showName', },
{ title: '发生位置', field: 'evtParamPosition' },
{ title: '持续时间(s)', field: 'evtParamTm' },
{ title: '暂降深度', field: 'evtParamVVaDepth' },
@@ -188,13 +208,17 @@ const tableStore = new TableStore({
}
})
tableStore.table.params.type = 0
tableStore.table.params.eventType=''
tableStore.table.params.location=''
provide('tableStore', tableStore)
const nodeClick = async (e: anyObj) => {
// console.log("🚀 ~ nodeClick ~ e:", e)
if (e.level == 2) {
loading.value = false
tableStore.table.params.deviceId = e.id
tableStore.index()
nextTick(() => {
tableStore.index()
})
}
}

View File

@@ -475,11 +475,10 @@ const tableStore = new TableStore({
icon: 'el-icon-Grid',
render: 'basicButton',
disabled: row => {
return (
row.devType == '8b45cf6b7f5266e777d07c166ad5fa77' &&
row.devModel == 'a0d4da4b5c17b2172362a3f5a27bf217'
return !(
row.devType == '2d4e186e2462590dedc765c5b6700a32'
)
},
},
click: row => {
deivce.value = row
deivce.value.qrPath = fullUrl(deivce.value.qrPath)

View File

@@ -20,9 +20,11 @@
<el-button icon="el-icon-Download" type="primary" @click="exportEvent">导出excel</el-button>
</template>
</TableHeader>
<div class="box">
<div id="luckysheet" v-loading="tableStore.table.loading"
:style="`height: calc(${tableStore.table.height} + 45px)`"></div>
<div class="box" v-loading="tableStore.table.loading">
<div id="luckysheet"
:style="`height: calc(${tableStore.table.height} + 45px)`"
v-if="tableStore.table.data.length > 0"></div>
<el-empty :style="`height: calc(${tableStore.table.height} + 45px)`" v-else description="暂无数据" />
</div>
</pane>
</splitpanes>
@@ -90,7 +92,6 @@ const flag = ref(true)
onMounted(() => {
const dom = document.getElementById('navigation-splitpanes')
if (dom) {
console.log("🚀 ~ onMounted ~ dom.offsetHeight:", dom.offsetWidth)
size.value = ((280 / (dom.offsetWidth - 7)) * 100)
}
@@ -114,11 +115,14 @@ const changetype = (val: any) => {
}
const handleNodeClick = (data: any, node: any) => {
if (data?.pid) {
dotList.value = data
setTimeout(() => {
tableStore.index()
}, 500)
} else {
tableStore.table.loading = false
}
}