西安三号线调整
This commit is contained in:
parent
18054e5001
commit
bb37c6ebbb
@ -418,6 +418,8 @@ class Jlmap {
|
|||||||
if (elem.deviceType === 'TRAIN') {
|
if (elem.deviceType === 'TRAIN') {
|
||||||
store.dispatch('map/updateTrainState', elem);
|
store.dispatch('map/updateTrainState', elem);
|
||||||
store.dispatch('map/setTrainListUpdate', elem);
|
store.dispatch('map/setTrainListUpdate', elem);
|
||||||
|
} else if (elem.deviceType === 'STAND') {
|
||||||
|
store.dispatch('map/updateStationStand', elem);
|
||||||
}
|
}
|
||||||
const oDevice = this.mapDevice[code] || deviceFactory(type, elem, this.showConfig);
|
const oDevice = this.mapDevice[code] || deviceFactory(type, elem, this.showConfig);
|
||||||
if (elem.dispose) {
|
if (elem.dispose) {
|
||||||
|
@ -344,10 +344,10 @@ export default class TrainBody extends Group {
|
|||||||
this.delayTime && this.delayTime.setStyle({textFill: this.style.Train.soonerOrLater.normalColor});
|
this.delayTime && this.delayTime.setStyle({textFill: this.style.Train.soonerOrLater.normalColor});
|
||||||
}
|
}
|
||||||
} else if (this.style.Train.soonerOrLater && this.style.Train.soonerOrLater.level === 3) {
|
} else if (this.style.Train.soonerOrLater && this.style.Train.soonerOrLater.level === 3) {
|
||||||
if (dt > 0) {
|
if (dt > 120) {
|
||||||
this.style.Train.soonerOrLater.serviceNumber && this.textTrainServer && this.textTrainServer.setStyle({textFill: this.style.Train.soonerOrLater.earlyColor});
|
this.style.Train.soonerOrLater.serviceNumber && this.textTrainServer && this.textTrainServer.setStyle({textFill: this.style.Train.soonerOrLater.earlyColor});
|
||||||
this.style.Train.soonerOrLater.trainBody && this.trainBodyBox && this.trainBodyBox.setColor({stroke: this.style.Train.soonerOrLater.earlyColor});
|
this.style.Train.soonerOrLater.trainBody && this.trainBodyBox && this.trainBodyBox.setColor({stroke: this.style.Train.soonerOrLater.earlyColor});
|
||||||
} else if (dt < 0) {
|
} else if (dt < -120) {
|
||||||
this.style.Train.soonerOrLater.serviceNumber && this.textTrainServer && this.textTrainServer.setStyle({textFill: this.style.Train.soonerOrLater.lateColor});
|
this.style.Train.soonerOrLater.serviceNumber && this.textTrainServer && this.textTrainServer.setStyle({textFill: this.style.Train.soonerOrLater.lateColor});
|
||||||
this.style.Train.soonerOrLater.trainBody && this.trainBodyBox && this.trainBodyBox.setColor({stroke: this.style.Train.soonerOrLater.lateColor});
|
this.style.Train.soonerOrLater.trainBody && this.trainBodyBox && this.trainBodyBox.setColor({stroke: this.style.Train.soonerOrLater.lateColor});
|
||||||
} else {
|
} else {
|
||||||
|
@ -25,8 +25,8 @@
|
|||||||
@change="trainTypeChange"
|
@change="trainTypeChange"
|
||||||
>
|
>
|
||||||
<el-radio :label="'PLAN'">{{ $t('menu.planTrain') }}</el-radio>
|
<el-radio :label="'PLAN'">{{ $t('menu.planTrain') }}</el-radio>
|
||||||
<el-radio :label="'MANUAL'">{{ $t('menu.headCodeTrain') }}</el-radio>
|
<el-radio :label="'HEAD'">{{ $t('menu.headCodeTrain') }}</el-radio>
|
||||||
<el-radio :label="'HEAD'" style="margin-top:5px;">{{ $t('menu.artificialTrain') }}</el-radio>
|
<el-radio :label="'MANUAL'" style="margin-top:5px;">{{ $t('menu.artificialTrain') }}</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="formModel.type == 'PLAN'" prop="serviceNumber">
|
<el-form-item v-if="formModel.type == 'PLAN'" prop="serviceNumber">
|
||||||
@ -37,14 +37,14 @@
|
|||||||
:disabled="serverNoIsDisabled"
|
:disabled="serverNoIsDisabled"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="formModel.type == 'PLAN'|| formModel.type == 'MANUAL'" :label="this.$t('menu.tripNumber')+this.$t('global.colon')" prop="tripNumber">
|
<el-form-item v-if="formModel.type == 'PLAN'|| formModel.type == 'HEAD'" :label="this.$t('menu.tripNumber')+this.$t('global.colon')" prop="tripNumber">
|
||||||
<el-input
|
<el-input
|
||||||
:id="domIdTrainNo"
|
:id="domIdTrainNo"
|
||||||
v-model="formModel.tripNumber"
|
v-model="formModel.tripNumber"
|
||||||
maxlength="4"
|
maxlength="4"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="formModel.type == 'PLAN' || formModel.type == 'MANUAL'" :label="this.$t('menu.targetCode')+this.$t('global.colon')" prop="destinationCode">
|
<el-form-item v-if="formModel.type == 'PLAN' || formModel.type == 'HEAD'" :label="this.$t('menu.targetCode')+this.$t('global.colon')" prop="destinationCode">
|
||||||
<el-input
|
<el-input
|
||||||
:id="domIdTargetCode"
|
:id="domIdTargetCode"
|
||||||
v-model="formModel.destinationCode"
|
v-model="formModel.destinationCode"
|
||||||
|
@ -67,10 +67,10 @@
|
|||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</div>
|
</div>
|
||||||
<div class="deviceStatus">
|
<!--<div class="deviceStatus">-->
|
||||||
<div class="holdTrainStatus">H</div>
|
<!--<div class="holdTrainStatus">H</div>-->
|
||||||
<div class="jumpStopStatus">S</div>
|
<!--<div class="jumpStopStatus">S</div>-->
|
||||||
</div>
|
<!--</div>-->
|
||||||
<station-control-convert ref="stationControlConvert" />
|
<station-control-convert ref="stationControlConvert" />
|
||||||
<password-box ref="passwordBox" @setLoginResult="getLoginResult" />
|
<password-box ref="passwordBox" @setLoginResult="getLoginResult" />
|
||||||
<view-train-id ref="viewTrainId" />
|
<view-train-id ref="viewTrainId" />
|
||||||
@ -698,8 +698,7 @@ export default {
|
|||||||
<style scoped rel="stylesheet/scss" lang="scss">
|
<style scoped rel="stylesheet/scss" lang="scss">
|
||||||
@import "src/styles/mixin.scss";
|
@import "src/styles/mixin.scss";
|
||||||
$width: 30px;
|
$width: 30px;
|
||||||
$lineHeight: 30px;
|
$height:30px;
|
||||||
$height:74px;
|
|
||||||
$menuPadding: 10px;
|
$menuPadding: 10px;
|
||||||
$menuItemHeight: 30px;
|
$menuItemHeight: 30px;
|
||||||
$menuItemWidth: 190px;
|
$menuItemWidth: 190px;
|
||||||
@ -710,7 +709,7 @@ export default {
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
width: inherit;
|
width: inherit;
|
||||||
height: $height;
|
height: $height;
|
||||||
line-height: $lineHeight;
|
line-height: $height;
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav {
|
.nav {
|
||||||
|
@ -209,7 +209,11 @@ const map = {
|
|||||||
showCentralizedStationCode: '', // 现地分集中站显示(集中站code)
|
showCentralizedStationCode: '', // 现地分集中站显示(集中站code)
|
||||||
showCentralizedStationNum: 0, // 现地分集中站显示判断
|
showCentralizedStationNum: 0, // 现地分集中站显示判断
|
||||||
overlapList: [], // 延续保护list
|
overlapList: [], // 延续保护list
|
||||||
overlapData: {} // 延续保护数据
|
overlapData: {}, // 延续保护数据
|
||||||
|
holdStandList: [], // 扣车站台列表
|
||||||
|
holdStatus: false, // 是否有扣车状态
|
||||||
|
jumpStandList: [], // 跳停站台列表
|
||||||
|
jumpStatus: false // 是否有跳停状态
|
||||||
},
|
},
|
||||||
|
|
||||||
getters: {
|
getters: {
|
||||||
@ -751,6 +755,23 @@ const map = {
|
|||||||
updateTrainState:(state, status) =>{
|
updateTrainState:(state, status) =>{
|
||||||
state.map.trainList[parseInt(status.code) - 1] = deepAssign(state.map.trainList[parseInt(status.code) - 1] || {}, status);
|
state.map.trainList[parseInt(status.code) - 1] = deepAssign(state.map.trainList[parseInt(status.code) - 1] || {}, status);
|
||||||
},
|
},
|
||||||
|
updateStationStand: (state, status) => {
|
||||||
|
const holdIndex = state.holdStandList.indexOf(status.code);
|
||||||
|
const jumpIndex = state.jumpStandList.indexOf(status.code);
|
||||||
|
if ((status.stationHoldTrain || status.centerHoldTrain) && holdIndex < 0) {
|
||||||
|
state.holdStandList.push(status.code);
|
||||||
|
} else if (!(status.stationHoldTrain && status.centerHoldTrain) && holdIndex > -1) {
|
||||||
|
state.holdStandList.splice(holdIndex, 1);
|
||||||
|
}
|
||||||
|
state.holdStatus = state.holdStandList.length > 0;
|
||||||
|
if ((status.assignSkip || status.allSkip) && jumpIndex < 0) {
|
||||||
|
state.jumpStandList.push(status.code);
|
||||||
|
} else if (!(status.assignSkip && status.allSkip) && jumpIndex > -1) {
|
||||||
|
state.jumpStandList.splice(jumpIndex, 1);
|
||||||
|
}
|
||||||
|
state.jumpStatus = state.jumpStandList.length > 0;
|
||||||
|
console.log(state.jumpStatus, state.jumpStandList, state.holdStandList, state.holdStatus);
|
||||||
|
},
|
||||||
setMapVersion:(state, version) => {
|
setMapVersion:(state, version) => {
|
||||||
state.version = version;
|
state.version = version;
|
||||||
},
|
},
|
||||||
@ -819,6 +840,9 @@ const map = {
|
|||||||
updateTrainState:({ commit }, status) => {
|
updateTrainState:({ commit }, status) => {
|
||||||
commit('updateTrainState', status);
|
commit('updateTrainState', status);
|
||||||
},
|
},
|
||||||
|
updateStationStand: ({ commit }, status) => {
|
||||||
|
commit('updateStationStand', status);
|
||||||
|
},
|
||||||
getRouteDataListByCode: ({ state, commit }, code) => { // 获取进路数据
|
getRouteDataListByCode: ({ state, commit }, code) => { // 获取进路数据
|
||||||
return new Promise((resolve) => {
|
return new Promise((resolve) => {
|
||||||
const list = [];
|
const list = [];
|
||||||
|
82
src/views/components/StatusIcon/statusIcon.vue
Normal file
82
src/views/components/StatusIcon/statusIcon.vue
Normal file
@ -0,0 +1,82 @@
|
|||||||
|
<template>
|
||||||
|
<div class="icon-box" :style="{top: offset+'px'}">
|
||||||
|
<div class="textStatus" :style="{background: holdBackground}">H</div>
|
||||||
|
<div class="textStatus" :style="{background: jumpBackground}">S</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: 'StatusIcon',
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
offset: 15,
|
||||||
|
holdBackground: '#807D8E',
|
||||||
|
jumpBackground: '#807D8E'
|
||||||
|
};
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
'$store.state.map.holdStatus': function (val) {
|
||||||
|
console.log(val, '-----------');
|
||||||
|
if (val) {
|
||||||
|
this.holdBackground = '#F00';
|
||||||
|
} else {
|
||||||
|
this.holdBackground = '#807D8E';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
'$store.state.map.jumpStatus': function (val) {
|
||||||
|
if (val) {
|
||||||
|
this.jumpBackground = '#F00';
|
||||||
|
} else {
|
||||||
|
this.jumpBackground = '#807D8E';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.setPosition();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
setPosition() {
|
||||||
|
this.$nextTick(() => {
|
||||||
|
let offset = 30;
|
||||||
|
const menuBar = document.getElementById('menuBar');
|
||||||
|
const menuTool = document.getElementById('menuTool');
|
||||||
|
if (menuBar) {
|
||||||
|
offset = (menuBar.offsetHeight || 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (menuTool) {
|
||||||
|
offset = (menuTool.offsetHeight || 0);
|
||||||
|
}
|
||||||
|
if (this.offset !== offset) {
|
||||||
|
this.offset = offset;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.icon-box {
|
||||||
|
z-index: 7;
|
||||||
|
position: absolute;
|
||||||
|
left: 0;
|
||||||
|
width: 120px;
|
||||||
|
height: 58px;
|
||||||
|
background: rgb(224, 223, 223);
|
||||||
|
border-radius: 4px;
|
||||||
|
overflow: hidden;
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
.textStatus {
|
||||||
|
width: 50px;
|
||||||
|
height: 50px;
|
||||||
|
line-height: 50px;
|
||||||
|
text-align: center;
|
||||||
|
font-size: 28px;
|
||||||
|
margin: 4px;
|
||||||
|
background: #807D8E;
|
||||||
|
color: #C9A167;
|
||||||
|
}
|
||||||
|
</style>
|
@ -4,6 +4,7 @@
|
|||||||
<transition name="el-zoom-in-bottom">
|
<transition name="el-zoom-in-bottom">
|
||||||
<map-system-draft ref="mapCanvas" @back="back" />
|
<map-system-draft ref="mapCanvas" @back="back" />
|
||||||
</transition>
|
</transition>
|
||||||
|
<status-icon v-if="$route.query.lineCode == '11' || $route.query.lineCode == '10'" ref="statusIcon" />
|
||||||
<menu-exam
|
<menu-exam
|
||||||
v-if="isExam"
|
v-if="isExam"
|
||||||
ref="menuExam"
|
ref="menuExam"
|
||||||
@ -108,6 +109,7 @@ import Vue from 'vue';
|
|||||||
import LeftSlider from '@/views/newMap/displayNew/LeftSlider';
|
import LeftSlider from '@/views/newMap/displayNew/LeftSlider';
|
||||||
import { getSessionStorage } from '@/utils/auth';
|
import { getSessionStorage } from '@/utils/auth';
|
||||||
import MenuTrainList from '@/views/newMap/displayNew/menuTrainList';
|
import MenuTrainList from '@/views/newMap/displayNew/menuTrainList';
|
||||||
|
import StatusIcon from '@/views/components/StatusIcon/statusIcon';
|
||||||
|
|
||||||
// 三维
|
// 三维
|
||||||
// import Jl3dSimulation from '@/views/jlmap3d/simulation/jl3dsimulation';
|
// import Jl3dSimulation from '@/views/jlmap3d/simulation/jl3dsimulation';
|
||||||
@ -130,7 +132,8 @@ export default {
|
|||||||
Jl3dDrive,
|
Jl3dDrive,
|
||||||
Jl3dDevice,
|
Jl3dDevice,
|
||||||
Scheduling,
|
Scheduling,
|
||||||
LeftSlider
|
LeftSlider,
|
||||||
|
StatusIcon
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
size: {
|
size: {
|
||||||
|
@ -38,7 +38,7 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
setPosition() {
|
setPosition() {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
let offset = 15;
|
let offset = this.$route.path.includes('displayNew') && (this.$route.query.lineCode == 10 || this.$route.query.lineCode == 11) ? 73 : 15;
|
||||||
const menuBar = document.getElementById('menuBar');
|
const menuBar = document.getElementById('menuBar');
|
||||||
const menuTool = document.getElementById('menuTool');
|
const menuTool = document.getElementById('menuTool');
|
||||||
if (menuBar) {
|
if (menuBar) {
|
||||||
|
Loading…
Reference in New Issue
Block a user