diff --git a/src/api/jointTraining.js b/src/api/jointTraining.js index dd3785ddc..7c77e7245 100644 --- a/src/api/jointTraining.js +++ b/src/api/jointTraining.js @@ -238,3 +238,12 @@ export function realDeviceIsUsedNew(group, projectCode) { } }); } + +// 获取所有需要值班员的车站(新版) +export function getAvailableStaionList(mapId) { + return request({ + url: `/api/map/${mapId}/station/needSupervisor`, + method: 'get' + }); +} + diff --git a/src/i18n/langs/en/router.js b/src/i18n/langs/en/router.js index 6520bb8e6..49c469f2c 100644 --- a/src/i18n/langs/en/router.js +++ b/src/i18n/langs/en/router.js @@ -75,5 +75,6 @@ export default { deviceManage: 'Device management', iscsDraw: 'Iscs Draw', iscsSystem: 'Iscs System', - studentManage: 'Student manage' + studentManage: 'Student manage', + examDetail: 'Exam detail' }; diff --git a/src/i18n/langs/zh/map.js b/src/i18n/langs/zh/map.js index 8d58a9c69..b95471af5 100644 --- a/src/i18n/langs/zh/map.js +++ b/src/i18n/langs/zh/map.js @@ -32,7 +32,7 @@ export default { save: '保存', updata: '更新', - updateObj: '修改名称', + updateObj: '修改', updateObjAxis: '更新坐标', saveAs: '另存为', publish: '发布', diff --git a/src/i18n/langs/zh/router.js b/src/i18n/langs/zh/router.js index ffc9c7d0d..b30c1ff92 100644 --- a/src/i18n/langs/zh/router.js +++ b/src/i18n/langs/zh/router.js @@ -79,5 +79,6 @@ export default { studentManage: '学生管理', competitionManage: '竞赛管理', refereeJManage: '仿真管理', - homeJsxt: '首页' + homeJsxt: '首页', + examDetail: '考试详情' }; diff --git a/src/jmapNew/shape/Switch/index.js b/src/jmapNew/shape/Switch/index.js index b8c4f86b2..3b8059130 100644 --- a/src/jmapNew/shape/Switch/index.js +++ b/src/jmapNew/shape/Switch/index.js @@ -161,8 +161,8 @@ export default class Switch extends Group { z: this.z + 6, _subType: 'enabled', // 标识 style: { - x: arrowTextX, - y: arrowTextY + 10, + x: nameTextX, + y: nameTextY + directy * 20, fontSize: 12, text: 'E', textAlign: 'center', diff --git a/src/jmapNew/theme/xian_01/menus/menuStation.vue b/src/jmapNew/theme/xian_01/menus/menuStation.vue index ca9705442..c00fab189 100644 --- a/src/jmapNew/theme/xian_01/menus/menuStation.vue +++ b/src/jmapNew/theme/xian_01/menus/menuStation.vue @@ -81,6 +81,16 @@ export default { cmdType: CMD.Station.active } // { + // label: '所有进路交人工控', + // handler: this.humanControlALL, + // cmdType: '' + // }, + // { + // label: '所有进路交ATS自动控', + // handler: this.atsAutoControlALL, + // cmdType: '' + // } + // { // label: '执行关键操作测试', // handler: this.execKeyOperationTest, // cmdType: CMD.Station.active, diff --git a/src/router/index_Common.js b/src/router/index_Common.js index aea6f912f..df44f7993 100644 --- a/src/router/index_Common.js +++ b/src/router/index_Common.js @@ -121,6 +121,7 @@ const DeviceManage = () => import('@/views/system/deviceManage/index'); const MapSort = () => import('@/views/publish/publishMap/mapSort'); const StudentManage = () => import('@/views/studentManage'); +const CompetitionDetail = () => import('@/views/jsxt/competition/examDetail'); const CompetitionManage = () => import('@/views/jsxt/competition/index'); const CompetitionHome = () => import('@/views/jsxt/competition/home'); const theoryManage = () => import('@/views/jsxt/competition/theory/index'); @@ -1023,6 +1024,15 @@ export const JSXT = [ meta: { hidden: true } + }, + { + path: 'examDetail', + component: CompetitionDetail, + meta: { + il8n: 'router.examDetail', + icon: 'design', + hidden: true + } } ] } diff --git a/src/views/jsxt/competition/examDetail.vue b/src/views/jsxt/competition/examDetail.vue new file mode 100644 index 000000000..d163d9214 --- /dev/null +++ b/src/views/jsxt/competition/examDetail.vue @@ -0,0 +1,348 @@ + + + diff --git a/src/views/newMap/displayNew/designIndex.vue b/src/views/newMap/displayNew/designIndex.vue index 8ffb148e0..2af6e52c5 100644 --- a/src/views/newMap/displayNew/designIndex.vue +++ b/src/views/newMap/displayNew/designIndex.vue @@ -24,8 +24,12 @@ :offset="offset" :offset-bottom="offsetBottom" :group="group" + :show-station="showStation" + :station-list="stationList" + :show-select-station="showSelectStation" @switchMode="switchMode" @selectQuest="selectQuest" + @switchStationMode="switchStationMode" /> @@ -104,6 +108,9 @@ export default { simulationShow: false, drivingShow: false, questId: 0, // 加载任务的Id + showStation: '', + stationList: [], + showSelectStation: false, // 是否展示现地选择设备集中站select group: '', prdTypeMap: { '01': '01', // 现地 => 现地 @@ -162,6 +169,12 @@ export default { '$store.state.map.mapViewLoadedCount': function (val) { this.mapBoxP = document.getElementById(this.canvasId).children[0]; this.mapBoxP.style.cursor = ''; + this.switchStationMode(this.showStation); + }, + '$store.state.training.centerStationCode': function(code) { + if (code) { + this.showStation = code; + } }, // '$store.state.training.prdType': function(val) { // debugger; @@ -172,6 +185,10 @@ export default { '$store.state.app.windowSizeCount': function() { this.setWindowSize(); }, + '$store.state.map.map': function (val) { + this.showSelectStation = val.skinVO.code === '06' && this.$store.state.training.prdType === '01'; + this.showSelectStation && this.setStationList(val); + }, $route() { this.$nextTick(() => { this.initLoadData(); @@ -436,6 +453,26 @@ export default { this.$store.dispatch('config/resize', { width, height }); this.$store.dispatch('training/updateOffsetStationCode', { offsetStationCode: this.offsetStationCode }); }); + }, + switchStationMode(val) { + if (val == null && this.stationList.length > 0) { + this.showStation = this.stationList[0].value; + } else { + this.showStation = val; + } + this.$store.dispatch('map/setShowCentralizedStationCode', this.showStation); + this.$store.dispatch('map/setShowCentralizedStationNum'); + }, + setStationList(val) { + this.stationList = []; + (val.stationList || []).forEach(item => { + if (item.centralized) { + this.stationList.push({value: item.code, name: item.name}); + } + }); + if (this.stationList.length) { + this.showStation = this.stationList[0].value; + } } } }; diff --git a/src/views/newMap/displayNew/index.vue b/src/views/newMap/displayNew/index.vue index fcda0d5c2..4c7c007f6 100644 --- a/src/views/newMap/displayNew/index.vue +++ b/src/views/newMap/displayNew/index.vue @@ -627,9 +627,15 @@ export default { } }, switchStationMode(val) { - this.showStation = val; - this.$store.dispatch('map/setShowCentralizedStationCode', this.showStation); - this.$store.dispatch('map/setShowCentralizedStationNum'); + if (this.stationList.length > 0) { + if (val == null) { + this.showStation = this.stationList[0].value; + } else { + this.showStation = val; + } + this.$store.dispatch('map/setShowCentralizedStationCode', this.showStation); + this.$store.dispatch('map/setShowCentralizedStationNum'); + } }, setStationList(val) { this.stationList = []; diff --git a/src/views/newMap/displayNew/menuDemon.vue b/src/views/newMap/displayNew/menuDemon.vue index 5ecee252f..b8f3287e9 100644 --- a/src/views/newMap/displayNew/menuDemon.vue +++ b/src/views/newMap/displayNew/menuDemon.vue @@ -329,11 +329,12 @@ export default { font-size: 18px !important; color: #fff; } - - .display-draft { - position: absolute; - float: right; - right: 20px; - bottom: 15px; - } + + diff --git a/src/views/newMap/displayNew/menuSchema.vue b/src/views/newMap/displayNew/menuSchema.vue index a9b08129e..d858431b0 100644 --- a/src/views/newMap/displayNew/menuSchema.vue +++ b/src/views/newMap/displayNew/menuSchema.vue @@ -1,10 +1,10 @@