综合演练生成仿真号&仿真界面刷新bug调整
This commit is contained in:
parent
770de3c73c
commit
2b6fa6a9f7
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div id="app">
|
<div id="app">
|
||||||
<router-view />
|
<router-view v-if="loadingComponent" />
|
||||||
<deomon-list ref="deomonList" @enterQcode="qcodeEntry" />
|
<deomon-list ref="deomonList" @enterQcode="qcodeEntry" />
|
||||||
<qcode ref="qcode" />
|
<qcode ref="qcode" />
|
||||||
<div v-show="loading" class="AppAll">
|
<div v-show="loading" class="AppAll">
|
||||||
@ -50,7 +50,8 @@ export default {
|
|||||||
appLoading: AppLoading,
|
appLoading: AppLoading,
|
||||||
loading: false,
|
loading: false,
|
||||||
jlFavicon: Favicon,
|
jlFavicon: Favicon,
|
||||||
project: ''
|
project: '',
|
||||||
|
loadingComponent: false
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@ -120,6 +121,7 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
initFrontProjectConfig() {
|
initFrontProjectConfig() {
|
||||||
getFrontProjectConfigByLogin(this.project).then(resp => {
|
getFrontProjectConfigByLogin(this.project).then(resp => {
|
||||||
|
this.loadingComponent = true;
|
||||||
const urlData = handlerUrl();
|
const urlData = handlerUrl();
|
||||||
const { baseApiUrl, baseSite, ossUrl, loginProLogo, browserTitle} = resp.data.viewSetting;
|
const { baseApiUrl, baseSite, ossUrl, loginProLogo, browserTitle} = resp.data.viewSetting;
|
||||||
this.$store.dispatch('setBaseUrl', baseApiUrl || urlData.BASE_API);
|
this.$store.dispatch('setBaseUrl', baseApiUrl || urlData.BASE_API);
|
||||||
|
BIN
src/assets/sim_id.jpg
Normal file
BIN
src/assets/sim_id.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 22 KiB |
48
src/views/newMap/display/simulationId.vue
Normal file
48
src/views/newMap/display/simulationId.vue
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
<template>
|
||||||
|
<el-dialog v-dialogDrag :title="title" :visible.sync="dialogVisible" width="350px" :before-close="done => {}" :show-close="false" center>
|
||||||
|
<div v-if="group" class="qrcodeGroup">
|
||||||
|
<span>{{ $t('global.roomId')+group }}</span>
|
||||||
|
</div>
|
||||||
|
<span slot="footer" class="dialog-footer">
|
||||||
|
<el-button @click="doClose">{{ $t('global.close') }}</el-button>
|
||||||
|
</span>
|
||||||
|
</el-dialog>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: 'SimulationId',
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
dialogVisible: false,
|
||||||
|
title: '',
|
||||||
|
loading: false,
|
||||||
|
group: ''
|
||||||
|
};
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
clearModel() {
|
||||||
|
this.title = '';
|
||||||
|
},
|
||||||
|
doShow(data) {
|
||||||
|
this.clearModel();
|
||||||
|
if (data) {
|
||||||
|
this.title = data.title;
|
||||||
|
this.dialogVisible = true;
|
||||||
|
this.group = data.group;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
doClose() {
|
||||||
|
this.dialogVisible = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.qrcodeView{text-align:center; margin:auto;}
|
||||||
|
.qrcodeGroup{text-align: center;font-size: 18px;font-weight: bold; margin-top:40px;}
|
||||||
|
/deep/ .el-dialog{
|
||||||
|
background-image: url('~@/assets/sim_id.jpg');
|
||||||
|
background-size: 100% 100%;
|
||||||
|
}
|
||||||
|
</style>
|
@ -17,11 +17,10 @@
|
|||||||
<select-exam ref="selectExam" @examStart="examStart" />
|
<select-exam ref="selectExam" @examStart="examStart" />
|
||||||
<exam-panel ref="examPanel" />
|
<exam-panel ref="examPanel" />
|
||||||
<device-manage ref="deviceManage" />
|
<device-manage ref="deviceManage" />
|
||||||
<qr-code ref="qrCode" />
|
<simulation-id ref="simulationId" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getSimulationQrcode } from '@/api/jointSimulation';
|
|
||||||
import { initSimulation } from '@/api/rtSimulation';
|
import { initSimulation } from '@/api/rtSimulation';
|
||||||
import ContectUs from './contectUs';
|
import ContectUs from './contectUs';
|
||||||
import FlowData from './flowData';
|
import FlowData from './flowData';
|
||||||
@ -32,11 +31,11 @@ import SelectExam from '../exam/selectExam';
|
|||||||
import ExamPanel from '../exam/examPanel';
|
import ExamPanel from '../exam/examPanel';
|
||||||
import getErrorTip from '@/scripts/errorTip';
|
import getErrorTip from '@/scripts/errorTip';
|
||||||
import DeviceManage from './deviceManage';
|
import DeviceManage from './deviceManage';
|
||||||
import QrCode from '@/components/QrCode';
|
|
||||||
import { SimulationUserType } from '@/scripts/ConstDic';
|
import { SimulationUserType } from '@/scripts/ConstDic';
|
||||||
import { destroySimulationByAdmin, ranAsPlan} from '@/api/simulation';
|
import { destroySimulationByAdmin, ranAsPlan} from '@/api/simulation';
|
||||||
import { EventBus } from '@/scripts/event-bus';
|
import { EventBus } from '@/scripts/event-bus';
|
||||||
import SimulationControl from './simulationControl';
|
import SimulationControl from './simulationControl';
|
||||||
|
import SimulationId from '../simulationId';
|
||||||
export default {
|
export default {
|
||||||
name: 'SimulationMenu',
|
name: 'SimulationMenu',
|
||||||
components: {
|
components: {
|
||||||
@ -48,8 +47,8 @@ export default {
|
|||||||
Jl3dDevice,
|
Jl3dDevice,
|
||||||
MemberManage,
|
MemberManage,
|
||||||
DeviceManage,
|
DeviceManage,
|
||||||
QrCode,
|
SimulationControl,
|
||||||
SimulationControl
|
SimulationId
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@ -63,7 +62,7 @@ export default {
|
|||||||
{ label: '设备视图', name: 'jlmap3dmodel', click: this.jlmap3dmodel, isDisabled: () => { return false; }, isShow: () => { return this.$route.query.client !== 'diagramEdit'; } },
|
{ label: '设备视图', name: 'jlmap3dmodel', click: this.jlmap3dmodel, isDisabled: () => { return false; }, isShow: () => { return this.$route.query.client !== 'diagramEdit'; } },
|
||||||
{ label: '设备管理', name: 'deviceManage', click: this.deviceManage, isDisabled: () => { return false; }, isShow: () => { return (this.$store.state.training.domConfig.hasDeviceManage && this.$store.state.training.simulationUserType === SimulationUserType.TEACHER) || (this.$route.query.client === 'interlockWork' && this.$route.query.projectDevice === 'ILW'); } },
|
{ label: '设备管理', name: 'deviceManage', click: this.deviceManage, isDisabled: () => { return false; }, isShow: () => { return (this.$store.state.training.domConfig.hasDeviceManage && this.$store.state.training.simulationUserType === SimulationUserType.TEACHER) || (this.$route.query.client === 'interlockWork' && this.$route.query.projectDevice === 'ILW'); } },
|
||||||
{ label: '联系方式', name: 'contectUs', click: this.contectUs, isDisabled: () => { return false; }, isShow: () => { return true; } },
|
{ label: '联系方式', name: 'contectUs', click: this.contectUs, isDisabled: () => { return false; }, isShow: () => { return true; } },
|
||||||
{ label: '生成二维码', name: 'generateQrCode', click: this.generateQrCode, isDisabled: () => { return false; }, isShow: () => { return this.$store.state.training.domConfig.joint && this.$store.state.training.simulationUserType === SimulationUserType.TEACHER; } },
|
{ label: '生成仿真号', name: 'generateQrCode', click: this.generateQrCode, isDisabled: () => { return false; }, isShow: () => { return this.$store.state.training.domConfig.joint && this.$store.state.training.simulationUserType === SimulationUserType.TEACHER; } },
|
||||||
{ label: '切换客流数据', name: 'changeFlowData', click: this.changeFlowData, isDisabled: () => { return false; }, isShow: () => { return this.$store.state.training.domConfig.hasLpf && this.$store.state.training.simulationUserType === SimulationUserType.TEACHER; } },
|
{ label: '切换客流数据', name: 'changeFlowData', click: this.changeFlowData, isDisabled: () => { return false; }, isShow: () => { return this.$store.state.training.domConfig.hasLpf && this.$store.state.training.simulationUserType === SimulationUserType.TEACHER; } },
|
||||||
{ label: '成员管理', name: 'memberManage', click: this.memberManage, isDisabled: () => { return false; }, isShow: () => { return this.$store.state.training.domConfig.hasMemberManage && this.$store.state.training.simulationUserType === SimulationUserType.TEACHER; } },
|
{ label: '成员管理', name: 'memberManage', click: this.memberManage, isDisabled: () => { return false; }, isShow: () => { return this.$store.state.training.domConfig.hasMemberManage && this.$store.state.training.simulationUserType === SimulationUserType.TEACHER; } },
|
||||||
{ label: '考试', name: 'exam', click: this.goExam, isDisabled: () => { return false; }, isShow: () => { return this.$store.state.training.domConfig.hasExam && this.$store.state.training.simulationUserType === SimulationUserType.TEACHER; } },
|
{ label: '考试', name: 'exam', click: this.goExam, isDisabled: () => { return false; }, isShow: () => { return this.$store.state.training.domConfig.hasExam && this.$store.state.training.simulationUserType === SimulationUserType.TEACHER; } },
|
||||||
@ -130,18 +129,11 @@ export default {
|
|||||||
},
|
},
|
||||||
generateQrCode() {
|
generateQrCode() {
|
||||||
this.hideMenuList();
|
this.hideMenuList();
|
||||||
getSimulationQrcode(this.$route.query.group).then(resp => {
|
|
||||||
const param = {
|
const param = {
|
||||||
url: resp.data,
|
title: this.$t('综合演练仿真号'),
|
||||||
title: this.$t('综合演练二维码'),
|
|
||||||
group: this.$route.query.group
|
group: this.$route.query.group
|
||||||
};
|
};
|
||||||
if (this.$refs) {
|
this.$refs.simulationId.doShow(param);
|
||||||
this.$refs.qrCode.doShow(param);
|
|
||||||
}
|
|
||||||
}).catch(() => {
|
|
||||||
this.$messageBox('仿真生成二维码失败!');
|
|
||||||
});
|
|
||||||
},
|
},
|
||||||
deviceManage() {
|
deviceManage() {
|
||||||
this.hideMenuList();
|
this.hideMenuList();
|
||||||
|
Loading…
Reference in New Issue
Block a user