diff --git a/src/api/script.js b/src/api/script.js index 93bed7652..b4cc5e639 100644 --- a/src/api/script.js +++ b/src/api/script.js @@ -3,8 +3,8 @@ import request from '@/utils/request'; /** 分页查找上线的剧本*/ export function getScriptPageListOnline(params) { return request({ - // url: `/api/script/paging/online`, - url: `/api/script/paging/published`, + url: `/api/script/paging/online`, + // url: `/api/script/paging/published`, method: 'get', params: params }); diff --git a/src/api/trainingPlatform.js b/src/api/trainingPlatform.js index 0b9fe20be..d3cde2894 100644 --- a/src/api/trainingPlatform.js +++ b/src/api/trainingPlatform.js @@ -48,3 +48,12 @@ export function getSubSystemDetail(id) { method: 'get' }); } + +export function getMapSystemPageList(params) { + /** 分页查询地图系统 */ + return request({ + url: `/api/mapSystem`, + method: 'get', + params + }); +} diff --git a/src/i18n/langs/en/index.js b/src/i18n/langs/en/index.js index f55c5a908..6a41b8f3e 100644 --- a/src/i18n/langs/en/index.js +++ b/src/i18n/langs/en/index.js @@ -25,6 +25,7 @@ import trainRoom from './trainRoom'; import menu from './menu'; import ibp from './ibp'; import approval from './approval'; +import systemGenerate from './systemGenerate'; export default { ...enLocale, @@ -53,5 +54,6 @@ export default { trainRoom, menu, ibp, - approval + approval, + systemGenerate }; diff --git a/src/i18n/langs/en/systemGenerate.js b/src/i18n/langs/en/systemGenerate.js new file mode 100644 index 000000000..cd34967aa --- /dev/null +++ b/src/i18n/langs/en/systemGenerate.js @@ -0,0 +1,9 @@ +export default { + map: 'Map', + mapName: 'Map Name', + prdName: 'Product Name', + name: 'Name', + type: 'Type', + updateData: 'Modify', + generate: 'Generate' +}; diff --git a/src/i18n/langs/zh/index.js b/src/i18n/langs/zh/index.js index 50d8a0d1e..c84bf1120 100644 --- a/src/i18n/langs/zh/index.js +++ b/src/i18n/langs/zh/index.js @@ -25,6 +25,7 @@ import trainRoom from './trainRoom'; import menu from './menu'; import ibp from './ibp'; import approval from './approval'; +import systemGenerate from './systemGenerate'; export default { ...cnLocale, @@ -53,5 +54,6 @@ export default { trainRoom, menu, ibp, - approval + approval, + systemGenerate }; diff --git a/src/i18n/langs/zh/systemGenerate.js b/src/i18n/langs/zh/systemGenerate.js new file mode 100644 index 000000000..158981019 --- /dev/null +++ b/src/i18n/langs/zh/systemGenerate.js @@ -0,0 +1,9 @@ +export default { + map: '地图', + mapName: '地图名称', + prdName: '产品名称', + name: '名称', + type: '类型', + updateData: '更新', + generate: '生成' +}; diff --git a/src/scripts/ConstConfig.js b/src/scripts/ConstConfig.js index da8435267..2987f9ec9 100644 --- a/src/scripts/ConstConfig.js +++ b/src/scripts/ConstConfig.js @@ -103,7 +103,11 @@ export default { { enlabel: 'Pending review', label: '待审核', value: '1'}, { enlabel: 'Successfully released', label: '发布成功', value: '2'}, { enlabel: 'Overrule', label: '被驳回', value: '3'} + ], + productType: [ + { enlabel: 'Lesson System', label: '教学系统', value: 'Lesson'}, + { enlabel: 'Exam System', label: '考试系统', value: 'Exam'}, + { enlabel: 'Simulation System', label: '仿真系统', value: 'Simulation'} ] - } }; diff --git a/src/views/demonstration/detail/index.vue b/src/views/demonstration/detail/index.vue index faf587857..19fa1b091 100644 --- a/src/views/demonstration/detail/index.vue +++ b/src/views/demonstration/detail/index.vue @@ -102,7 +102,6 @@ export default { methods: { async loadInitData() { this.loading = true; - this.currentPrdCode = this.prodId; try { const resp = await getSubSystemDetail(this.$route.params.subSystem); this.tryUser = 0; @@ -119,6 +118,7 @@ export default { pmsList: resp.data.permissionList || [], PermissionType: PermissionType.SIMULATION }; + this.currentPrdCode = resp.data.mapPrd.code; if (resp.data.mapPrd.prdType === '03') { this.getJointTrainingList(); } diff --git a/src/views/display/menuExam.vue b/src/views/display/menuExam.vue index b2e7c7f52..51dfcf9c6 100644 --- a/src/views/display/menuExam.vue +++ b/src/views/display/menuExam.vue @@ -24,6 +24,7 @@ import { exitFullscreen } from '@/utils/screen'; import { timeFormat } from '@/utils/date'; import { refreshExamList, finishOneExamQuestion } from '@/api/management/userexam'; import { launchFullscreen } from '@/utils/screen'; +import { UrlConfig } from '@/router/index'; export default { name: 'MenuExam', @@ -124,7 +125,7 @@ export default { type: 'warning' }).then(() => { this.$emit('quit'); - this.$router.back(); + this.$router.push({ path: `${UrlConfig.trainingPlatform.examDetail}/${this.$route.query.examId}`, query: { subSystem: this.$route.query.subSystem }}); Notification.closeAll(); exitFullscreen(); }).catch(() => { @@ -141,7 +142,7 @@ export default { }).catch(error => { // 如果时50009则表示考试已完成,不能再次进行y if (error.code === 500009) { - this.$router.replace({ path: `/trainingPlatform/result/${this.$route.params.userExamId}` }); + this.$router.replace({ path: `/trainingPlatform/result/${this.$route.params.userExamId}`, query: {subSystem: this.$route.query.subSystem} }); } else { this.$messageBox(this.$t('display.exam.refreshListError')); } diff --git a/src/views/display/tipExamList.vue b/src/views/display/tipExamList.vue index da7f989a6..ad55ebf76 100644 --- a/src/views/display/tipExamList.vue +++ b/src/views/display/tipExamList.vue @@ -5,7 +5,7 @@
- {{$t('display.exam.examTime')}} + {{ $t('display.exam.examTime') }} {{ formatRemainTime }}
@@ -38,12 +38,12 @@ {{ courseModel.name }}- {{$t('display.exam.bestTime')}} - {{ courseModel.minDuration }} {{$t('display.seconds')}} + {{ $t('display.exam.bestTime') }} + {{ courseModel.minDuration }} {{ $t('display.seconds') }}
- {{$t('display.exam.maximumTime')}} - {{ courseModel.maxDuration }} {{$t('display.seconds')}} + {{ $t('display.exam.maximumTime') }} + {{ courseModel.maxDuration }} {{ $t('display.seconds') }}
{{ $t('display.exam.trainingInstructions') }}
@@ -59,10 +59,10 @@
- {{$t('display.exam.examTime')}} + {{ $t('display.exam.examTime') }} {{ formatRemainTime }}
@@ -191,7 +191,7 @@ export default { }).catch(error => { // 如果时50009则表示考试已完成,不能再次进行y if (error.code === 500009) { - this.$router.replace({ path: `/exam/result/${this.$route.params.userExamId}` }); + this.$router.replace({ path: `/trainingPlatform/result/${this.$route.params.userExamId}`, query: { subSystem: this.$route.query.subSystem } }); } else { this.$messageBox(this.$t('display.exam.refreshListError')); @@ -233,7 +233,9 @@ export default { group: this.$route.query.group, userExamId: this.$route.query.userExamId, trainingId: obj.trainingId, - examQuestionId: obj.id + examQuestionId: obj.id, + subSystem: this.$route.query.subSystem, + examId: this.$route.query.examId }; this.$router.push({ path: '/display/exam', query: query }); this.$emit('refresh'); @@ -260,7 +262,7 @@ export default { exitFullscreen(); this.$store.dispatch('exam/over').then(() => { this.$store.dispatch('trainingList/clearTrainingList'); - this.$router.replace({ path: `/trainingPlatform/result/${this.$route.query.userExamId}` }); + this.$router.replace({ path: `/trainingPlatform/result/${this.$route.query.userExamId}`, query: {subSystem: this.$route.query.subSystem} }); }); }, shrink() { diff --git a/src/views/exam/detail/courseDetail.vue b/src/views/exam/detail/courseDetail.vue index 6e0d9ec97..f9dfee80e 100644 --- a/src/views/exam/detail/courseDetail.vue +++ b/src/views/exam/detail/courseDetail.vue @@ -102,8 +102,8 @@ export default { } }, watch: { - '$route.query.prodId': function (val) { - this.loadInitPage(val, this.$route.query.type); + '$route.params.subSystem': function (val) { + this.loadInitPage(); } }, mounted() { @@ -137,7 +137,7 @@ export default { this.loading = true; this.$router.push({ path: `${UrlConfig.trainingPlatform.pay}/${this.courseModel.id}`, - query: { permissionType: PermissionType.EXAM, lessonId: this.courseModel.id, prdCode: this.courseModel.prdCode, mapId: this.courseModel.mapId,subSystem:this.$route.params.subSystem } + query: { permissionType: PermissionType.EXAM, lessonId: this.courseModel.id, prdCode: this.courseModel.prdCode, mapId: this.courseModel.mapId, subSystem: this.$route.params.subSystem } }); }, checkCourse() { @@ -162,10 +162,9 @@ export default { } }, clickEvent(obj, node, data) { - // setSessionStorage('trainingExamCheckId', obj.id); if (obj.type === 'Exam') { if (obj.valid) { - this.$router.push(`${UrlConfig.trainingPlatform.examDetail}/${obj.id}`); + this.$router.push({ path: `${UrlConfig.trainingPlatform.examDetail}/${obj.id}`, query: { subSystem: this.$route.params.subSystem }}); } else { this.$confirm(this.$t('tip.accessCourseNo'), this.$t('tip.hint'), { confirmButtonText: this.$t('tip.confirm'), diff --git a/src/views/exam/detail/examDetail.vue b/src/views/exam/detail/examDetail.vue index 5abc807d5..67dc2d424 100644 --- a/src/views/exam/detail/examDetail.vue +++ b/src/views/exam/detail/examDetail.vue @@ -44,7 +44,7 @@