监管仿真增加进入仿真
This commit is contained in:
parent
15226a3406
commit
83d1342110
@ -567,3 +567,10 @@ export function exitSimulation(group) {
|
||||
method: 'put'
|
||||
});
|
||||
}
|
||||
/** 仿真监管那里进入仿真 */
|
||||
export function enterSimulationByTeacher(group) {
|
||||
return request({
|
||||
url: `/simulation/${group}/monitor`,
|
||||
method: 'post'
|
||||
});
|
||||
}
|
||||
|
@ -72,9 +72,11 @@ export default {
|
||||
this.position = { x: 0, y: 0 };
|
||||
},
|
||||
'$store.state.training.tipEvent': function (val) {
|
||||
setTimeout(() => {
|
||||
if (this.tip) {
|
||||
setTimeout(() => { this.tipInit(); }, 10);
|
||||
this.tipInit();
|
||||
}
|
||||
}, 10);
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
@ -7,7 +7,7 @@
|
||||
<script>
|
||||
import ViewMember from './viewMember';
|
||||
import { getExistSimulationList, getSuperviseSimulation } from '@/api/rtSimulation';
|
||||
import { destroySimulationByAdmin } from '@/api/simulation';
|
||||
import { destroySimulationByAdmin, enterSimulationByTeacher } from '@/api/simulation';
|
||||
export default {
|
||||
name: 'SimulationManage',
|
||||
components: {
|
||||
@ -82,6 +82,11 @@ export default {
|
||||
handleClick: this.viewMember,
|
||||
type: ''
|
||||
},
|
||||
{
|
||||
name: '进入仿真',
|
||||
handleClick: this.enterSimulation,
|
||||
type: ''
|
||||
},
|
||||
{
|
||||
name: this.$t('system.destory'),
|
||||
handleClick: this.handleDelete,
|
||||
@ -120,6 +125,24 @@ export default {
|
||||
});
|
||||
});
|
||||
},
|
||||
enterSimulation(index, row) {
|
||||
enterSimulationByTeacher(row.id).then(resp => {
|
||||
const query = {
|
||||
lineCode: row.map.lineCode,
|
||||
group: row.id,
|
||||
mapId: row.map.id,
|
||||
simType: row.workParamVO.type,
|
||||
project: this.project
|
||||
};
|
||||
if (row.workParamVO && row.workParamVO.domConfig && row.workParamVO.domConfig.client) {
|
||||
query.client = row.workParamVO.domConfig.client;
|
||||
}
|
||||
if (row.workParamVO && row.workParamVO.domConfig && row.workParamVO.domConfig.singleClient) {
|
||||
query.singleClient = row.workParamVO.domConfig.singleClient;
|
||||
}
|
||||
this.$router.push({ path: `/display/demon`, query: query });
|
||||
});
|
||||
},
|
||||
reloadTable() {
|
||||
this.queryList.reload();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user