|
@@ -33,10 +33,10 @@
|
|
|
v-for="(item, index) in stationArr"
|
|
|
:key="index"
|
|
|
>
|
|
|
- <div class="stationTitle" v-if="item[0].stationId">
|
|
|
+ <div class="stationTitle" v-if="item[0].childer[0].stationId">
|
|
|
<div class="stationName">
|
|
|
<!-- {{ getStationName(item) }} -->
|
|
|
- 测试
|
|
|
+ 风场测试场站
|
|
|
</div>
|
|
|
<div class="num">
|
|
|
<div class="jrts">接入台数</div>
|
|
@@ -89,7 +89,8 @@
|
|
|
</div>
|
|
|
<div class="stationTitle" v-else>
|
|
|
<div class="stationName">
|
|
|
- {{ getStationName(item) }}
|
|
|
+ <!-- {{ getStationName(item) }} -->
|
|
|
+ 光伏测试场站
|
|
|
</div>
|
|
|
<div class="num">
|
|
|
<div class="jrts">接入台数</div>
|
|
@@ -165,24 +166,24 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div class="block" v-if="showWh(item)">
|
|
|
- <div class="data_views_text" v-for="iv in 3" :key="iv">
|
|
|
- <div class="textsx">一期</div>
|
|
|
+ <div class="block" v-if="showWh(item[0].childer)">
|
|
|
+ <div class="data_views_text" v-for="iv in item" :key="iv">
|
|
|
+ <div class="textsx">{{ iv.text }}</div>
|
|
|
<UnpaidMatrixBlock
|
|
|
@on-click="handleDetial"
|
|
|
@choose-click="handleClick"
|
|
|
- :dataList="item"
|
|
|
+ :dataList="iv.childer"
|
|
|
>
|
|
|
</UnpaidMatrixBlock>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="block" v-else>
|
|
|
- <div class="data_views_text" v-for="iv in 3" :key="iv">
|
|
|
- <div class="textsx">一期</div>
|
|
|
+ <div class="data_views_text" v-for="iv in item" :key="iv">
|
|
|
+ <div class="textsx">{{ iv.text }}</div>
|
|
|
<UnpaidMatrixBlockPv
|
|
|
@on-click="handleDetialPv"
|
|
|
@choose-click="handleClickPv"
|
|
|
- :dataList="item"
|
|
|
+ :dataList="iv.childer"
|
|
|
>
|
|
|
</UnpaidMatrixBlockPv>
|
|
|
</div>
|
|
@@ -233,7 +234,7 @@ export default {
|
|
|
data() {
|
|
|
return {
|
|
|
current: "all",
|
|
|
- windterbin: {},
|
|
|
+ windterbin: [],
|
|
|
stationObj: {},
|
|
|
cache: {},
|
|
|
stationArr: [],
|
|
@@ -282,7 +283,8 @@ export default {
|
|
|
mounted() {
|
|
|
this.$nextTick(() => {
|
|
|
this.stationOverviewInfosNow = dataJson.stationOverviewInfos;
|
|
|
- this.stationArr = dataJson.stationArr;
|
|
|
+ this.stationArr = dataJson.stationArrQ;
|
|
|
+ this.windterbin = dataJson.windterbin;
|
|
|
});
|
|
|
},
|
|
|
methods: {
|
|
@@ -434,7 +436,7 @@ export default {
|
|
|
this.dialogVisible = true;
|
|
|
this.currentWindturbine = itm;
|
|
|
},
|
|
|
- handleClick(values) {
|
|
|
+ handleClick(values, datas) {
|
|
|
if (values.active) {
|
|
|
let showIndex = null;
|
|
|
this.chooseList.forEach((item, index) => {
|
|
@@ -446,12 +448,17 @@ export default {
|
|
|
} else {
|
|
|
this.chooseList.push(values);
|
|
|
}
|
|
|
- this.stationArr.forEach((item) => {
|
|
|
- item.forEach((val) => {
|
|
|
- if (val.windturbineId === values.windturbineId) {
|
|
|
- val.active = !val.active;
|
|
|
- }
|
|
|
- });
|
|
|
+ // this.stationArr.forEach((item) => {
|
|
|
+ // item.forEach((val) => {
|
|
|
+ // if (val.windturbineId === values.windturbineId) {
|
|
|
+ // val.active = !val.active;
|
|
|
+ // }
|
|
|
+ // });
|
|
|
+ // });
|
|
|
+ datas.forEach((val) => {
|
|
|
+ if (val.windturbineId === values.windturbineId) {
|
|
|
+ val.active = !val.active;
|
|
|
+ }
|
|
|
});
|
|
|
},
|
|
|
handleClose() {
|
|
@@ -464,7 +471,7 @@ export default {
|
|
|
this.currentWindturbinePv = item;
|
|
|
console.log("item", item);
|
|
|
},
|
|
|
- handleClickPv(values) {
|
|
|
+ handleClickPv(values, datas) {
|
|
|
if (values.active) {
|
|
|
let showIndex = null;
|
|
|
this.chooseList.forEach((item, index) => {
|
|
@@ -476,12 +483,17 @@ export default {
|
|
|
} else {
|
|
|
this.chooseList.push(values);
|
|
|
}
|
|
|
- this.stationArr.forEach((item) => {
|
|
|
- item.forEach((val) => {
|
|
|
- if (val.id === values.id) {
|
|
|
- val.active = !val.active;
|
|
|
- }
|
|
|
- });
|
|
|
+ // this.stationArr.forEach((item) => {
|
|
|
+ // item.forEach((val) => {
|
|
|
+ // if (val.id === values.id) {
|
|
|
+ // val.active = !val.active;
|
|
|
+ // }
|
|
|
+ // });
|
|
|
+ // });
|
|
|
+ datas.forEach((val) => {
|
|
|
+ if (val.id === values.id) {
|
|
|
+ val.active = !val.active;
|
|
|
+ }
|
|
|
});
|
|
|
},
|
|
|
handleClosePv() {
|
|
@@ -490,7 +502,36 @@ export default {
|
|
|
|
|
|
selectList(val) {
|
|
|
val.forEach((item) => {
|
|
|
- this.handleClick(this.windterbin[item.id]);
|
|
|
+ if (item.id.indexOf("风场") > -1) {
|
|
|
+ let data = this.windterbin.filter(
|
|
|
+ (iv) => iv.windturbineId === item.id
|
|
|
+ );
|
|
|
+ let datas = [];
|
|
|
+ this.stationArr.forEach((ic) => {
|
|
|
+ ic.forEach((iv) => {
|
|
|
+ iv.childer.forEach((ib) => {
|
|
|
+ if (ib.windturbineId === data[0].windturbineId) {
|
|
|
+ datas = iv.childer;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ });
|
|
|
+ });
|
|
|
+ this.handleClick(data[0], datas);
|
|
|
+ } else {
|
|
|
+ let data = this.windterbin.filter((iv) => iv.id === item.id * 1);
|
|
|
+ let datas = [];
|
|
|
+ this.stationArr.forEach((ic) => {
|
|
|
+ ic.forEach((iv) => {
|
|
|
+ iv.childer.forEach((ib) => {
|
|
|
+ if (ib.id === data[0].id) {
|
|
|
+ datas = iv.childer;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ });
|
|
|
+ });
|
|
|
+ this.handleClickPv(data[0], datas);
|
|
|
+ }
|
|
|
+ // this.handleClick(this.windterbin[item.id]);
|
|
|
});
|
|
|
},
|
|
|
getLocks() {
|
|
@@ -1050,6 +1091,7 @@ export default {
|
|
|
letter-spacing: 5px;
|
|
|
color: #fff;
|
|
|
text-align: center;
|
|
|
+ margin-right: 10px;
|
|
|
}
|
|
|
}
|
|
|
}
|