From 653c01cec2db31645d6b4f9cd7d50f8c0e291548 Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Thu, 15 Oct 2020 17:47:13 +0800 Subject: [PATCH] =?UTF-8?q?=E7=AB=9E=E8=B5=9B=E7=BB=93=E6=9E=9C=E5=BC=B9?= =?UTF-8?q?=E7=AA=97=E4=BB=A3=E7=A0=81=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../displayNew/dispatherContest/index.vue | 17 +- .../displayNew/dispatherContest/sceneList.vue | 8 +- .../dispatherContest/testResult.vue | 265 ++++++++++++++++++ 3 files changed, 284 insertions(+), 6 deletions(-) create mode 100644 src/views/newMap/displayNew/dispatherContest/testResult.vue diff --git a/src/views/newMap/displayNew/dispatherContest/index.vue b/src/views/newMap/displayNew/dispatherContest/index.vue index a75e1b8df..66592f40f 100644 --- a/src/views/newMap/displayNew/dispatherContest/index.vue +++ b/src/views/newMap/displayNew/dispatherContest/index.vue @@ -75,6 +75,8 @@ + + @@ -106,6 +108,7 @@ import { launchFullscreen } from '@/utils/screen'; import { EventBus } from '@/scripts/event-bus'; import { createSimulationNew } from '@/api/simulation'; import OperationalStatistic from './operationalStatistic.vue'; +import TestResult from './testResult.vue'; import Vue from 'vue'; export default { @@ -119,6 +122,7 @@ export default { TheoryExamSelect, TheoryExam, OperationalStatistic, + TestResult, // TheoryQuiz, // ThroryResult, SelectRole @@ -166,6 +170,7 @@ export default { scriptMode: ScriptMode.TEACH, mapLocation:{}, playerList:[], + actionList:[], currentPlayList:[], // formatUsedTime:'', formatScore:0, @@ -449,11 +454,12 @@ export default { // this.$refs.menuScript.initLoadPage(); // } }, - selectScript({playerList, mapLocation}) { + selectScript({playerList, mapLocation, actionList}) { this.changeScriptMode(this.scriptMode); this.isScriptLoad = true; this.playerList = playerList; this.mapLocation = mapLocation; + this.actionList = actionList; this.userRole = 'AUDIENCE'; this.$store.dispatch('training/setRoles', 'AUDIENCE'); }, @@ -466,12 +472,17 @@ export default { finishTraining() { this.isScriptRun = false; }, + showResultData(data) { + this.$refs.testResult.doShow({data:data, actionList:this.actionList}); + }, endTraining() { competitionPracticalSceneFinish(this.group, {operationStatisticVO:{}}).then(res=>{ this.isScriptRun = false; // if (this.scriptMode == ScriptMode.TEST) { - this.formatScore = res.data; - this.$messageBox('得分:' + this.formatScore); + // this.formatScore = res.data; + // this. + this.showResultData(res.data); + // this.$messageBox('得分:' + this.formatScore); // } // this.userRole = 'AUDIENCE'; // this.$store.dispatch('training/setRoles', 'AUDIENCE'); diff --git a/src/views/newMap/displayNew/dispatherContest/sceneList.vue b/src/views/newMap/displayNew/dispatherContest/sceneList.vue index ca01dc10f..cb195b5ca 100644 --- a/src/views/newMap/displayNew/dispatherContest/sceneList.vue +++ b/src/views/newMap/displayNew/dispatherContest/sceneList.vue @@ -120,6 +120,7 @@ export default { const playerList = []; EventBus.$emit('clearRunSeries'); EventBus.$emit('loadScene'); + const actionList = {}; if (res.data.memberList && res.data.memberList.length > 0) { this.form.type = ''; res.data.memberList.sort((a, b) => { @@ -128,6 +129,7 @@ export default { this.$store.dispatch('training/setMemberList', {memberList:res.data.memberList, userId:this.$store.state.user.id}); const activeMemberList = []; res.data.actionList.forEach((activeMember)=>{ + actionList[activeMember.id] = activeMember; if (!(activeMemberList.length > 0 && activeMemberList.includes(activeMember.memberId))) { activeMemberList.push(activeMember.memberId); } @@ -177,14 +179,14 @@ export default { if (res.data.mapLocation) { this.mapLocation = res.data.mapLocation; } - this.confirm(playerList); + this.confirm(playerList, actionList); } } }, - confirm(playerList) { + confirm(playerList, actionList) { // this.$store.dispatch('training/setScriptOperationType', this.operationType); // operationType:ScriptMode[this.operationType] - this.$emit('selectScript', {playerList:playerList, mapLocation:this.mapLocation}); + this.$emit('selectScript', {playerList:playerList, mapLocation:this.mapLocation, actionList:actionList}); this.doClose(); }, objectSpanMethod({ row, column, rowIndex, columnIndex }) { diff --git a/src/views/newMap/displayNew/dispatherContest/testResult.vue b/src/views/newMap/displayNew/dispatherContest/testResult.vue new file mode 100644 index 000000000..51b5e8cd4 --- /dev/null +++ b/src/views/newMap/displayNew/dispatherContest/testResult.vue @@ -0,0 +1,265 @@ + + + + +