修改三维设备界面隐藏显示
This commit is contained in:
parent
357862d2d4
commit
d973dbc46e
@ -206,29 +206,15 @@ export function Jl3ddeviceNew(dom,group,token,skinCode) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
window.onresize = function () {
|
|
||||||
|
|
||||||
// if(scope.windowstatus){
|
|
||||||
// changeelement.style.width = '50%';
|
|
||||||
// changeelement.style.height = '50%';
|
|
||||||
// changeelement.style.top = '25%';
|
|
||||||
// scope.windowstatus = false;
|
|
||||||
// scope.updatewindowstatus('0');
|
|
||||||
// }else{
|
|
||||||
scope.camera.aspect = scope.dom.offsetWidth / scope.dom.offsetHeight;
|
|
||||||
scope.camera.updateProjectionMatrix();
|
|
||||||
scope.renderer.setSize(scope.dom.offsetWidth, scope.dom.offsetHeight);
|
|
||||||
|
|
||||||
if(scope.windowstatus == "0"){
|
|
||||||
let changeelement = document.getElementById('jl3d');
|
let changeelement = document.getElementById('jl3d');
|
||||||
changeelement.style.width = '100%';
|
window.addEventListener('resize', () =>
|
||||||
changeelement.style.height = '100%';
|
onresize()
|
||||||
changeelement.style.top = '0';
|
, false)
|
||||||
scope.camera.aspect = window.innerWidth / scope.dom.offsetHeight;
|
let onresize = function () {
|
||||||
|
|
||||||
|
scope.camera.aspect = changeelement.offsetWidth / changeelement.offsetHeight;
|
||||||
scope.camera.updateProjectionMatrix();
|
scope.camera.updateProjectionMatrix();
|
||||||
scope.renderer.setSize(window.innerWidth, scope.dom.offsetHeight);
|
scope.renderer.setSize(changeelement.offsetWidth, changeelement.offsetHeight);
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -73,6 +73,10 @@ export function TrainConnect(trafficTrain,deviceaction,toptrain,routegroup,passe
|
|||||||
// jl3d.updateNowLeaveData("down",data.body.out);
|
// jl3d.updateNowLeaveData("down",data.body.out);
|
||||||
// }
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(data.type == "TRAIN_PIS"){
|
||||||
|
console.log(data);
|
||||||
|
}
|
||||||
if(data.type == "TRAIN_PFI_NUM"){
|
if(data.type == "TRAIN_PFI_NUM"){
|
||||||
|
|
||||||
trafficTrain.trainList = [];
|
trafficTrain.trainList = [];
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
</Jl3ddevice-Msg>
|
</Jl3ddevice-Msg>
|
||||||
<Jl3ddevice-List v-show="isswitch" :devicelist="devicelist" @sdevice="sdevice">
|
<Jl3ddevice-List v-show="isswitch" :devicelist="devicelist" @sdevice="sdevice">
|
||||||
</Jl3ddevice-List>
|
</Jl3ddevice-List>
|
||||||
<canvas id="canvastexture" />
|
<canvas id="canvastexture" ></canvas>
|
||||||
<div class="jl3dcontrolpane" v-show="isswitch">
|
<div class="jl3dcontrolpane" v-show="isswitch">
|
||||||
<el-button-group>
|
<el-button-group>
|
||||||
<el-button type="primary" @click="back">初始化</el-button>
|
<el-button type="primary" @click="back">初始化</el-button>
|
||||||
@ -16,7 +16,7 @@
|
|||||||
|
|
||||||
<div id="jl3dwindow" v-show="isPsd" class="windowbutton"
|
<div id="jl3dwindow" v-show="isPsd" class="windowbutton"
|
||||||
:style="{'background-image': 'url('+localStatic+'/texture/fk.png)'}"
|
:style="{'background-image': 'url('+localStatic+'/texture/fk.png)'}"
|
||||||
@click="windowchange"></div
|
@click="windowchange"></div>
|
||||||
|
|
||||||
<div id="jl3dclose" v-show="isPsd" class="backbutton"
|
<div id="jl3dclose" v-show="isPsd" class="backbutton"
|
||||||
:style="{'background-image': 'url('+localStatic+'/texture/xx.png)'}"
|
:style="{'background-image': 'url('+localStatic+'/texture/xx.png)'}"
|
||||||
|
@ -28,7 +28,8 @@
|
|||||||
</el-button-group>
|
</el-button-group>
|
||||||
</div>
|
</div>
|
||||||
<Jl3d-Device
|
<Jl3d-Device
|
||||||
v-if="deviceShow"
|
v-if="deviceif"
|
||||||
|
v-show="deviceShow"
|
||||||
ref="Jl3dDevice"
|
ref="Jl3dDevice"
|
||||||
:panel-show="deviceShow"
|
:panel-show="deviceShow"
|
||||||
@closedevice3dview="jumpjlmap3dmodel"
|
@closedevice3dview="jumpjlmap3dmodel"
|
||||||
@ -113,7 +114,8 @@ export default {
|
|||||||
mapId:'',
|
mapId:'',
|
||||||
lineCode:'',
|
lineCode:'',
|
||||||
practiceDisabled:false,
|
practiceDisabled:false,
|
||||||
deviceShow: false,
|
deviceif:false,
|
||||||
|
deviceShow: true,
|
||||||
drivingShow: false,
|
drivingShow: false,
|
||||||
jl3dtrafficplan:this.$t('display.demon.trafficplantext'),
|
jl3dtrafficplan:this.$t('display.demon.trafficplantext'),
|
||||||
jl3dtraffictrain:this.$t('display.demon.traffictraintext'),
|
jl3dtraffictrain:this.$t('display.demon.traffictraintext'),
|
||||||
@ -159,11 +161,16 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
jumpjlmap3dmodel() {
|
jumpjlmap3dmodel() {
|
||||||
|
if(this.deviceif == false){
|
||||||
|
this.deviceif = true;
|
||||||
|
}else{
|
||||||
if (this.deviceShow == false) {
|
if (this.deviceShow == false) {
|
||||||
this.deviceShow = true;
|
this.deviceShow = true;
|
||||||
} else {
|
} else {
|
||||||
this.deviceShow = false;
|
this.deviceShow = false;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
showdriving() {
|
showdriving() {
|
||||||
this.drivingShow = false;
|
this.drivingShow = false;
|
||||||
|
@ -50,7 +50,8 @@
|
|||||||
<members-manage ref="membersManage" :is-admin="isAdmin" @addSimulationMember="addSimulationMember" /> <!-- 成员管理 -->
|
<members-manage ref="membersManage" :is-admin="isAdmin" @addSimulationMember="addSimulationMember" /> <!-- 成员管理 -->
|
||||||
<add-member ref="addMember" />
|
<add-member ref="addMember" />
|
||||||
<Jl3d-Device
|
<Jl3d-Device
|
||||||
v-if="deviceShow"
|
v-if="deviceif"
|
||||||
|
v-show="deviceShow"
|
||||||
ref="Jl3dDevice"
|
ref="Jl3dDevice"
|
||||||
:panel-show="deviceShow"
|
:panel-show="deviceShow"
|
||||||
@closedevice3dview="devicemodel"
|
@closedevice3dview="devicemodel"
|
||||||
@ -124,7 +125,8 @@ export default {
|
|||||||
mapViewLoadedOver: false,
|
mapViewLoadedOver: false,
|
||||||
dataError: false,
|
dataError: false,
|
||||||
isAdmin: false,
|
isAdmin: false,
|
||||||
deviceShow: false,
|
deviceif:false,
|
||||||
|
deviceShow: true,
|
||||||
centralizedStationMap: {}
|
centralizedStationMap: {}
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
@ -175,7 +177,8 @@ export default {
|
|||||||
this.showSelectStation && this.setShowStation(this.showStation);
|
this.showSelectStation && this.setShowStation(this.showStation);
|
||||||
// this.initMemberUserInfo();
|
// this.initMemberUserInfo();
|
||||||
if (this.$route.query.type === 'VR_PSD') {
|
if (this.$route.query.type === 'VR_PSD') {
|
||||||
this.deviceShow = true;
|
this.deviceif = true;
|
||||||
|
this.deviceShow = false;
|
||||||
}
|
}
|
||||||
if (this.$route.query.type === 'DRIVE') {
|
if (this.$route.query.type === 'DRIVE') {
|
||||||
this.$store.dispatch('training/setPrdType', '04');
|
this.$store.dispatch('training/setPrdType', '04');
|
||||||
@ -292,11 +295,16 @@ export default {
|
|||||||
// });
|
// });
|
||||||
// },
|
// },
|
||||||
devicemodel() {
|
devicemodel() {
|
||||||
|
if(this.deviceif == false){
|
||||||
|
this.deviceif = true;
|
||||||
|
}else{
|
||||||
if (this.deviceShow == false) {
|
if (this.deviceShow == false) {
|
||||||
this.deviceShow = true;
|
this.deviceShow = true;
|
||||||
} else {
|
} else {
|
||||||
this.deviceShow = false;
|
this.deviceShow = false;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
/* 地图根据仿真group获取仿真基础信息 */
|
/* 地图根据仿真group获取仿真基础信息 */
|
||||||
async loadSimulationInfo() {
|
async loadSimulationInfo() {
|
||||||
|
Loading…
Reference in New Issue
Block a user