全局替换终端

This commit is contained in:
GGJ
2024-06-13 13:32:50 +08:00
parent d4db10d5ca
commit 2c66e096e7
90 changed files with 1369 additions and 628 deletions

View File

@@ -1,77 +1,339 @@
<template>
<div :class="show ? 'show' : 'noshow'">
<div class="boxLeft" :style="height">
<!-- 在线监测规模 -->
<div :style="boxHeight">
<!-- 监测规模 -->
<div class="mb10" :style="`height:250px);`">
<div class="title">
<span>在线监测规模</span>
<span>监测规模</span>
</div>
<div style="display: flex" class="mt2">
<img src="@/assets/img/FGX.png" />
</div>
<div style="display: flex">
<div v-for="(item, i) in list" class="cardBox" :style="i == 1 ? 'flex:1.3' : ''">
<div class="card">
<span style="cursor: pointer" @click="GridDiagram(i)">{{ item.title }}</span>
<span
:style="`color: ${item.color[0]}; cursor:pointer`"
@click="LookMap(item.list[4].numOneList, item.list[4].numTwoList, 0)"
>
{{ item.list[4].numOne }}
</span>
</div>
</div>
</div>
<!-- 监测规模 列表 -->
<div>
<div class="vcl mt5">
<p
v-for="(item, i) in vList"
:style="i == 0 ? 'width: 60px' : i == 5 ? 'width: 32px' : 'flex:1'"
>
{{ item }}
</p>
</div>
<div v-for="(item, i) in list" class="vcl">
<p style="width: 60px">
{{ item.title }}
<!-- <span style="position: absolute; font-size: 10px; top: -10px; right: -5px; color: #575757">
详情
</span> -->
</p>
<p class="numOne" @click="LookMap(item.list[0].numOneList, item.list[0].numTwoList, 0)">
{{ item.list[0].numOne }}
</p>
<p class="numOne" @click="LookMap(item.list[1].numOneList, item.list[1].numTwoList, 0)">
{{ item.list[1].numOne }}
</p>
<p class="numOne" @click="LookMap(item.list[2].numOneList, item.list[2].numTwoList, 0)">
{{ item.list[2].numOne }}
</p>
<p class="numOne" @click="LookMap(item.list[3].numOneList, item.list[3].numTwoList, 0)">
{{ item.list[3].numOne }}
</p>
<!-- <p
style="font-size: 12px; width: 32px; cursor: pointer; color: var(--el-color-primary)"
@click.stop="open(i)"
>
详情
</p> -->
</div>
</div>
</div>
<!-- 监测点指标统计 -->
<div :style="`height:calc(${boxHeight.height} + 50px)`">
<div class="title">
<span>监测点指标统计</span>
</div>
<div style="display: flex" class="mt2">
<img src="@/assets/img/FGX.png" />
</div>
<div :style="`height:calc(${boxHeight.height} + 20px);overflow-y: auto;`">
<div v-for="item in countList">
<div class="title mt5" style="font-weight: 500">
<img src="@/assets/img/TJ.png" />
{{ item.title }}
</div>
<div
class="card-Box"
:style="`height:calc((${boxHeight.height} - 50px )/ 3);`"
v-for="val in item.children"
>
<div>
<span class="line"></span>
<span class="vol">{{ val.title }}</span>
</div>
<div class="num">
<div @click="LookMap(val.numList, [], 0)">
投运:
<span>{{ val.num }}</span>
</div>
<div @click="LookMap(val.onLineNumList, [], 0)">
在线:
<span style="color: #2dcd28">{{ val.onLineNum }}</span>
</div>
<div>
数据完整性:
<span style="color: #2b7fd3; cursor: text">{{ val.integrityRate }}%</span>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- 监测点指标统计 -->
<div :style="`height:calc(${boxHeight.height} - 55px)`">
<div class="title">
<span>监测运行统计</span>
</div>
<div style="display: flex" class="mt2">
<img src="@/assets/img/FGX.png" />
</div>
<div style="display: flex" class="mt2">
<img src="@/assets/img/FGX.png" />
<div :style="`height:calc(${boxHeight.height} - 100px);overflow-y: auto;`" class="BoxA mt10">
<div class="card-Box" v-for="item in linList">
<div>
<span class="line"></span>
<span class="vol">{{ item.title[0] }}</span>
</div>
<div class="num">
<div>
{{ item.title[1] }}:
<span style="color: #2dcd28" @click="LookMap(item.lineListOne, [], 0)">
{{ item.lineNumOne || 0 }}
</span>
</div>
<div>
{{ item.title[2] }}:
<span style="color: #cc0000" @click="LookMap([], item.lineListTwo, 1)">
{{ item.lineNumTwo || 0 }}
</span>
</div>
</div>
</div>
</div>
<MyEChart :style="tabHeight" :options="onlineCharts" />
</div>
<!-- 监测终端状态 -->
<div :style="boxHeight">
<div class="title">
<span>监测终端状态</span>
</div>
<div style="display: flex" class="mt2">
<img src="@/assets/img/FGX.png" />
</div>
<div class="TJTop">
<img src="@/assets/img/TJ.png" />
终端在线率
<span>{{ onlineRate }}%</span>
</div>
<MyEChart :style="`height: calc(${tabHeight.height} - 27px)`" :options="terminalCharts" />
</div>
<!-- 监测点 -->
<div :style="boxHeight">
<div class="title">
<span>监测点数据完整率</span>
</div>
<div style="display: flex" class="mt2">
<img src="@/assets/img/FGX.png" />
</div>
<MyEChart :style="tabHeight" :options="dotCharts" />
</div>
</div>
<img
class="imgL"
:style="show ? 'transform: rotate(0deg);' : 'transform: rotate(180deg);'"
@click="show = !show"
src="@/assets/img/QH.png"
/>
<!-- 变电站详情 -->
<stand ref="standRef" />
<!-- 终端 -->
<terminal ref="terminalRef" />
<!-- 检测点 -->
<point ref="pointRef" />
</div>
</template>
<script setup lang="ts">
import { onMounted, reactive, ref, provide } from 'vue'
import MyEChart from '@/components/echarts/MyEchart.vue'
import { useDictData } from '@/stores/dictData'
import { mainHeight } from '@/utils/layout'
import { getGridDiagramAreaData, getGridDiagramCityDev, getGridDiagramLineData } from '@/api/device-boot/panorama'
import { useConfig } from '@/stores/config'
const config = useConfig()
import { ArrowRight, View } from '@element-plus/icons-vue'
import stand from './details/stand.vue'
import terminal from './details/terminal.vue'
import point from './details/point.vue'
import {
getSubLineGiveAnAlarm,
getGridDiagramMonitor,
getGridDiagramDev,
getGridDiagramStatistics,
getGridDiagramRunData
} from '@/api/device-boot/panorama'
const emit = defineEmits(['LookMap', 'GridDiagram'])
const dictData = useDictData()
const height = mainHeight(30)
const boxHeight = mainHeight(40, 3)
const tabHeight: any = mainHeight(150, 3)
const onlineRate = ref(0)
const show = ref(false)
const standRef = ref()
const terminalRef = ref()
const pointRef = ref()
const list: any = ref([
{
title: '变电站',
color: ['#000', '#bd3124'],
list: [
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
}
]
},
{
title: '监测终端',
color: ['#000', '#2dcd28'],
list: [
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
}
]
},
{
title: '监测点',
color: ['#000', '#2dcd28', '#bd3124'],
list: [
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
},
{
numOne: 0,
numTwo: 0,
numOneList: [],
numTwoList: []
}
]
}
])
const countList: any = ref([
{
title: '冀北',
children: [
{
title: '电网侧监测点',
num: 0,
onLineNum: 0,
integrityRate: 0
},
{ title: '非电网侧监测点', num: 0, onLineNum: 0, integrityRate: 0 }
]
},
{
title: '上送国网',
children: [{ title: '电网侧监测点', num: 0, onLineNum: 0, integrityRate: 0 }]
}
])
const linList: any = ref([
{
title: ['运行状态', '合格', '告警']
},
{
title: ['通讯状态', '在线', '离线']
},
{
title: ['数据完整性', '≥90%', '<90%']
},
{
title: ['电能质量指标', '未超标', '超标']
}
])
const vList = ['', '500kV', '220kV', '110kV', '35kV', ]
const formRow: any = ref({})
const terminalCharts: any = ref({})
const height = mainHeight(30)
const boxHeight = mainHeight(290, 2)
const dotCharts = ref()
const onlineCharts = ref()
const info = (row: any) => {
// 详情
const open = (e: any) => {
if (e == 0) {
standRef.value.open(formRow.value)
} else if (e == 1) {
terminalRef.value.open(formRow.value)
} else if (e == 2) {
pointRef.value.open(formRow.value)
}
}
const info = async (row: any) => {
let form = {
...row,
id: row.orgNo,
@@ -82,181 +344,66 @@ const info = (row: any) => {
isUpToGrid: row.isUpToGrid,
monitorFlag: row.isUpToGrid == 0 ? null : row.isUpToGrid
}
let loadType = dictData.getBasicData('Statistical_Type').find(item => item.code == 'Load_Type')
countList.value[0].title = row.areaName
formRow.value = form
// 变电站
getGridDiagramAreaData(form).then(res => {
onlineCharts.value = {
tooltip: {},
yAxis: {
type: 'value',
name: '个'
},
xAxis: {
type: 'category',
data: ['变电站', '监测终端', '监测点'],
axisLabel: {
color: '#000',
fontSize: 12
}
},
grid: {
top: '30px',
left: '10px',
right: '20px'
},
options: {
dataZoom: null,
series: [
{
name: '个数',
type: 'bar',
data: [
res.data[0].subNum,
res.data[0].deviceNum,
res.data[0].lineNum
],
label: {
show: true,
position: 'top',
fontSize: 10
}
}
]
}
}
getSubLineGiveAnAlarm(form).then(res => {
let data = row.isUpToGrid == 1 ? res.data.gwInfo : res.data.info
list.value[0].list = data[0].data
})
// 终端
getGridDiagramCityDev({ ...form, deviceInfoParam: form, pageNum: 1, pageSize: 1000 }).then(res => {
onlineRate.value = res.data[1]
let data = [
{
name: '运行',
value: res.data[0] - 0
},
{
name: '检修',
value: res.data[2] - 0
},
{
name: '退役',
value: res.data[4] - 0
}
]
terminalCharts.value = {
title: {
text: data[0].value + data[1].value + data[2].value,
left: '26%',
top: '40%',
textStyle: {
fontWeight: 600,
fontSize: 16
},
subtext: '总数',
subtextStyle: {
fontWeight: 550,
fontSize: 14
}
},
tooltip: {
trigger: 'item'
},
legend: {
orient: 'vertical',
top: 'center',
right: '10%',
formatter: function (e: any) {
return e + ' ' + data.filter(item => item.name == e)[0].value + '台'
}
},
xAxis: {
show: false
},
yAxis: {
show: false
},
color: [config.layout.elementUiPrimary[0], '#FFBF00', '#FF9100'],
options: {
dataZoom: null,
series: [
{
type: 'pie',
center: ['30%', '50%'],
radius: ['40%', '60%'],
label: {
show: false,
position: 'outside',
textStyle: {
//数值样式
}
},
data: data
}
]
}
}
getGridDiagramDev(form).then(res => {
let data = row.isUpToGrid == 1 ? res.data.gwInfo : res.data.info
list.value[1].list = data[0].data
})
// 监测点
getGridDiagramLineData({ ...form, statisticalType: loadType }).then(res => {
dotCharts.value = {
title: {
text: ''
},
// str.replace(/\(\d+\)/, "\n$&");
xAxis: {
data: res.data.map((item: any) => {
let title = item.orgName.replace(/\(\d+\)/g, '')
// return title.length > 5
return title.length > 6
? title.length > 11
? title.slice(0, 5) + '\n ' + title.slice(5, 10) + '\n ' + title.slice(10)
: title.slice(0, 5) + '\n ' + title.slice(5)
: title
}),
axisLabel: {
color: '#000',
fontSize: 12,
interval: 0
}
},
yAxis: {
name: '%',
min: 0,
max: 100
},
grid: {
top: '30px',
left: '0px',
right: '20px',
bottom: 0
},
options: {
dataZoom: null,
series: [
{
name: '数据完整率',
type: 'bar',
await getGridDiagramMonitor(form).then(res => {
let data = row.isUpToGrid == 1 ? res.data.gwInfo : res.data.info
data: res.data.map((item: any) => item.integrityRate),
label: {
show: true,
position: 'top',
fontSize: 10
}
}
]
list.value[2].list = data[0].data.map((item: any) => {
return {
numOne: item.num,
numTwo: item.onLineNum,
numOneList: item.numList,
numTwoList: item.onLineNumList
}
}
})
list.value[2].list.push({
numOne: 0,
numOneList: []
})
})
// 监测点指标统计
getGridDiagramStatistics(form).then(res => {
countList.value[0].children[0] = { title: '电网侧监测点', ...res.data.data[0] }
countList.value[0].children[1] = { title: '非电网侧监测点', ...res.data.data[1] }
countList.value[1].children[0] = { title: '电网侧监测点', ...res.data.gwData[0] }
})
// 监测运行统计
getGridDiagramRunData(form).then(res => {
res.data[0].title = ['运行状态', '合格', '告警']
res.data[1].title = ['通讯状态', '在线', '离线']
res.data[2].title = ['数据完整性', '≥90%', '<90%']
res.data[3].title = ['电能质量指标', '未超标', '超标']
linList.value = res.data
})
}
// 点击
const LookMap = (coutList: object, alarmList: object, key?: any) => {
// console.log('🚀 ~ LookMap ~ row:', row)
let form = {
coutList: coutList,
alarmList: alarmList
}
emit('LookMap', form, key)
}
const GridDiagram = (k: any) => {
emit('GridDiagram', k, 3)
}
onMounted(() => {})
defineExpose({ info, show })
</script>
@@ -264,22 +411,80 @@ defineExpose({ info, show })
.boxLeft {
background-color: #fff;
width: 100%;
padding: 10px 10px 10px 10px;
// padding: 10px 10px 10px 10px;
border-radius: 5px;
font-size: 13px;
overflow: hidden;
}
.cardBox {
display: flex;
flex-wrap: wrap;
flex: 1;
.card {
justify-content: center;
margin-top: 15px;
margin-right: 2%;
display: flex;
flex: 1;
align-items: center;
font-size: 16px;
span:nth-child(2) {
font-weight: 550;
}
}
}
.vcl {
display: flex;
border-bottom: 2px solid #fff;
background-color: #edededc0;
border-radius: 5px;
font-size: 14px;
p {
text-align: center;
margin: 6px;
line-height: 30px;
}
.numOne {
flex: 1;
font-weight: 550;
cursor: pointer;
}
&:nth-child(1) {
background-color: #fff;
}
&:nth-child(2) {
.numOne {
color: #00bff5;
}
}
&:nth-child(3) {
.numOne {
color: #008000;
}
}
&:nth-child(4) {
.numOne {
color: #0000ff;
}
}
}
.title {
// height: ;
display: flex;
justify-content: space-between;
// display: flex;
// justify-content: space-between;
font-size: 15px;
line-height: 23px;
padding-left: 5px;
width: 100%;
font-weight: 550;
display: flex;
align-items: center;
span:nth-child(1) {
cursor: pointer;
}
.info {
font-weight: normal;
display: flex;
@@ -287,6 +492,60 @@ defineExpose({ info, show })
cursor: pointer;
color: #757575;
}
img {
height: 1.2rem;
width: 1.2rem;
margin-right: 5px;
}
}
.card-Box {
// display: grid;
// grid-template-rows: 1fr 1fr;
display: flex;
flex-direction: column;
justify-content: space-evenly;
// align-items: center;
margin: 0 5px 5px;
padding: 10px;
background-color: #edededc0;
border-radius: 10px;
min-height: 60px;
max-height: 120px;
.line {
display: inline-block;
width: 0.5rem;
height: 0.5rem;
border-radius: 0.25rem;
background: var(--el-color-primary);
margin-right: 5px;
margin-bottom: 2px;
}
.num {
margin-left: 10px;
display: grid;
text-align: center;
grid-template-columns: 1fr 1fr 1.5fr;
font-size: 14px;
span {
cursor: pointer;
font-size: 16px;
font-weight: 550;
}
}
}
.BoxA {
display: grid;
grid-template-columns: 1fr 1fr;
grid-template-rows: 1fr 1fr;
// grid-template-rows: 80px;
.num {
margin-left: 10px;
display: grid;
text-align: center;
grid-template-columns: 1fr 1fr;
}
}
.imgL {
@@ -302,7 +561,7 @@ defineExpose({ info, show })
.show {
width: 0px;
transition: all 0.1s ease;
transition: all 0.3s ease;
.boxLeft {
padding: 0;
}
@@ -320,18 +579,6 @@ defineExpose({ info, show })
:deep(.el-table thead) {
color: #000;
}
.TJTop {
margin-top: 10px;
display: flex;
img {
height: 1.2rem;
width: 1.2rem;
margin-right: 5px;
}
span {
color: #2dcd28;
}
}
:deep(.el-dialog__body) {
max-height: none !important;
}

View File

@@ -0,0 +1,338 @@
<template>
<div :class="show ? 'show' : 'noshow'">
<div class="boxLeft" :style="height">
<!-- 在线监测规模 -->
<div :style="boxHeight">
<div class="title">
<span>在线监测规模</span>
</div>
<div style="display: flex" class="mt2">
<img src="@/assets/img/FGX.png" />
</div>
<MyEChart :style="tabHeight" :options="onlineCharts" />
</div>
<!-- 监测终端状态 -->
<div :style="boxHeight">
<div class="title">
<span>监测终端状态</span>
</div>
<div style="display: flex" class="mt2">
<img src="@/assets/img/FGX.png" />
</div>
<div class="TJTop">
<img src="@/assets/img/TJ.png" />
终端在线率
<span>{{ onlineRate }}%</span>
</div>
<MyEChart :style="`height: calc(${tabHeight.height} - 27px)`" :options="terminalCharts" />
</div>
<!-- 监测点 -->
<div :style="boxHeight">
<div class="title">
<span>监测点数据完整率</span>
</div>
<div style="display: flex" class="mt2">
<img src="@/assets/img/FGX.png" />
</div>
<MyEChart :style="tabHeight" :options="dotCharts" />
</div>
</div>
<img
class="imgL"
:style="show ? 'transform: rotate(0deg);' : 'transform: rotate(180deg);'"
@click="show = !show"
src="@/assets/img/QH.png"
/>
</div>
</template>
<script setup lang="ts">
import { onMounted, reactive, ref, provide } from 'vue'
import MyEChart from '@/components/echarts/MyEchart.vue'
import { useDictData } from '@/stores/dictData'
import { mainHeight } from '@/utils/layout'
import { getGridDiagramAreaData, getGridDiagramCityDev, getGridDiagramLineData } from '@/api/device-boot/panorama'
import { useConfig } from '@/stores/config'
const config = useConfig()
const dictData = useDictData()
const height = mainHeight(30)
const boxHeight = mainHeight(40, 3)
const tabHeight: any = mainHeight(150, 3)
const onlineRate = ref(0)
const show = ref(false)
const formRow: any = ref({})
const terminalCharts: any = ref({})
const dotCharts = ref()
const onlineCharts = ref()
const info = (row: any) => {
let form = {
...row,
id: row.orgNo,
deptIndex: row.orgNo,
orgId: row.orgNo,
ids: [],
statisticalType: dictData.getBasicData('Statistical_Type', ['Report_Type'])[0],
isUpToGrid: row.isUpToGrid,
monitorFlag: row.isUpToGrid == 0 ? null : row.isUpToGrid
}
let loadType = dictData.getBasicData('Statistical_Type').find(item => item.code == 'Load_Type')
formRow.value = form
// 变电站
getGridDiagramAreaData(form).then(res => {
onlineCharts.value = {
tooltip: {},
yAxis: {
type: 'value',
name: '个'
},
xAxis: {
type: 'category',
data: ['变电站', '监测终端', '监测点'],
axisLabel: {
color: '#000',
fontSize: 12
}
},
grid: {
top: '30px',
left: '10px',
right: '20px'
},
options: {
dataZoom: null,
series: [
{
name: '个数',
type: 'bar',
data: [
res.data[0].subNum,
res.data[0].deviceNum,
res.data[0].lineNum
],
label: {
show: true,
position: 'top',
fontSize: 10
}
}
]
}
}
})
// 终端
getGridDiagramCityDev({ ...form, deviceInfoParam: form, pageNum: 1, pageSize: 1000 }).then(res => {
onlineRate.value = res.data[1]
let data = [
{
name: '运行',
value: res.data[0] - 0
},
{
name: '检修',
value: res.data[2] - 0
},
{
name: '退役',
value: res.data[4] - 0
}
]
terminalCharts.value = {
title: {
text: data[0].value + data[1].value + data[2].value,
left: '26%',
top: '40%',
textStyle: {
fontWeight: 600,
fontSize: 16
},
subtext: '总数',
subtextStyle: {
fontWeight: 550,
fontSize: 14
}
},
tooltip: {
trigger: 'item'
},
legend: {
orient: 'vertical',
top: 'center',
right: '10%',
formatter: function (e: any) {
return e + ' ' + data.filter(item => item.name == e)[0].value + '台'
}
},
xAxis: {
show: false
},
yAxis: {
show: false
},
color: [config.layout.elementUiPrimary[0], '#FFBF00', '#FF9100'],
options: {
dataZoom: null,
series: [
{
type: 'pie',
center: ['30%', '50%'],
radius: ['40%', '60%'],
label: {
show: false,
position: 'outside',
textStyle: {
//数值样式
}
},
data: data
}
]
}
}
})
// 监测点
getGridDiagramLineData({ ...form, statisticalType: loadType }).then(res => {
dotCharts.value = {
title: {
text: ''
},
// str.replace(/\(\d+\)/, "\n$&");
xAxis: {
data: res.data.map((item: any) => {
let title = item.orgName.replace(/\(\d+\)/g, '')
// return title.length > 5
return title.length > 6
? title.length > 11
? title.slice(0, 5) + '\n ' + title.slice(5, 10) + '\n ' + title.slice(10)
: title.slice(0, 5) + '\n ' + title.slice(5)
: title
}),
axisLabel: {
color: '#000',
fontSize: 12,
interval: 0
}
},
yAxis: {
name: '%',
min: 0,
max: 100
},
grid: {
top: '30px',
left: '0px',
right: '20px',
bottom: 0
},
options: {
dataZoom: null,
series: [
{
name: '数据完整率',
type: 'bar',
data: res.data.map((item: any) => item.integrityRate),
label: {
show: true,
position: 'top',
fontSize: 10
}
}
]
}
}
})
}
defineExpose({ info, show })
</script>
<style lang="scss" scoped>
.boxLeft {
background-color: #fff;
width: 100%;
padding: 10px 10px 10px 10px;
border-radius: 5px;
font-size: 13px;
overflow: hidden;
}
.title {
// height: ;
display: flex;
justify-content: space-between;
font-size: 15px;
line-height: 23px;
padding-left: 5px;
width: 100%;
font-weight: 550;
.info {
font-weight: normal;
display: flex;
font-size: 12px;
cursor: pointer;
color: #757575;
}
}
.imgL {
position: absolute;
padding: 10px;
top: calc(50% - 80px);
right: -23px;
transform: rotate(180deg);
height: 200px;
cursor: pointer;
}
.show {
width: 0px;
transition: all 0.1s ease;
.boxLeft {
padding: 0;
}
}
.noshow {
width: 25%;
transition: all 0.3s ease;
.boxLeft {
padding: 10px 10px 10px 10px;
}
}
:deep(.el-card) {
--el-card-padding: 10px !important;
}
:deep(.el-table thead) {
color: #000;
}
.TJTop {
margin-top: 10px;
display: flex;
img {
height: 1.2rem;
width: 1.2rem;
margin-right: 5px;
}
span {
color: #2dcd28;
}
}
:deep(.el-dialog__body) {
max-height: none !important;
}
</style>

View File

@@ -418,18 +418,18 @@ const info = (row: any) => {
]
statisticsCharts.value = {
title: {
text: data[0].value + data[1].value + data[2].value,
left: '26%',
top: '40%',
text:'总数:'+ (data[0].value + data[1].value + data[2].value),
left: '23%',
top: '45%',
textStyle: {
fontWeight: 600,
fontSize: 16
// fontWeight: 600,
fontSize: 12
},
subtext: '总数',
subtextStyle: {
fontWeight: 550,
fontSize: 14
}
// subtext: '总数',
// subtextStyle: {
// fontWeight: 550,
// fontSize: 14
// }
},
tooltip: {

View File

@@ -131,12 +131,12 @@
<el-option label="年" value="1" />
<el-option label="月" value="3" />
</el-select> -->
<div style="position: absolute; width: 100px; top: 0px; right: 10px; z-index: 1">
<el-radio-group v-model="city" size="small" >
<el-radio-button label="1"></el-radio-button>
<el-radio-button label="2"></el-radio-button>
<div style="position: absolute; width: 100px; top: 0px; right: 0px; z-index: 1">
<el-radio-group v-model="city" size="small" @change="analysis">
<el-radio-button label="0"></el-radio-button>
<el-radio-button label="1"></el-radio-button>
</el-radio-group>
<el-radio-group v-model="time" size="small" @change="analysis">
<el-radio-group v-model="type" size="small" @change="analysis">
<el-radio-button label="1"></el-radio-button>
<el-radio-button label="3"></el-radio-button>
</el-radio-group>
@@ -153,8 +153,8 @@ import { defaultAttribute } from '@/components/table/defaultAttribute'
import { getAssessDetail, getAssessTrend } from '@/api/device-boot/panorama'
const dialogVisible: any = ref(false)
const rowList: any = ref({})
const time = ref('1')
const city = ref('1')
const type = ref('1')
const city = ref('0')
const loading = ref(false)
const tableData: any = ref([])
@@ -164,13 +164,13 @@ const open = async (row: any) => {
tableData.value = res.data
})
rowList.value = row
analysis(1)
analysis()
dialogVisible.value = true
}
const analysis = (e: any) => {
const analysis = () => {
loading.value = true
let time = rowList.value.searchBeginTime.slice(0, 4) + `-01-01`
getAssessTrend({ ...rowList.value, searchBeginTime: time, type: e }).then(res => {
getAssessTrend({ ...rowList.value, searchBeginTime: time, type: type.value, areaType: city.value }).then(res => {
picEChart.value = {
title: {
text: '各地市综合评估趋势对比'
@@ -230,7 +230,7 @@ const analysis = (e: any) => {
grid: {
bottom: '10px',
top: '60px',
top: '60px'
},
yAxis: {

View File

@@ -456,18 +456,18 @@ const open = async (id: string) => {
]
incidentCharts.value = {
title: {
text: ' ' + (data[0].value + data[1].value + data[2].value),
left: '41%',
top: '40%',
text: '总数:' + (data[0].value + data[1].value + data[2].value),
left: '40%',
top: '45%',
textStyle: {
fontWeight: 600,
fontSize: 16
// fontWeight: 600,
fontSize: 12
},
subtext: '总数',
subtextStyle: {
fontWeight: 550,
fontSize: 14
}
// subtext: '总数',
// subtextStyle: {
// fontWeight: 550,
// fontSize: 14
// }
},
tooltip: {

View File

@@ -8,7 +8,7 @@
v-model.trim="inputQuery"
style="height: 46px; width: 334px"
@keyup.enter="DeviceQ"
placeholder="请输入设备名称"
placeholder="请输入终端名称"
>
<template #prefix>
<div class="Icon"></div>
@@ -127,7 +127,7 @@ const LngLat = [
]
import { getAssessOverview } from '@/api/device-boot/panorama'
narimap.Require(['PSRMap', 'Thematic', 'Components.Query', 'Components.RegionSelector'], () => {
narimap.Require(['PSRMap', 'Thematic', 'Components.Query','Components.MapSelector', 'Components.RegionSelector'], () => {
if (narimap.Config.examples.notlogin) {
initMap(narimap.Config.styles.sjRaster)
} else {
@@ -147,9 +147,6 @@ narimap.Require(['PSRMap', 'Thematic', 'Components.Query', 'Components.RegionSel
console.log('错误', err)
})
}
setTimeout(() => {
console.log('🚀 ~ .then ~ narimap.Config.style:', narimap.Config)
}, 0)
})
function initMap(styleurl: any) {
map.value = new narimap.Map({
@@ -163,6 +160,7 @@ function initMap(styleurl: any) {
localIdeographFontFamily: 'Microsoft YoHei'
})
map.value.on('load', () => {
createMapSelectorComponent()
DeviceQuery.value = new narimap.ResourceQuery.DeviceQuery()
addLayer()
@@ -984,6 +982,24 @@ const flyTo = (row: any, zoom?: number) => {
})
}
// 添加地图选择
const createMapSelectorComponent = () => {
const mapSelector = new narimap.Components.MapSelector();
mapSelector.init(
map.value,
// ['sjBase', 'sjDark'],
// [
// {
// styleKey: 'sjRaster',
// styleName: '影像图',
// styleUrl: narimap.Config.styles.sjRaster,
// // styleIcon: WebGIS.Config.apiRoot + 'libs/webgis/images/map/map_sjRasterStyle.png'
// }
// ]
)
}
defineExpose({ locatePositions, addMarkers, grids, DeviceQ, radiusPop, flyTo })
const height = mainHeight(20)
</script>

View File

@@ -13,12 +13,12 @@
<div v-for="(item, i) in list" class="cardBox" :style="i == 1 ? 'flex:1.3' : ''">
<div class="card">
<span style="cursor: pointer" @click="GridDiagram(i)">{{ item.title }}</span>
<span
<!-- <span
:style="`color: ${item.color[0]}; cursor:pointer`"
@click="LookMap(item.list[4].numOneList, item.list[4].numTwoList, 0)"
>
{{ item.list[4].numOne }}
</span>
</span> -->
</div>
</div>
</div>
@@ -142,6 +142,12 @@
@click="show = !show"
src="@/assets/img/QH.png"
/>
<div class="legeng">
<div v-for="item in legengList">
<span :style="`background-color: ${item.color};`"></span>
<span>{{ item.title }}</span>
</div>
</div>
<!-- 变电站详情 -->
<stand ref="standRef" />
@@ -318,6 +324,28 @@ const linList: any = ref([
title: ['电能质量指标', '未超标', '超标']
}
])
const legengList = [
{
color: '#00b07d',
title: '优质'
},
{
color: '#3399ff',
title: '良好'
},
{
color: '#ffcc33',
title: '合格'
},
{
color: '#db0887',
title: '较差'
},
{
color: '#ff0000',
title: '极差'
}
]
const vList = ['', '500kV', '220kV', '110kV', '35kV', '']
const formRow: any = ref({})
const height = mainHeight(30)
@@ -344,6 +372,7 @@ const info = async (row: any) => {
isUpToGrid: row.isUpToGrid,
monitorFlag: row.isUpToGrid == 0 ? null : row.isUpToGrid
}
countList.value[0].title = row.areaName
formRow.value = form
// 变电站
@@ -453,6 +482,21 @@ defineExpose({ info, show })
&:nth-child(1) {
background-color: #fff;
}
&:nth-child(2) {
.numOne {
color: #00bff5;
}
}
&:nth-child(3) {
.numOne {
color: #008000;
}
}
&:nth-child(4) {
.numOne {
color: #0000ff;
}
}
}
.title {
@@ -566,4 +610,30 @@ defineExpose({ info, show })
:deep(.el-dialog__body) {
max-height: none !important;
}
.legeng {
position: absolute;
padding: 5px;
bottom: 0;
right: -75px;
width: 70px;
font-size: 12px;
height: 120px;
background: #fff;
border-radius: 5px;
display: grid;
line-height: 22px;
grid-template-rows: auto;
div {
display: flex;
align-items: center;
justify-content: center;
span:nth-child(1) {
display: inline-block;
height: 10px;
border-radius: 2px;
width: 15px;
margin-right: 5px;
}
}
}
</style>

View File

@@ -5,7 +5,7 @@
<div style="height: 110px">
<div class="title">
<span>
综合评估
稳态综合评估
<el-popover placement="right" :width="150" trigger="hover">
<template #reference>
<WarningFilled class="WarningFilled" />
@@ -229,12 +229,12 @@
@click="show = !show"
src="@/assets/img/QH.png"
/>
<div class="legeng">
<!-- <div class="legeng">
<div v-for="item in legengList">
<span :style="`background-color: ${item.color};`"></span>
<span>{{ item.title }}</span>
</div>
</div>
</div> -->
<!-- 评估 -->
<Evaluate ref="evaluateRef" />
<!-- 稳态 -->

View File

@@ -97,6 +97,9 @@
:deep(.sgmap-canvas) {
width: 100% !important;
}
:deep(.sgmap-ctrl-bottom-right) {
z-index: 0 !important;
}
:deep(.my-popup) {
max-width: 400px !important;
.popup-box {
@@ -184,7 +187,7 @@
display: flex;
justify-content: space-around;
text-align: center;
div{
div {
cursor: pointer;
}
}