修改测试bug

This commit is contained in:
GGJ
2024-12-23 11:30:28 +08:00
parent b10854971d
commit 90efcc4ad2
20 changed files with 209 additions and 54 deletions

View File

@@ -2,7 +2,7 @@
<div class="default-main device-control" :style="{ height: pageHeight.height }" v-loading="loading"
style="position: relative">
<!-- @init="nodeClick" -->
<PointTree @node-click="nodeClick" @pointTypeChange="pointTypeChange" style="width: 280px"></PointTree>
<PointTree @node-click="nodeClick" @pointTypeChange="pointTypeChange"></PointTree>
<div class="device-control-right" v-if="deviceData">
<el-descriptions title="监测点信息" class="mb10" width="180" :column="3" border>
<template #extra>
@@ -1253,7 +1253,7 @@ onBeforeUnmount(() => {
display: flex;
&-left {
width: 280px;
// width: 280px;
}
&-right {

View File

@@ -358,7 +358,7 @@ defineExpose({ open, setRealTrendData, setOverLimitData })
.select {
position: absolute;
top: -40px;
top: -36px;
display: flex;
align-items: center;
font-size: 14px;

View File

@@ -344,6 +344,7 @@ const init = async () => {
color: ['#FFCC00', '#009900', '#CC0000', ...color],
xAxis: {
type: 'time',
name:'时间',
axisLabel: {
formatter: {
day: '{MM}-{dd}',

View File

@@ -32,6 +32,7 @@ const key: any = ref(0)
const column: any = ref([
{ field: 'startTime', title: '数据起始时间', width: '140px', sortable: true },
{ field: 'endTime', title: '数据结束时间', width: '140px', sortable: true },
{ field: 'lastTime', title: '持续时间', width: '140px', sortable: true },
{ field: 'itemName', title: '数据来源', width: '100px' },
{ field: 'statisticalInterval', title: '时间间隔(分钟)', width: '120px', },
{ field: 'voltageLevel', title: '电压等级', width: '100px', sortable: true },
@@ -45,7 +46,7 @@ const column: any = ref([
{ field: 'capacitySscb', title: '基准短路容量(MVA)', width: '140px', },
{ field: 'capacitySscmin', title: '最小短路容量(MVA)', width: '140px', },
{ field: 'location', title: ' 测试位置', width: '100px', },
// { field: 'location', title: ' 测试位置', width: '100px', },

View File

@@ -34,7 +34,7 @@
<el-descriptions-item label="型号">
{{ echoName(deviceData.devModel, devModelOptions) }}
</el-descriptions-item>
<el-descriptions-item label="接入日期">
<el-descriptions-item label="首次接入日期">
{{ deviceData.time }}
</el-descriptions-item>
<el-descriptions-item label="应用程序版本号">

View File

@@ -1,7 +1,7 @@
<template>
<div>
<div :style="{ width: menuCollapse ? '40px' : '280px' }"
style="transition: all 0.3s; overflow: hidden; height: 100%">
style=" overflow: hidden; height: 100%">
<Icon v-show="menuCollapse" @click="onMenuCollapse" :name="menuCollapse ? 'el-icon-Expand' : 'el-icon-Fold'"
:class="menuCollapse ? 'unfold' : ''" size="18" class="fold ml10 mt20 menu-collapse"
style="cursor: pointer" />

View File

@@ -35,7 +35,7 @@ const tableStore = new TableStore({
method: 'POST',
paramsPOST: true,
showPage: false,
publicHeight: 365,
publicHeight: 355,
column: [
// { width: '60', type: 'checkbox', fixed: 'left' },
{
@@ -160,12 +160,12 @@ const tableStore = new TableStore({
})
const setHeight = () => {
if (props.activeColName == '0') {
waveFormAnalysisRef.value && waveFormAnalysisRef.value.setHeight(360, 495)
tableStore.table.height = mainHeight(385).height
waveFormAnalysisRef.value && waveFormAnalysisRef.value.setHeight(350, 485)
tableStore.table.height = mainHeight(380).height
} else {
waveFormAnalysisRef.value && waveFormAnalysisRef.value.setHeight(360, 360)
tableStore.table.height = mainHeight(250).height
waveFormAnalysisRef.value && waveFormAnalysisRef.value.setHeight(350, 350)
tableStore.table.height = mainHeight(240).height
}
}
provide('tableStore', tableStore)

View File

@@ -215,7 +215,7 @@ const voltageLevelList = dictData.getBasicData('Dev_Voltage_Stand')
const volConTypeList = dictData.getBasicData('Dev_Connect')
//值类型
const pageHeight = mainHeight(20)
const EcharHeight = ref(mainHeight(451))
const EcharHeight = ref(mainHeight(436))
const loading = ref(false)
const searchForm: any = ref({})
const typeOptions = [
@@ -955,15 +955,15 @@ const selectChange = (e: boolean) => {
if (activeColName.value == '0') {
if (flag.value) {
EcharHeight.value = mainHeight(495)
EcharHeight.value = mainHeight(480)
} else {
EcharHeight.value = mainHeight(451)
EcharHeight.value = mainHeight(436)
}
} else {
if (flag.value) {
EcharHeight.value = mainHeight(355)
EcharHeight.value = mainHeight(340)
} else {
EcharHeight.value = mainHeight(315)
EcharHeight.value = mainHeight(300)
}
}
}
@@ -972,15 +972,15 @@ const handleChange = () => {
if (activeColName.value == '0') {
if (flag.value) {
EcharHeight.value = mainHeight(495)
EcharHeight.value = mainHeight(480)
} else {
EcharHeight.value = mainHeight(451)
EcharHeight.value = mainHeight(436)
}
} else {
if (flag.value) {
EcharHeight.value = mainHeight(355)
EcharHeight.value = mainHeight(340)
} else {
EcharHeight.value = mainHeight(315)
EcharHeight.value = mainHeight(300)
}
}
setTimeout(() => {
@@ -1051,8 +1051,8 @@ onMounted(() => {
overflow: hidden;
flex: 1 !important;
height: calc(100vh - 135px);
padding: 10px 10px 10px 10px;
border: 2px solid #eeeeee;
// padding: 10px 10px 10px 10px;
// border: 2px solid #eeeeee;
display: flex;
flex-direction: column;

View File

@@ -38,7 +38,7 @@
:show-file-list="false" :auto-upload="false" :on-change="bulkImport">
<el-button type="primary" class="ml10" icon="el-icon-Tickets">批量导入</el-button>
</el-upload>
<el-button type="primary" class="ml10" @click="add" icon="el-icon-Plus">设备出厂管理</el-button>
<el-button type="primary" class="ml10" @click="add" icon="el-icon-Plus">新增设备</el-button>
</template>
</TableHeader>
<Table ref="tableRef"></Table>
@@ -139,7 +139,7 @@ const rules = reactive({
sort: [{ required: true, message: '排序不能为空', trigger: 'blur' }]
})
const dialogFormVisible = ref(false)
const dialogTitle = ref('设备出厂管理')
const dialogTitle = ref('新增设备')
const loading = ref<boolean>(false)
const devModelOptions: any = ref([])
queryByCode('Device_Type').then(res => {
@@ -395,7 +395,7 @@ const tableStore = new TableStore({
// },
//便携式设备手动接入
{
title: '手动接入',
title: '接5入',
type: 'primary',
icon: 'el-icon-Grid',
render: 'basicButton',
@@ -403,7 +403,7 @@ const tableStore = new TableStore({
return (
(row.devType != '8b45cf6b7f5266e777d07c166ad5fa77' &&
row.devModel != 'a0d4da4b5c17b2172362a3f5a27bf217') ||
row.status == '5'
row.status != '5'
)
},
click: row => {
@@ -425,7 +425,7 @@ const tableStore = new TableStore({
}
},
{
title: '接入',
title: '接3入',
type: 'primary',
icon: 'el-icon-Grid',
render: 'basicButton',
@@ -433,7 +433,7 @@ const tableStore = new TableStore({
return (
(row.devType != '8b45cf6b7f5266e777d07c166ad5fa77' &&
row.devModel != 'a0d4da4b5c17b2172362a3f5a27bf217') ||
row.status == '3'
row.status != '3'
)
},
click: row => {
@@ -591,7 +591,7 @@ const bulkImport = (e: any) => {
// 新增
const add = () => {
dialogFormVisible.value = true
dialogTitle.value = '设备出厂管理'
dialogTitle.value = '新增设备'
}
// 确认
@@ -601,7 +601,7 @@ const onSubmit = () => {
ruleFormRef.value.validate((valid: any) => {
if (valid) {
if (dialogTitle.value == '设备出厂管理') {
if (dialogTitle.value == '新增设备') {
addEquipmentDelivery(form).then(res => {
ElMessage.success('新增成功')
if (devTypeOptions.value.filter((item: any) => item.value == form.devType)[0].code == 'Portable') {

View File

@@ -6,7 +6,7 @@
@Policy="stencil">
</PointTree>
</pane>
<pane style="background: #fff" :style="height">
<pane :size="(100 - size)" style="background: #fff" :style="height">
<TableHeader ref="TableHeaderRef" datePicker>
<template v-slot:select>
<el-form-item label="模板策略">
@@ -78,8 +78,8 @@ const tableStore = new TableStore({
tableStore.table.data.forEach((item: any) => {
item.data1 ? (item.data = JSON.parse(item.data1)) : ''
item.celldata.forEach((k: any) => {
item.data[k.r][k.c].v ? (item.data[k.r][k.c] = k.v ) : ''
item.data[k.r][k.c].v ? (item.data[k.r][k.c] = k.v) : ''
})
})
setTimeout(() => {
@@ -102,7 +102,7 @@ const flag = ref(true)
onMounted(() => {
const dom = document.getElementById('navigation-splitpanes')
if (dom) {
size.value = Math.round((180 / dom.offsetHeight) * 100)
size.value = ((280 / (dom.offsetWidth - 7)) * 100)
}
})

View File

@@ -6,7 +6,7 @@
@Policy="stencil">
</pointTreeWx>
</pane>
<pane style="background: #fff" :style="height">
<pane :size="(100-size)" style="background: #fff" :style="height">
<TableHeader ref="TableHeaderRef" :showReset="false">
<template v-slot:select>
<el-form-item label="模板策略">
@@ -65,8 +65,8 @@ const tableStore = new TableStore({
tableStore.table.data.forEach((item: any) => {
item.data1 ? (item.data = JSON.parse(item.data1)) : ''
item.celldata.forEach((k: any) => {
item.data[k.r][k.c].v ? (item.data[k.r][k.c] = k.v ) : ''
item.data[k.r][k.c].v ? (item.data[k.r][k.c] = k.v) : ''
})
})
setTimeout(() => {
@@ -90,7 +90,9 @@ const flag = ref(true)
onMounted(() => {
const dom = document.getElementById('navigation-splitpanes')
if (dom) {
size.value = Math.round((210 / dom.offsetHeight) * 100)
console.log("🚀 ~ onMounted ~ dom.offsetHeight:", dom.offsetWidth)
size.value = ((280 / (dom.offsetWidth - 7)) * 100)
}
})
@@ -112,7 +114,7 @@ const changetype = (val: any) => {
}
const handleNodeClick = (data: any, node: any) => {
if (data?.pid ) {
if (data?.pid) {
dotList.value = data
setTimeout(() => {
tableStore.index()