|
@@ -1,101 +1,115 @@
|
|
|
<template>
|
|
|
- <div >
|
|
|
- <div class="systemData bodys">
|
|
|
- <div class="line">
|
|
|
- <ul>
|
|
|
- <li v-for="(item,index) in TargetData" :key="index" :class="{active:headerIndex==index}" @click="changeTitle(index,item)" > {{item.name}} </li>
|
|
|
- </ul>
|
|
|
- <div style="display: flex">
|
|
|
-
|
|
|
-<!-- <el-button round size="mini" class="buttons" @click="downXlsxFn">导出</el-button>-->
|
|
|
-
|
|
|
- <div class="rightContent"> <div class="more" @click="addTargets"><i>+</i>更多指标</div> </div>
|
|
|
- <el-tooltip class="item" effect="dark" content="导出" placement="bottom">
|
|
|
- <el-button class="updownTits icon-dataOut" round size="mini" type="primary"
|
|
|
- @click="downXlsxFn"
|
|
|
- >
|
|
|
- </el-button>
|
|
|
- </el-tooltip>
|
|
|
- </div>
|
|
|
-
|
|
|
- </div>
|
|
|
- <el-table
|
|
|
- :data="stationData"
|
|
|
- class="table-fixed"
|
|
|
- ref="multipleTable"
|
|
|
- :cell-style="cellStyle"
|
|
|
- :header-cell-style="headerStyle"
|
|
|
- height="900px"
|
|
|
- style="width: 100%"
|
|
|
- fit
|
|
|
- v-loading="loading"
|
|
|
- element-loading-text="加载中..."
|
|
|
- empty-text=" "
|
|
|
- v-if="tableShow"
|
|
|
- stripe>
|
|
|
- <el-table-column
|
|
|
- type="index"
|
|
|
- label="序号"
|
|
|
- align="center"
|
|
|
- fixed
|
|
|
- class-name="anames"
|
|
|
- width="52">
|
|
|
- </el-table-column>
|
|
|
- <el-table-column v-for="(item,index) in uniformDetial" :key="index"
|
|
|
- :prop="item.tagCode"
|
|
|
- sortable
|
|
|
- align="center"
|
|
|
- header-align="center"
|
|
|
- :resizable="true"
|
|
|
- :width="item.width"
|
|
|
- :min-width="item.width"
|
|
|
- :fixed="index<2"
|
|
|
- >
|
|
|
- <template v-slot="scope" v-if="cilent=='click'">
|
|
|
- <el-tag @click="v(item.tagCode,scope.$index,item,scope.row, scope.row[`${item.tagCode}`])">
|
|
|
-
|
|
|
- <span v-if="item.tagName!=='设备名称' && item.tagName!=='设备类型'" style="cursor: pointer">
|
|
|
- {{ scope.row[`${item.tagCode}`+'value'] }}
|
|
|
+ <div>
|
|
|
+ <div class="systemData bodys" >
|
|
|
+ <div >
|
|
|
+ <div class="line" v-if="TargetData.length>0">
|
|
|
+ <ul >
|
|
|
+ <li v-for="(item,index) in TargetData" :key="index" :class="{active:headerIndex==index}"
|
|
|
+ @click="changeTitle(index,item)"> {{ item.name }}
|
|
|
+ </li>
|
|
|
+ </ul>
|
|
|
+ <div style="display: flex">
|
|
|
+
|
|
|
+ <!-- <el-button round size="mini" class="buttons" @click="downXlsxFn">导出</el-button>-->
|
|
|
+
|
|
|
+ <div class="rightContent">
|
|
|
+ <div class="more" @click="addTargets"><i>+</i>更多指标</div>
|
|
|
+ </div>
|
|
|
+ <el-tooltip class="item" effect="dark" content="导出" placement="bottom">
|
|
|
+ <el-button class="updownTits icon-dataOut" round size="mini" type="primary"
|
|
|
+ @click="downXlsxFn"
|
|
|
+ >
|
|
|
+ </el-button>
|
|
|
+ </el-tooltip>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ </div>
|
|
|
+ <div v-else-if="noData===1 && TargetData.length<=0" class="empty-data">
|
|
|
+ <el-col :span="24">暂无数据</el-col>
|
|
|
+ </div>
|
|
|
+ <el-table
|
|
|
+ :data="stationData"
|
|
|
+ class="table-fixed"
|
|
|
+ ref="multipleTable"
|
|
|
+ :cell-style="cellStyle"
|
|
|
+ :header-cell-style="headerStyle"
|
|
|
+ height="900px"
|
|
|
+ style="width: 100%"
|
|
|
+ fit
|
|
|
+ v-loading="loading"
|
|
|
+ element-loading-text="加载中..."
|
|
|
+ empty-text=" "
|
|
|
+
|
|
|
+ stripe>
|
|
|
+ <el-table-column v-if="TargetData.length>0"
|
|
|
+ type="index"
|
|
|
+ label="序号"
|
|
|
+ align="center"
|
|
|
+ fixed
|
|
|
+ class-name="anames"
|
|
|
+ width="52">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column v-if="TargetData.length>0" v-for="(item,index) in uniformDetial" :key="index"
|
|
|
+ :prop="item.tagCode"
|
|
|
+ sortable
|
|
|
+ align="center"
|
|
|
+ header-align="center"
|
|
|
+ :resizable="true"
|
|
|
+ :width="item.width"
|
|
|
+ :min-width="item.width"
|
|
|
+ :fixed="index<2"
|
|
|
+ >
|
|
|
+ <template v-slot="scope" v-if="cilent=='click'">
|
|
|
+ <el-tag>
|
|
|
+
|
|
|
+ <span @click="v(item.tagCode,scope.$index,item,scope.row, scope.row[`${item.tagCode}`])"
|
|
|
+ v-if="item.tagName!=='设备名称' && item.tagName!=='设备类型'" style="cursor: pointer">
|
|
|
+ {{ scope.row[`${item.tagCode}` + 'value'] }}
|
|
|
</span>
|
|
|
|
|
|
- <span v-else> {{
|
|
|
+ <span v-else> {{
|
|
|
|
|
|
- scope.row[`${item.tagCode}`] || '--'
|
|
|
- }}</span>
|
|
|
+ scope.row[`${item.tagCode}`] || '--'
|
|
|
+ }}</span>
|
|
|
|
|
|
- </el-tag>
|
|
|
- </template>
|
|
|
- <template v-slot="scope" v-else>
|
|
|
+ </el-tag>
|
|
|
+ </template>
|
|
|
+ <template v-slot="scope" v-else>
|
|
|
|
|
|
- <el-tag @contextmenu="v(item.tagCode,scope.$index,item,scope.row, scope.row[`${item.tagCode}`])">
|
|
|
+ <el-tag >
|
|
|
|
|
|
- <span v-if="item.tagName!=='设备名称' && item.tagName!=='设备型号'" style="cursor: pointer">
|
|
|
- {{ scope.row[`${item.tagCode}`+'value'] }}
|
|
|
+ <span @contextmenu="v(item.tagCode,scope.$index,item,scope.row, scope.row[`${item.tagCode}`])"
|
|
|
+ v-if="item.tagName!=='设备名称' && item.tagName!=='设备型号'" style="cursor: pointer">
|
|
|
+ {{ scope.row[`${item.tagCode}` + 'value'] }}
|
|
|
</span>
|
|
|
|
|
|
- <span v-else> {{
|
|
|
+ <span v-else> {{
|
|
|
|
|
|
- scope.row[`${item.tagCode}`] || '--'
|
|
|
- }}</span>
|
|
|
- </el-tag>
|
|
|
- </template>
|
|
|
- <template #header>
|
|
|
+ scope.row[`${item.tagCode}`] || '--'
|
|
|
+ }}</span>
|
|
|
+ </el-tag>
|
|
|
+ </template>
|
|
|
+ <template #header>
|
|
|
|
|
|
- <div v-if="item.valueUnit">
|
|
|
- <div >{{ item.tagName }}</div>
|
|
|
- <div >({{ item.valueUnit ? item.valueUnit : '--' }})</div>
|
|
|
- </div>
|
|
|
- <div v-else>
|
|
|
- <div style="line-height: 50px">{{ item.tagName }}</div>
|
|
|
+ <div v-if="item.valueUnit">
|
|
|
+ <div>{{ item.tagName }}</div>
|
|
|
+ <div>({{ item.valueUnit ? item.valueUnit : '--' }})</div>
|
|
|
+ </div>
|
|
|
+ <div v-else>
|
|
|
+ <div style="line-height: 50px">{{ item.tagName }}</div>
|
|
|
|
|
|
- </div>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
|
|
|
- </el-table>
|
|
|
- <dialog-check ref="tagChild"></dialog-check>
|
|
|
+ </el-table>
|
|
|
+
|
|
|
+ <dialog-check ref="tagChild"></dialog-check>
|
|
|
+ </div >
|
|
|
|
|
|
</div>
|
|
|
+
|
|
|
+
|
|
|
<el-dialog v-model="dialogVisible" width="1200px">
|
|
|
<template #title>
|
|
|
<div class="dialog-title">
|
|
@@ -103,7 +117,7 @@
|
|
|
<div class="title">选择指标(<span class="count"> {{ checkList.length }} </span>)</div>
|
|
|
</div>
|
|
|
</template>
|
|
|
- <div class="dialog-body" >
|
|
|
+ <div class="dialog-body">
|
|
|
<img class="dialog-img" src="/img/images/dialog.png"/>
|
|
|
<!-- <div class="targetNav" v-if="moreTargetData.length>1">-->
|
|
|
<!-- <ul>-->
|
|
@@ -112,10 +126,11 @@
|
|
|
<!-- </ul>-->
|
|
|
<!-- </div>-->
|
|
|
<div class="box">
|
|
|
- <div v-for="(item1,index1) in moreTargetData" :key="index1" >
|
|
|
+ <div v-for="(item1,index1) in moreTargetData" :key="index1">
|
|
|
<el-row class="headerTitle">{{ item1.unitName }}</el-row>
|
|
|
<el-checkbox-group v-model="checkList">
|
|
|
- <el-checkbox v-for="(item2,index2) in item1.data" :key="index2" :label="item2.tagName"></el-checkbox>
|
|
|
+ <el-checkbox v-for="(item2,index2) in item1.data" :key="index2"
|
|
|
+ :label="item2.tagName"></el-checkbox>
|
|
|
</el-checkbox-group>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -141,8 +156,8 @@
|
|
|
GetDataTargetsByStationType
|
|
|
} from '@/api/factoryMonitor'
|
|
|
import {GetRtValuesByTagName} from "@api/stateMonitor";
|
|
|
- import {GetPowerstationTypeList,GetEquipmentTypesInfoByStationCode} from "../../../../../../../api/factoryMonitor";
|
|
|
-import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
+ import {GetPowerstationTypeList, GetEquipmentTypesInfoByStationCode} from "../../../../../../../api/factoryMonitor";
|
|
|
+ import {rtDataRefreshTime} from "../../../../../../../config";
|
|
|
|
|
|
export default {
|
|
|
name: 'lightDataTarget',
|
|
@@ -159,7 +174,7 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
loading: false,
|
|
|
SBMC: 'SBMC',
|
|
|
SBAMC: 'SBAMC',
|
|
|
- TargetData:[],
|
|
|
+ TargetData: [],
|
|
|
SBXH: 'SBXH',
|
|
|
tagCode: '',
|
|
|
indexes: 0,
|
|
@@ -197,25 +212,30 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
cilent: '',
|
|
|
pageSize: 25,
|
|
|
stationDatasd: [],
|
|
|
- titleCode:'',
|
|
|
- winduniformCode:null,
|
|
|
- downName:'',
|
|
|
- downType:'',
|
|
|
- name:'',
|
|
|
- tagscode:'',
|
|
|
- dialogTime:''
|
|
|
+ titleCode: '',
|
|
|
+ winduniformCode: null,
|
|
|
+ downName: '',
|
|
|
+ downType: '',
|
|
|
+ name: '',
|
|
|
+ tagscode: '',
|
|
|
+ dialogTime: '',
|
|
|
+ noData:0
|
|
|
|
|
|
}
|
|
|
},
|
|
|
- async created() {
|
|
|
- this.loading=true;
|
|
|
- this.$nextTick(() => this.addRollListener())
|
|
|
+ created() {
|
|
|
+ setTimeout(() => {
|
|
|
+ this.$nextTick(() => this.addRollListener())
|
|
|
+ }, 100)
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ this.loading = true;
|
|
|
+
|
|
|
|
|
|
},
|
|
|
mounted() {
|
|
|
- this.timer = setInterval(() => {
|
|
|
- this.dataHandler();
|
|
|
- }, rtDataRefreshTime)
|
|
|
+
|
|
|
},
|
|
|
unmounted() {
|
|
|
clearInterval(this.timer);
|
|
@@ -224,24 +244,24 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
methods: {
|
|
|
|
|
|
|
|
|
- getHeaderNum(val,stationCode){
|
|
|
- this.headerIndex=val
|
|
|
+ getHeaderNum(val, stationCode) {
|
|
|
+ this.headerIndex = val
|
|
|
this.stationCode = stationCode;
|
|
|
this.getSystemConfigData()
|
|
|
|
|
|
},
|
|
|
|
|
|
- async getList(){
|
|
|
- let data = window.localStorage.getItem('alllocalTarge'+ this.titleCode);
|
|
|
+ async getList() {
|
|
|
+ let data = window.localStorage.getItem('alllocalTarge' + this.titleCode);
|
|
|
if (data != null && JSON.stringify(data) != "{}") {
|
|
|
data = JSON.parse(data);
|
|
|
this.uniformDetial = data;
|
|
|
|
|
|
- }else {
|
|
|
+ } else {
|
|
|
const result = await this.getDefaultUniformCodesList();
|
|
|
var newArr = [];
|
|
|
|
|
|
- if(result!=null && JSON.stringify(result)!='{}') {
|
|
|
+ if (result != null && JSON.stringify(result) != '{}') {
|
|
|
result.forEach(item => {
|
|
|
newArr.push({...item, width: ''});
|
|
|
})
|
|
@@ -252,7 +272,7 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
valueUnit: '',
|
|
|
width: '150'
|
|
|
}, ...newArr];
|
|
|
- window.localStorage.setItem('alllocalTarge'+ this.titleCode, JSON.stringify(this.uniformDetial));
|
|
|
+ window.localStorage.setItem('alllocalTarge' + this.titleCode, JSON.stringify(this.uniformDetial));
|
|
|
}
|
|
|
|
|
|
var arr = [];
|
|
@@ -262,35 +282,34 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
}
|
|
|
})
|
|
|
const codeStr = arr.join(',')
|
|
|
- this.winduniformCode=codeStr
|
|
|
+ this.winduniformCode = codeStr
|
|
|
await this.getCompanyEquipmentsIndicator();
|
|
|
},
|
|
|
|
|
|
// 点击title
|
|
|
- changeTitle(index,type){
|
|
|
- this.stationData=[]
|
|
|
- this.headerIndex=index
|
|
|
- this.titleCode=type.type
|
|
|
- this.downType=type.name
|
|
|
+ changeTitle(index, type) {
|
|
|
+ this.stationData = []
|
|
|
+ this.headerIndex = index
|
|
|
+ this.titleCode = type.type
|
|
|
+ this.downType = type.name
|
|
|
this.getList()
|
|
|
},
|
|
|
// 导出
|
|
|
|
|
|
- downXlsxFn(){
|
|
|
- this.stationData=this.stationDatasd
|
|
|
+ downXlsxFn() {
|
|
|
+ this.stationData = this.stationDatasd
|
|
|
let headers = []
|
|
|
this.uniformDetial.forEach(it => {
|
|
|
- if(it.valueUnit!=''){
|
|
|
- headers.push(it.tagName +'(' + it.valueUnit +')')
|
|
|
- }else {
|
|
|
- headers.push(it.tagName )
|
|
|
+ if (it.valueUnit != '') {
|
|
|
+ headers.push(it.tagName + '(' + it.valueUnit + ')')
|
|
|
+ } else {
|
|
|
+ headers.push(it.tagName)
|
|
|
}
|
|
|
})
|
|
|
|
|
|
-
|
|
|
setTimeout(() => {
|
|
|
if (this.stationData.length > 0) {
|
|
|
- utils.exportExcel(this.$refs['multipleTable'].$el, '序号' +headers , this.downName+this.downType)
|
|
|
+ utils.exportExcel(this.$refs['multipleTable'].$el, '序号' + headers, this.downName + this.downType)
|
|
|
}
|
|
|
}, 1000)
|
|
|
|
|
@@ -299,43 +318,40 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
// 滚动条监听
|
|
|
addRollListener() {
|
|
|
const dom = document.getElementsByClassName("el-table__body-wrapper")[0]
|
|
|
- dom.addEventListener('scroll', () => {
|
|
|
- const scrollTop = dom.scrollTop
|
|
|
- const offsetHeight = dom.offsetHeight
|
|
|
- const clientHeight = dom.clientHeight
|
|
|
- const scrollHeight = dom.scrollHeight
|
|
|
-
|
|
|
- if (clientHeight + scrollTop + 1 > scrollHeight || offsetHeight + scrollTop >= scrollHeight) {
|
|
|
- this.pageSize++
|
|
|
- let ss=this.deepClone(this.stationDatasd)
|
|
|
-
|
|
|
- this.stationData = ss.splice(0, this.pageSize)
|
|
|
- }
|
|
|
- })
|
|
|
+ if(dom){
|
|
|
+ dom.addEventListener('scroll', () => {
|
|
|
+ const scrollTop = dom.scrollTop
|
|
|
+ const offsetHeight = dom.offsetHeight
|
|
|
+ const clientHeight = dom.clientHeight
|
|
|
+ const scrollHeight = dom.scrollHeight
|
|
|
+
|
|
|
+ if (clientHeight + scrollTop + 1 > scrollHeight || offsetHeight + scrollTop+1 >= scrollHeight) {
|
|
|
+ this.pageSize+=10
|
|
|
+ let ss = this.deepClone(this.stationDatasd)
|
|
|
+ this.stationData = ss.splice(0, this.pageSize)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
},
|
|
|
- async getSystemConfigData(){
|
|
|
- const data=await GetEquipmentTypesInfoByStationCode({stationCode:this.stationCode })
|
|
|
-
|
|
|
- if(data){
|
|
|
+ async getSystemConfigData() {
|
|
|
+ const data = await GetEquipmentTypesInfoByStationCode({stationCode: this.stationCode})
|
|
|
+ if (data && data.length > 0) {
|
|
|
+ this.TargetData = data
|
|
|
+ this.titleCode = data[0].type
|
|
|
+ this.downType = data[0].name
|
|
|
|
|
|
- this.TargetData=data
|
|
|
- this.titleCode=data[0].type
|
|
|
- this.downType=data[0].name
|
|
|
- this.getList()
|
|
|
+ }else {
|
|
|
+ this.noData=1
|
|
|
+ this.TargetData = data
|
|
|
+ this.titleCode=''
|
|
|
+ this.downType=''
|
|
|
}
|
|
|
+ this.getList()
|
|
|
},
|
|
|
|
|
|
|
|
|
- v(tagCode, index, tagName,name,de) {
|
|
|
- if(de !=='') {
|
|
|
-
|
|
|
- this.cilent = process.env.VUE_APP_DIALOG_POINT;
|
|
|
-
|
|
|
- this.tagscode = name.CZBM
|
|
|
-
|
|
|
- this.$refs.tagChild.getXY(tagCode, tagName.tagName, de, name.SBMC, name[tagCode + 'date'])
|
|
|
-
|
|
|
- } else {
|
|
|
+ v(tagCode, index, tagName, name, de) {
|
|
|
+ if (de === '' || de === undefined) {
|
|
|
this.$message({
|
|
|
type: 'warning',
|
|
|
offset: 200,
|
|
@@ -344,49 +360,57 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
message: '指标测点为空'
|
|
|
});
|
|
|
|
|
|
+
|
|
|
+ } else {
|
|
|
+
|
|
|
+ this.cilent = process.env.VUE_APP_DIALOG_POINT;
|
|
|
+
|
|
|
+ this.tagscode = name.CZBM
|
|
|
+
|
|
|
+ this.$refs.tagChild.getXY(tagCode, tagName.tagName, de, name.SBMC, name[tagCode + 'date'])
|
|
|
}
|
|
|
event.preventDefault();
|
|
|
},
|
|
|
async renderData(stationCode) {
|
|
|
- this.headerIndex=0
|
|
|
+ this.headerIndex = 0
|
|
|
this.getSystemConfigData()
|
|
|
this.stationCode = stationCode;
|
|
|
|
|
|
},
|
|
|
//获取默认指标
|
|
|
- async getDefaultUniformCodesList(){
|
|
|
+ async getDefaultUniformCodesList() {
|
|
|
let type = this.stationType == -2 ? 'G' : 'F'
|
|
|
- const datas =await GetDataTargetsByStationType({
|
|
|
- type:type,
|
|
|
+ const datas = await GetDataTargetsByStationType({
|
|
|
+ type: type,
|
|
|
|
|
|
});
|
|
|
- const data=await GetDefaultUniformCodesList({stationType:type,eqType:this.titleCode});
|
|
|
+ const data = await GetDefaultUniformCodesList({stationType: type, eqType: this.titleCode});
|
|
|
return data;
|
|
|
},
|
|
|
async getCompanyEquipmentsIndicator() {
|
|
|
- if(this.stationCode){
|
|
|
+ if (this.stationCode) {
|
|
|
|
|
|
//获取带有编码的数据
|
|
|
const data = await GetCompanyEquipmentsIndicator({
|
|
|
powerStationCode: this.stationCode,
|
|
|
uniformCode: this.winduniformCode,
|
|
|
- eqType:this.titleCode
|
|
|
+ eqType: this.titleCode
|
|
|
});
|
|
|
- if(data){
|
|
|
- this.downName=data.CZAMC
|
|
|
- this.tableData= data.sbLists;
|
|
|
+ if (data) {
|
|
|
+ this.downName = data.CZAMC
|
|
|
+ this.tableData = data.sbLists;
|
|
|
this.dataHandler();
|
|
|
}
|
|
|
|
|
|
- }else {
|
|
|
+ } else {
|
|
|
|
|
|
- this.stationData=[];
|
|
|
+ this.stationData = [];
|
|
|
}
|
|
|
},
|
|
|
//数据处理
|
|
|
async dataHandler() {
|
|
|
-
|
|
|
- if(this.tableData){
|
|
|
+ clearInterval(this.timer);
|
|
|
+ if (this.tableData) {
|
|
|
//属性抽提
|
|
|
|
|
|
let tempData = this.tableData?.flatMap(s => {
|
|
@@ -402,17 +426,20 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
//字符拼接处理
|
|
|
let tempDataStr = tempData.join("|");
|
|
|
//获取编码对应的数据
|
|
|
- const dataArr=await GetRtValuesByTagName(tempDataStr);
|
|
|
+ const dataArr = await GetRtValuesByTagName(tempDataStr);
|
|
|
if (dataArr) {
|
|
|
|
|
|
this.codeValur = dataArr;
|
|
|
}
|
|
|
-
|
|
|
+ this.timer = setTimeout(() => {
|
|
|
+ this.dataHandler();
|
|
|
+ }, rtDataRefreshTime)
|
|
|
this.codeToValue();
|
|
|
}
|
|
|
+
|
|
|
},
|
|
|
// 将编码转化为数据
|
|
|
- async codeToValue(){
|
|
|
+ async codeToValue() {
|
|
|
let map = new Map();
|
|
|
let maps = new Map();
|
|
|
if (JSON.stringify(this.codeValur) != "{}") {
|
|
@@ -423,22 +450,22 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
}
|
|
|
|
|
|
|
|
|
- const datas=this.deepClone(this.tableData)
|
|
|
+ const datas = this.deepClone(this.tableData)
|
|
|
await datas.forEach(z => {
|
|
|
const codeArr = this.winduniformCode.split(',')
|
|
|
codeArr.forEach(code => {
|
|
|
// z[code]=map.get(z[code]);
|
|
|
let result = map.get(z[code]);
|
|
|
let results = maps.get(z[code]);
|
|
|
- if (result == undefined || result==undefined) {
|
|
|
- z[code+'value'] = '--'
|
|
|
- z[code+'date'] = '--'
|
|
|
+ if (result == undefined || result == undefined) {
|
|
|
+ z[code + 'value'] = '--'
|
|
|
+ z[code + 'date'] = '--'
|
|
|
} else if (typeof result == 'number') {
|
|
|
- z[code+'value'] = result.toFixed(2);
|
|
|
- z[code+'date'] = results;
|
|
|
+ z[code + 'value'] = result.toFixed(2);
|
|
|
+ z[code + 'date'] = results;
|
|
|
} else {
|
|
|
- z[code+'value'] = '--'
|
|
|
- z[code+'date'] = '--';
|
|
|
+ z[code + 'value'] = '--'
|
|
|
+ z[code + 'date'] = '--';
|
|
|
}
|
|
|
})
|
|
|
});
|
|
@@ -460,11 +487,11 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
return {'backdrop-filter': 'blur(10px)', 'padding': '7px 0', 'font-size': '13px'}
|
|
|
}
|
|
|
},
|
|
|
- headerStyle({row, column, rowIndex, columnIndex}){
|
|
|
- if (columnIndex < 3){
|
|
|
- return {'backdrop-filter': 'blur(10px)','padding':'6px 0'}
|
|
|
- }else {
|
|
|
- return {'padding':'6px 0'}
|
|
|
+ headerStyle({row, column, rowIndex, columnIndex}) {
|
|
|
+ if (columnIndex < 3) {
|
|
|
+ return {'backdrop-filter': 'blur(10px)', 'padding': '6px 0'}
|
|
|
+ } else {
|
|
|
+ return {'padding': '6px 0'}
|
|
|
}
|
|
|
},
|
|
|
// 添加指标,数据回填
|
|
@@ -476,9 +503,13 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
//获取风机或者光伏的全部指标
|
|
|
async getMoreUniformCodesList() {
|
|
|
let type = this.stationType == -2 ? 'G' : 'F'
|
|
|
- const data = await GetMoreUniformCodesList({stationType: type, pointType: 'AI',eqType:this.titleCode});
|
|
|
+ const data = await GetMoreUniformCodesList({
|
|
|
+ stationType: type,
|
|
|
+ pointType: 'AI',
|
|
|
+ eqType: this.titleCode
|
|
|
+ });
|
|
|
this.moreTargetData = data;
|
|
|
- this.checkList=this.winduniformName;
|
|
|
+ this.checkList = this.winduniformName;
|
|
|
|
|
|
},
|
|
|
//点击确定,将checkList文字转为编码
|
|
@@ -500,25 +531,30 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
return arr == value.tagName
|
|
|
})
|
|
|
|
|
|
- if(obj!=undefined){
|
|
|
- if(newArr.length>13){
|
|
|
+ if (obj != undefined) {
|
|
|
+ if (newArr.length > 13) {
|
|
|
obj.width = '120';
|
|
|
- }else {
|
|
|
- obj.width='';
|
|
|
+ } else {
|
|
|
+ obj.width = '';
|
|
|
}
|
|
|
code.push(obj.tagCode);
|
|
|
codeDetial.push(obj);
|
|
|
}
|
|
|
|
|
|
})
|
|
|
- this.uniformDetial = [{tagName: '设备名称', tagCode: 'SBAMC',valueUnit:'' ,width: '100'}, {tagName: '设备型号', tagCode: 'SBXH',valueUnit:'', width: '150'}, ...codeDetial];
|
|
|
- window.localStorage.setItem('alllocalTarge'+ this.titleCode, JSON.stringify(this.uniformDetial));
|
|
|
+ this.uniformDetial = [{
|
|
|
+ tagName: '设备名称',
|
|
|
+ tagCode: 'SBAMC',
|
|
|
+ valueUnit: '',
|
|
|
+ width: '100'
|
|
|
+ }, {tagName: '设备型号', tagCode: 'SBXH', valueUnit: '', width: '150'}, ...codeDetial];
|
|
|
+ window.localStorage.setItem('alllocalTarge' + this.titleCode, JSON.stringify(this.uniformDetial));
|
|
|
this.dialogVisible = false;
|
|
|
- this.tableShow=false;
|
|
|
- setTimeout(()=>{
|
|
|
- this.tableShow=true
|
|
|
- },100)
|
|
|
- await this.getList()
|
|
|
+ this.tableShow = false;
|
|
|
+ setTimeout(() => {
|
|
|
+ this.tableShow = true
|
|
|
+ }, 100)
|
|
|
+ await this.getList()
|
|
|
|
|
|
|
|
|
},
|
|
@@ -533,7 +569,7 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
winduniformCode() {
|
|
|
|
|
|
},
|
|
|
- winduniformName(){
|
|
|
+ winduniformName() {
|
|
|
var arr = [];
|
|
|
this.uniformDetial.forEach((item, index) => {
|
|
|
if (index > 1) {
|
|
@@ -544,13 +580,22 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
}
|
|
|
|
|
|
},
|
|
|
- watch:{
|
|
|
- }
|
|
|
+ watch: {}
|
|
|
}
|
|
|
</script>
|
|
|
|
|
|
<style lang="less" scoped>
|
|
|
+ .empty-data {
|
|
|
+ position: absolute;
|
|
|
+ width:calc(100% - 170px);
|
|
|
+ height: 955px;
|
|
|
+ display: flex;
|
|
|
+ justify-content: center;
|
|
|
+ align-items: center;
|
|
|
+ text-align: center;
|
|
|
|
|
|
+ padding: 5px;
|
|
|
+ }
|
|
|
.updownTits {
|
|
|
|
|
|
padding: 0 !important;
|
|
@@ -567,6 +612,7 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
background: linear-gradient(180deg, rgba(255, 255, 255, .5), rgba(0, 0, 0, .5), rgba(0, 0, 0, 1));
|
|
|
|
|
|
}
|
|
|
+
|
|
|
.el-tag {
|
|
|
background: none !important;
|
|
|
border: none !important;
|
|
@@ -632,7 +678,7 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
|
|
|
.systemData {
|
|
|
width: 100%;
|
|
|
- height: calc(100% - 70px);
|
|
|
+ height: 950px;
|
|
|
background-color: rgba(0, 0, 0, 0.45);
|
|
|
padding: 5px;
|
|
|
overflow: hidden;
|
|
@@ -643,44 +689,51 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
position: absolute;
|
|
|
right: 20px;
|
|
|
bottom: 5px;
|
|
|
- .el-button:first-child{
|
|
|
- background-color: rgba(0, 70, 199, 0.2)!important;
|
|
|
+
|
|
|
+ .el-button:first-child {
|
|
|
+ background-color: rgba(0, 70, 199, 0.2) !important;
|
|
|
color: #B3B3B3;
|
|
|
border-color: transparent;
|
|
|
}
|
|
|
}
|
|
|
- .targetNav{
|
|
|
- >ul{
|
|
|
+
|
|
|
+ .targetNav {
|
|
|
+ > ul {
|
|
|
display: flex;
|
|
|
border: 1px solid rgba(42, 55, 79, 1);
|
|
|
height: 30px;
|
|
|
border-radius: 15px;
|
|
|
width: fit-content;
|
|
|
margin: 0 auto;
|
|
|
- li{
|
|
|
+
|
|
|
+ li {
|
|
|
padding: 0 36px;
|
|
|
color: #B3B3B3;
|
|
|
font-size: 13px;
|
|
|
line-height: 28px;
|
|
|
background-color: rgba(67, 81, 107, 0.2);
|
|
|
border-right: 1px solid #2A374F;
|
|
|
- cursor:pointer;
|
|
|
+ cursor: pointer;
|
|
|
}
|
|
|
- li:first-child{
|
|
|
+
|
|
|
+ li:first-child {
|
|
|
border-top-left-radius: 15px;
|
|
|
border-bottom-left-radius: 15px;
|
|
|
}
|
|
|
- li:last-child{
|
|
|
+
|
|
|
+ li:last-child {
|
|
|
border-top-right-radius: 15px;
|
|
|
border-bottom-right-radius: 15px;
|
|
|
border: none;
|
|
|
}
|
|
|
}
|
|
|
- .active{
|
|
|
+
|
|
|
+ .active {
|
|
|
background-color: rgba(0, 70, 199, 0.4);
|
|
|
color: #FFFFFF;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
ul {
|
|
|
display: flex;
|
|
|
border: 1px solid rgba(42, 55, 79, 1);
|
|
@@ -709,16 +762,19 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
border: none;
|
|
|
}
|
|
|
}
|
|
|
- .active{
|
|
|
+
|
|
|
+ .active {
|
|
|
background-color: rgba(0, 70, 199, 0.4);
|
|
|
color: #FFFFFF;
|
|
|
}
|
|
|
- .box{
|
|
|
+
|
|
|
+ .box {
|
|
|
height: 500px;
|
|
|
overflow: auto;
|
|
|
margin: 10px 0;
|
|
|
padding: 0 10px;
|
|
|
- .headerTitle{
|
|
|
+
|
|
|
+ .headerTitle {
|
|
|
width: 100%;
|
|
|
border-bottom: 1px solid #3A3F43;
|
|
|
padding: 9px 0;
|
|
@@ -727,7 +783,8 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
position: relative;
|
|
|
margin-bottom: 8px;
|
|
|
}
|
|
|
- .headerTitle:before{
|
|
|
+
|
|
|
+ .headerTitle:before {
|
|
|
content: '';
|
|
|
display: block;
|
|
|
width: 8px;
|
|
@@ -736,7 +793,8 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
position: absolute;
|
|
|
bottom: -1px;
|
|
|
}
|
|
|
- .headerTitle::after{
|
|
|
+
|
|
|
+ .headerTitle::after {
|
|
|
content: '';
|
|
|
display: block;
|
|
|
width: 8px;
|
|
@@ -747,6 +805,7 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
right: 0;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
.count {
|
|
|
color: #fff;
|
|
|
}
|
|
@@ -754,6 +813,7 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
.el-checkbox {
|
|
|
width: 150px;
|
|
|
}
|
|
|
+
|
|
|
.line {
|
|
|
display: flex;
|
|
|
flex-direction: row;
|
|
@@ -797,7 +857,8 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
cursor: pointer;
|
|
|
background: url("../../../../../../../assets/img/images/buttonBack.png") no-repeat;
|
|
|
background-size: cover;
|
|
|
- i{
|
|
|
+
|
|
|
+ i {
|
|
|
font-size: 18px;
|
|
|
margin-right: 5px;
|
|
|
vertical-align: -1%;
|
|
@@ -806,9 +867,10 @@ import { rtDataRefreshTime } from "../../../../../../../config";
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- /deep/ .el-table__header .anames .cell{
|
|
|
+ /deep/ .el-table__header .anames .cell {
|
|
|
line-height: 50px;
|
|
|
}
|
|
|
+
|
|
|
.buttons {
|
|
|
background: rgba(67, 81, 107, 0.3) !important;
|
|
|
border: 1px solid #3B4C6C;
|