|
@@ -62,8 +62,9 @@
|
|
|
class="graph"
|
|
|
style="width: 100%; height: 100%; touch-action: none"
|
|
|
/>
|
|
|
- <div v-if="!craftShow" id="graphContainer2" :style="'background-image: url('+flowImage+')'">
|
|
|
- <template v-for="(item,key) in currentSiteList">
|
|
|
+ <!-- <div v-if="!craftShow" id="graphContainer2" :style="'background-image: url('+flowImage+')'"> -->
|
|
|
+ <div v-if="!craftShow" id="graphContainer2" :style="'background-image: url('+flowImage+');'+((currentLoadCraft=='3'||currentLoadCraft=='4')?'background-size: 60%;background-repeat: no-repeat;background-position: center;':'')">
|
|
|
+ <template v-for="(item,key) in currentSiteList">
|
|
|
<div :style="'position: absolute;left:'+item.position.x+' ; top:'+item.position.y+';'" class='siteInfo' :key="'siteInfo_'+key">
|
|
|
<template v-for="(item2,key2) in item.data">
|
|
|
<div class='siteInfoItem' @click="showHistory(item2)" :class='item2.isAlarm==0?"":"isAlarm"' :key='"siteInfoItem_"+key+""+key2'>
|
|
@@ -104,7 +105,7 @@ import { parseTime } from "@/utils/index";
|
|
|
import Echarts from "echarts";
|
|
|
import { getScadaAlarmDataPage, getScadaData } from "@/api/scada";
|
|
|
import scadaSiteCom from "@/views/zhpt/scada/scadaMonitor/components/scadaSiteCom.vue";
|
|
|
-import {siteConfigTwo,siteConfigOne,siteConfigThree} from './siteConfig';
|
|
|
+import {siteConfigTwo,siteConfigOne,siteConfigThree,qskTwo,qskOne} from './siteConfig';
|
|
|
import commonMe from '@/utils/common.js'
|
|
|
export default {
|
|
|
name: "CraftMap2",
|
|
@@ -253,6 +254,7 @@ export default {
|
|
|
const cache = {};
|
|
|
const modulesFiles = require.context("./images", true, /\.(png|gif)$/);
|
|
|
modulesFiles.keys().forEach((key) => (cache[key] = modulesFiles(key)));
|
|
|
+ debugger
|
|
|
var imagesUrl = "./";
|
|
|
var div = this.$refs.graphContainer;
|
|
|
if(div){
|
|
@@ -272,6 +274,12 @@ export default {
|
|
|
}else if(this.currentLoadCraft=='2'){
|
|
|
this.currentSiteList=siteConfigThree;
|
|
|
this.renderSiteInfo(siteConfigThree);
|
|
|
+ }else if(this.currentLoadCraft=='3'){
|
|
|
+ this.currentSiteList=qskOne;
|
|
|
+ this.renderSiteInfo(qskOne);
|
|
|
+ }else if(this.currentLoadCraft=='4'){
|
|
|
+ this.currentSiteList=qskTwo;
|
|
|
+ this.renderSiteInfo(qskTwo);
|
|
|
}
|
|
|
if(tempData.type=="image"){
|
|
|
this.craftShow=false;
|
|
@@ -640,7 +648,8 @@ export default {
|
|
|
* 获取指标内容
|
|
|
*/
|
|
|
renderSiteInfo(siteInfoList){
|
|
|
- const data = { type: 1 };
|
|
|
+ // const data = { type: 1 };
|
|
|
+ const data = { };
|
|
|
this.getScadaData(data).then(res=>{
|
|
|
const tempValue=[];
|
|
|
if(res&&res.result){
|
|
@@ -954,6 +963,7 @@ export default {
|
|
|
bottom: 0%;
|
|
|
left: 0%;
|
|
|
margin: auto;
|
|
|
+ background: black !important;
|
|
|
// #graphContainer{
|
|
|
// background-image:url("../../../assets/images/gyt.png") ;
|
|
|
// background-repeat: no-repeat;
|