This commit is contained in:
fan 2021-03-23 17:14:17 +08:00
commit 2f4cd5569a
3 changed files with 175 additions and 6 deletions

View File

@ -75,7 +75,7 @@
<template v-for="(item, i) in addModel.columnWidthList">
<el-table-column :key="i" :label="'列'+(i + 1)" :prop="'column'+ (i + 1)" width="140px">
<template slot-scope="scope">
<el-input v-model="addModel.tableData[scope.$index]['column'+ (i + 1)]" size="small" />
<el-input v-model="addModel.tableData[scope.$index]['column'+ (i + 1)]" size="small" type="textarea" :rows="1" />
<div style="display:flex;justify-content:space-around;align-items: center;">
<div>背景</div>
<el-color-picker v-model="addModel.tableData[scope.$index]['bg'+(i+1)]" size="small" show-alpha />

View File

@ -0,0 +1,164 @@
<template>
<div v-loading="loading" element-loading-background="rgba(0, 0, 0, 0.6)" style="width:100%;height:100%;">
<div class="fasIndex" :style="{'background':bacground}">
<div class="fasIndex_header">{{ title }}</div>
<div>
<iscsSystem ref="iscsPlate" />
</div>
<!-- <div class="psdSystem_footer">
<div class="prevButton">{{}}</div>
<div class="nextButton">{{}}</div>
</div> -->
</div>
</div>
</template>
<script>
import iscsSystem from '../canvas/iscsCanvas';
import {getIscsData} from '@/api/iscs';
export default {
name:'Fas',
components:{
iscsSystem
},
data() {
return {
title:'',
bacground:'rgba(0,0,0,0)',
loading:false,
width:window.innerWidth,
scaleRate:window.innerWidth / 2200,
height: 1000
};
},
computed:{
stationName() {
return this.$route.query.stationName;
},
stationId() {
return this.$route.query.stationId;
}
// height() {
// return 970;
// }
},
watch:{
$route() {
this.mode = this.$route.params.mode;
this.getInitData();
}
},
created() {
this.mode = this.$route.params.mode;
},
mounted() {
this.getInitData();
},
methods:{
getInitData() {
const params = {
// lineCode: this.$route.query.lineCode,
mapId: this.$route.query.mapId,
system: 'fas',
totalSystem :'fas02',
userInterface : this.mode
};
if (this.mode == 'gas') {
this.title = this.stationName + ' 气体灭火系统';
this.scaleRate = window.innerWidth / 1920;
this.height = 970;
} else if (this.mode == 'sensing') {
this.title = '';
this.scaleRate = window.innerWidth / 1920;
this.height = 900;
} else if (this.mode == 'section') {
this.title = this.stationName + ' 火灾报警系统 区间层';
this.scaleRate = window.innerWidth / 1920;
this.height = 900;
} else if (this.mode == 'linkage') {
this.title = this.stationName + ' 火灾报警系统 FAS联动';
this.scaleRate = window.innerWidth / 1920;
this.height = 900;
}
// if (this.stationId == 'mainHouseOne' || this.stationId == 'mainHouseTwo') {
// this.bacground = 'rgba(0,0,0,0)';
// this.scaleRate = window.innerWidth / 2200;
// // if (this.stationId == 'mainHouseOne') {
// // //
// // this.title = '1线';
// // } else {
// // //
// // this.title = '2线';
// // }
// params.userInterface = 'substation';
// // parkingLotName
// // stationDepotName
// } else if (this.stationId == 'controlCenter') {
// this.title = '';
// this.bacground = '#000';
// this.scaleRate = window.innerWidth / 2000;
// params.userInterface = 'hybrid';
// } else if (this.stationId == 'parkingLot') {
// this.title = '';
// this.scaleRate = window.innerWidth / 2000;
// this.bacground = 'rgba(0,0,0,0)';
// params.userInterface = 'catenary';
// } else if (this.stationId == 'stationDepot') {
// this.title = '';
// this.bacground = 'rgba(0,0,0,0)';
// this.scaleRate = window.innerWidth / 2000;
// params.userInterface = 'catenary';
// } else {
// const tractionList = ['', '', '', '', '', '', '', '', '', '', '', ''];
// if (tractionList.includes(this.stationName)) {
// this.title = this.stationName + ' 线';
// if (this.stationName == '') {
// params.userInterface = 'combined01';
// } else if (this.stationName == '') {
// params.userInterface = 'combined02';
// } else if (this.stationName == '') {
// params.userInterface = 'combined03';
// } else {
// params.userInterface = 'combined02';
// }
// params.system = 'combined';
// } else {
// this.title = this.stationName + ' 线';
// params.userInterface = 'stepDown';
// }
// this.scaleRate = window.innerWidth / 2000;
// this.bacground = 'rgba(0,0,0,0)';
// }
this.loading = true;
this.$refs.iscsPlate.show({}, this.width, this.height, this.scaleRate);
getIscsData(params).then(resp=>{
if (resp.data) {
this.loading = false;
const data = JSON.parse(resp.data.graphData);
this.$refs.iscsPlate.show(data, this.width, this.height, this.scaleRate);
document.querySelector('.fasIndex').scrollTop = 0;
}
});
}
}
};
</script>
<style lang="scss" scoped>
.fasIndex_header{
text-align: center;
margin-top: 15px;
color: #d8e9a5;
font-size: 25px;
}
.fasIndex{
display: inline-block;
width:100%;
height:100%;
overflow-x: hidden;
overflow-y: auto;
vertical-align: top;
}
.SubstationIn{
display: inline-block;
}
</style>

View File

@ -3,8 +3,10 @@
<psd-system v-if="mode=='psdSystem'" />
<substation v-else-if="mode=='substation'" />
<schedule v-else-if="mode=='schedule'" />
<normal v-else-if="mode=='environmentThree'" />
<normal v-else-if="mode=='environmentFour'" />
<normal v-else-if="mode.includes('environment')" />
<fas v-else-if="fasList.includes(mode)" />
<!-- environmentThree -->
<!-- <normal v-else-if="mode=='environmentFour'" />
<normal v-else-if="mode=='environmentFive'" />
<normal v-else-if="mode=='environmentSix'" />
<normal v-else-if="mode=='environmentSeven'" />
@ -13,7 +15,7 @@
<normal v-else-if="mode=='environmentTen'" />
<normal v-else-if="mode=='environmentThirteen'" />
<normal v-else-if="mode=='environmentEleven'" />
<normal v-else-if="mode=='environmentTwelve'" />
<normal v-else-if="mode=='environmentTwelve'" /> -->
<big-screen v-else-if="mode === 'signal'" />
<!-- -->
</div>
@ -23,6 +25,7 @@ import PsdSystem from './psdSystem/index.vue';
import Substation from './powerMonitor/substation.vue';
import Normal from './environment/index.vue';
import Schedule from './schedule';
import Fas from './fas/index.vue';
import BigScreen from '@/views/designPlatform/bigScreen';
import { getSimulationInfoNew } from '@/api/simulation';
import { getByGroupStationList } from '@/api/jmap/map';
@ -33,12 +36,14 @@ export default {
PsdSystem,
Substation,
Normal,
BigScreen
BigScreen,
Fas
},
data() {
return {
mode: 'index',
deviceList: []
deviceList: [],
fasList:['sensing', 'gas', 'section', 'linkage']
};
},
computed: {