diff --git a/src/jmapNew/constant/deviceType.js b/src/jmapNew/constant/deviceType.js index 9904005df..4d995bb06 100644 --- a/src/jmapNew/constant/deviceType.js +++ b/src/jmapNew/constant/deviceType.js @@ -51,15 +51,15 @@ const deviceType = { DirectionRod: 'DirectionRod', Responder: 'Responder', SignalButton: 'SignalButton', - PickArrow: 'PickArrow', - DepartArrow: 'DepartArrow', - Occlusion: 'Occlusion', - Accident: 'Accident', - Recovery: 'Recovery', - PickAssist: 'PickAssist', - DepartAssist: 'DepartAssist', - TotalAssist: 'TotalAssist', - AssistStatus: 'AssistStatus', - SectionOccupied: 'SectionOccupied' + PickArrow: 'PickArrow', + DepartArrow: 'DepartArrow', + Occlusion: 'Occlusion', + Accident: 'Accident', + Recovery: 'Recovery', + PickAssist: 'PickAssist', + DepartAssist: 'DepartAssist', + TotalAssist: 'TotalAssist', + AssistStatus: 'AssistStatus', + SectionOccupied: 'SectionOccupied' }; export default deviceType; diff --git a/src/jmapNew/theme/components/utils/menuOperate.js b/src/jmapNew/theme/components/utils/menuOperate.js index 0755d7f2a..25fab991a 100644 --- a/src/jmapNew/theme/components/utils/menuOperate.js +++ b/src/jmapNew/theme/components/utils/menuOperate.js @@ -564,10 +564,25 @@ export const menuOperate = { operation: OperationEvent.CTCCommand.autoTrigger.menu.operation, cmdType: CMD.CTC.CTC_AUTO_TRIGGER }, - // 批量修改股道 - batchModifyTrackSection:{ - operation: OperationEvent.CTCCommand.batchModifyTrackSection.menu.operation, - cmdType: CMD.CTC.CTC_BATCH_MODIFY_RUN_PLAN + // // 批量修改股道 + // batchModifyTrackSection:{ + // operation: OperationEvent.CTCCommand.batchModifyTrackSection.menu.operation, + // cmdType: CMD.CTC.CTC_BATCH_MODIFY_RUN_PLAN + // }, + // 修改股道 + modifyTrackSection:{ + operation: OperationEvent.CTCCommand.modifyTrackSection.menu.operation, + cmdType: CMD.CTC.CTC_MODIFY_SECTION + }, + // 车站发送计划 + stationSendRunplan:{ + operation: OperationEvent.CTCCommand.stationSendRunplan.menu.operation, + cmdType: CMD.CTC.CTC_STATION_SEND_OUT_RUN_PLAN + }, + // 车站取消红闪 + stationCancleTwinkle:{ + operation: OperationEvent.CTCCommand.stationCancleTwinkle.menu.operation, + cmdType: CMD.CTC.CTC_CANCEL_TWINKLE }, // 移除行车日志 deleteRunplan:{ @@ -642,6 +657,16 @@ export const menuOperate = { modifyDispatcherLogerRpSection:{ operation: OperationEvent.CTCCommand.modifyDispatcherLogerRpSection.menu.operation, cmdType: CMD.CTC.CTC_ZONE_SAVE_TRACK_SECTION + }, + // 调度台行车计划修改时间 + modifyDispatcherLogerRpPlanTime:{ + operation: OperationEvent.CTCCommand.modifyDispatcherLogerRpSection.menu.operation, + cmdType: CMD.CTC.CTC_ZONE_SAVE_PLAN_TIME + }, + // 调度台行车计划修改出入口 + modifyDispatcherLogerRpDirection:{ + operation: OperationEvent.CTCCommand.modifyDispatcherLogerRpSection.menu.operation, + cmdType: CMD.CTC.CTC_ZONE_SAVE_DIRECTION } }, Rail: { @@ -653,6 +678,10 @@ export const menuOperate = { operation: OperationEvent.RailCommand.railQueryTicket.menu.operation, cmdType: CMD.RAIL.CMD_RAIL_QUERY_TICKET }, + railGiveTicketTo: { + operation: OperationEvent.RailCommand.railGiveTicketTo.menu.operation, + cmdType: CMD.RAIL.CMD_RAIL_GIVE_TICKET_TO + }, railFillInRegister: { operation: OperationEvent.RailCommand.railFillInRegister.menu.operation, cmdType: CMD.RAIL.CMD_RAIL_FILL_IN_REGISTER diff --git a/src/jmapNew/theme/datie_02/menus/dialog/sendRunplan.vue b/src/jmapNew/theme/datie_02/menus/dialog/sendRunplan.vue index 26e4fb5dd..a56d5f917 100644 --- a/src/jmapNew/theme/datie_02/menus/dialog/sendRunplan.vue +++ b/src/jmapNew/theme/datie_02/menus/dialog/sendRunplan.vue @@ -134,9 +134,9 @@ export default { tableData1:[], tableData2:[], addModel:{ - stationCode:'', - planParamList:[], - force:1 + stationCode:'' + // planParamList:[], + // force:1 } }; }, @@ -148,15 +148,15 @@ export default { return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : ''; }, domIdConfirm() { - return this.dialogShow ? OperationEvent.CTCCommand.batchModifyTrackSection.menu.domId : ''; + return this.dialogShow ? OperationEvent.CTCCommand.stationSendRunplan.menu.domId : ''; }, title() { return '发送计划'; } }, methods:{ - doShow(tableData, activeDepartRunPlan, activeArriveRunPlan, filterSectionList) { - this.addModel.planParamList = []; + doShow(tableData, filterSectionList) { + // this.addModel.planParamList = []; this.tableData1 = []; tableData.forEach(element => { if (element.arriveRunPlan && element.arriveRunPlan.sectionCode) { @@ -171,24 +171,24 @@ export default { }); // filterSectionList this.addModel.stationCode = this.$store.state.training.roleDeviceCode; - const activeDepartRunPlanList = Object.values(activeDepartRunPlan).filter(activeDepart=>{ return activeDepart.changeSectionCode && activeDepart.changeSectionCode != activeDepart.sectionCode; }); - if (activeDepartRunPlanList.length > 0) { - activeDepartRunPlanList.forEach(depart=>{ - this.addModel.planParamList.push({ - runPlanCode:depart.code, - departSectionCode:depart.changeSectionCode - }); - }); - } - const activeArriveRunPlanList = Object.values(activeArriveRunPlan).filter(activeArrive=>{ return activeArrive.changeSectionCode && activeArrive.changeSectionCode != activeArrive.sectionCode; }); - if (activeArriveRunPlanList.length > 0) { - activeArriveRunPlanList.forEach(arrive=>{ - this.addModel.planParamList.push({ - runPlanCode:arrive.code, - arriveSectionCode:arrive.changeSectionCode - }); - }); - } + // const activeDepartRunPlanList = Object.values(activeDepartRunPlan).filter(activeDepart=>{ return activeDepart.changeSectionCode && activeDepart.changeSectionCode != activeDepart.sectionCode; }); + // if (activeDepartRunPlanList.length > 0) { + // activeDepartRunPlanList.forEach(depart=>{ + // this.addModel.planParamList.push({ + // runPlanCode:depart.code, + // departSectionCode:depart.changeSectionCode + // }); + // }); + // } + // const activeArriveRunPlanList = Object.values(activeArriveRunPlan).filter(activeArrive=>{ return activeArrive.changeSectionCode && activeArrive.changeSectionCode != activeArrive.sectionCode; }); + // if (activeArriveRunPlanList.length > 0) { + // activeArriveRunPlanList.forEach(arrive=>{ + // this.addModel.planParamList.push({ + // runPlanCode:arrive.code, + // arriveSectionCode:arrive.changeSectionCode + // }); + // }); + // } this.dialogShow = true; this.$nextTick(function () { this.$store.dispatch('training/emitTipFresh'); @@ -200,21 +200,21 @@ export default { this.$store.dispatch('training/emitTipFresh'); }, commit() { - if (this.addModel.planParamList.length > 0) { - const params = this.addModel; - this.loading = true; - commitOperate(menuOperate.CTC.batchModifyTrackSection, params, 3).then(({valid})=>{ - this.loading = false; - if (valid) { - this.$emit('closeFlash'); - this.doClose(); - } - }).catch(() => { - this.loading = false; + // if (this.addModel.planParamList.length > 0) { + const params = this.addModel; + this.loading = true; + commitOperate(menuOperate.CTC.stationSendRunplan, params, 3).then(({valid})=>{ + this.loading = false; + if (valid) { + // this.$emit('closeFlash'); this.doClose(); - this.$emit('noticeInfo'); - }); - } + } + }).catch(() => { + this.loading = false; + this.doClose(); + this.$emit('noticeInfo'); + }); + // } // * @param stationCode 车站编码 // * @param runPlanCode 运行编码 diff --git a/src/jmapNew/theme/datie_02/menus/dialog/stageRunplan.vue b/src/jmapNew/theme/datie_02/menus/dialog/stageRunplan.vue index 6a55e1b49..89b7b22ee 100644 --- a/src/jmapNew/theme/datie_02/menus/dialog/stageRunplan.vue +++ b/src/jmapNew/theme/datie_02/menus/dialog/stageRunplan.vue @@ -53,9 +53,12 @@ width="100" > diff --git a/src/jmapNew/theme/datie_02/menus/runplanPane.vue b/src/jmapNew/theme/datie_02/menus/runplanPane.vue index 036da1041..74e6ccec4 100644 --- a/src/jmapNew/theme/datie_02/menus/runplanPane.vue +++ b/src/jmapNew/theme/datie_02/menus/runplanPane.vue @@ -77,6 +77,7 @@ border height="695" highlight-current-row + :row-class-name="judgeColor" style="width: 100%;border:1px #ccc solid" @cell-click="selectedTripNumber" @current-change="handleCurrentChange" @@ -88,7 +89,7 @@ width="100" > @@ -98,12 +99,18 @@


 
1
+
+ @@ -112,7 +119,7 @@
3
@@ -127,9 +134,9 @@ placeholder="" size="mini" popper-class="stationSelect" - @focus="focusArriveRunPlan($event,scope.row)" @change="changeArriveRunPlan($event,scope.row,scope.$index)" > + 7 @@ -177,6 +184,11 @@

8
+
@@ -271,12 +283,18 @@


 
19
+ + @@ -291,7 +309,6 @@ placeholder="" size="mini" popper-class="stationSelect" - @focus="focusDepartRunPlan($event,scope.row)" @change="changeDepartRunPlan($event,scope.row,scope.$index)" > 22 @@ -342,7 +359,7 @@
25
@@ -350,6 +367,11 @@

26
+
@@ -422,7 +444,7 @@
修改相关邻站
删除
-
清楚闪烁
+
清除闪烁
全体信息
@@ -483,7 +505,8 @@ - + + @@ -542,8 +565,8 @@ export default { Rph:Rph, tableData:[], filterSectionList:[], - activeDepartRunPlan:{}, - activeArriveRunPlan:{}, + // activeDepartRunPlan:{}, + // activeArriveRunPlan:{}, currentRailwaySimulationRunplan:{}, // radioSelected:'' currentRow:null @@ -560,11 +583,45 @@ export default { }, '$store.state.socket.railwaySimulationRunplanSendChange': function (val) { this.getRailwaySimulationRunplanSend(); + }, + '$store.state.socket.changedCtcRunplanMap': function (val) { + this.judgeStationCtcRunplan(); + }, + // 仿真-仿真重置消息 + '$store.state.socket.simulationReset': function (val) { + this.$store.dispatch('socket/resetRailCtcRunplanInitMsg'); + this.loadData(); } - // railwaySimulationRunplanSendMap - // railwaySimulationRunplanSendChange }, methods:{ + judgeColor({row, rowIndex}) { + if (row.effect) { + if (row.passenger == 'PASSENGER') { + return 'fontRed'; + } else if (row.passenger == 'GOODS_TRAIN') { + return 'fontBlue'; + } else { + return 'fontBlack'; + } + } else { + if (row.passenger == 'PASSENGER') { + return 'fontPink'; + } else if (row.passenger == 'GOODS_TRAIN') { + return 'fontLightBlue'; + } else { + return 'fontBlack'; + } + } + }, + judgeStationCtcRunplan() { + const changedCtcRunplanMap = this.$store.state.socket.changedCtcRunplanMap; + const stationCode = this.$store.state.training.roleDeviceCode; + if (changedCtcRunplanMap[stationCode]) { + document.getElementById('sendRunplan').classList.add('active'); + } else { + this.closeFlash(); + } + }, getRailwaySimulationRunplanSend() { const stationCode = this.$store.state.training.roleDeviceCode; const railwaySimulationRunplanSendMap = this.$store.state.socket.railwaySimulationRunplanSendMap; @@ -573,8 +630,8 @@ export default { document.getElementById('stageRunplan').classList.add('active'); this.currentRailwaySimulationRunplan = railwaySimulationRunplanSendMap; } else { - const sendRunplan = document.getElementById('stageRunplan').className; - document.getElementById('stageRunplan').className = sendRunplan.replace('active', ''); + const stageRunplan = document.getElementById('stageRunplan').className; + document.getElementById('stageRunplan').className = stageRunplan.replace('active', ''); } }, loadData() { @@ -594,8 +651,11 @@ export default { return data.stationCode == this.$store.state.training.roleDeviceCode; }); this.tableData.sort((prev, next)=>{ - const prevPlanTime = prev.departRunPlan ? prev.departRunPlan.planTime : prev.arriveRunPlan ? prev.arriveRunPlan.planTime : '00:00:00'; - const nextPlanTime = next.departRunPlan ? next.departRunPlan.planTime : next.arriveRunPlan ? next.arriveRunPlan.planTime : '00:00:00'; + const prevPlanTime = prev.departRunPlan ? (prev.departRunPlan.actualTime || prev.departRunPlan.planTime) + : prev.arriveRunPlan ? (prev.arriveRunPlan.actualTime || prev.arriveRunPlan.planTime) : '00:00:00'; + const nextPlanTime = next.departRunPlan ? (next.departRunPlan.actualTime || next.departRunPlan.planTime) + : next.arriveRunPlan ? (next.arriveRunPlan.actualTime || next.arriveRunPlan.planTime) : '00:00:00'; + // const nextPlanTime = next.departRunPlan ? next.departRunPlan.planTime : next.arriveRunPlan ? next.arriveRunPlan.planTime : '00:00:00'; return new Date('2000-06-18 ' + prevPlanTime).getTime() - new Date('2000-06-18 ' + nextPlanTime).getTime(); }); }, @@ -611,6 +671,7 @@ export default { this.loadData(); this.isShow = true; this.getRailwaySimulationRunplanSend(); + this.judgeStationCtcRunplan(); window.addEventListener('keydown', this.handleKeyDown); // arriveRunPlan: Object // code: "00110010" @@ -654,7 +715,8 @@ export default { }, sendRunplan() { if (document.getElementById('sendRunplan').className.includes('active')) { - this.$refs.sendRunplan.doShow(this.tableData, this.activeDepartRunPlan, this.activeArriveRunPlan, this.filterSectionList); + this.$refs.sendRunplan.doShow(this.tableData, this.filterSectionList); + // this.activeDepartRunPlan, this.activeArriveRunPlan, } }, stageRunplan() { @@ -663,28 +725,56 @@ export default { this.$refs.stageRunplan.doShow(this.currentRailwaySimulationRunplan[stationCode]); } }, - focusDepartRunPlan(event, row) { - this.activeDepartRunPlan[row.code] = {sectionCode:event, code:row.code}; - }, - // 发车股道 changeDepartRunPlan(event, row, index) { - const activeDepart = this.activeDepartRunPlan[row.code]; - if (activeDepart) { - activeDepart.changeSectionCode = event; - document.getElementById('sendRunplan').classList.add('active'); - } + const params = { + stationCode:row.stationCode, + runPlanCode:row.code, + arriveSection:'', + departSection:row.departRunPlan.sectionCode, + force:1 + }; + commitOperate(menuOperate.CTC.modifyTrackSection, params, 3).then(({valid})=>{ + this.loading = false; + if (valid) { + } + }).catch(() => { + this.loading = false; + }); + // const activeDepart = this.activeDepartRunPlan[row.code]; + // if (activeDepart) { + // activeDepart.changeSectionCode = event; + // document.getElementById('sendRunplan').classList.add('active'); + // } // console.log(event, this.tableData[index].departRunPlan.sectionCode, row.departRunPlan.sectionCode, '------'); }, - focusArriveRunPlan(event, row) { - this.activeArriveRunPlan[row.code] = {sectionCode:event, code:row.code}; - }, changeArriveRunPlan(event, row, index) { - const activeArrive = this.activeArriveRunPlan[row.code]; - if (activeArrive) { - activeArrive.changeSectionCode = event; - // if(activeArrive.changeSectionCode!=) - document.getElementById('sendRunplan').classList.add('active'); - } + const params = { + stationCode:row.stationCode, + runPlanCode:row.code, + arriveSection:row.arriveRunPlan.sectionCode, + departSection:'', + force:1 + }; + // stationCode 车站编码 + // runPlanCode 运行计划 + // arriveSection 到达股道 + // departSection 出发股道 + // force 是否强制 + // element.arriveRunPlan.sectionCode + // element.departRunPlan.sectionCode + commitOperate(menuOperate.CTC.modifyTrackSection, params, 3).then(({valid})=>{ + this.loading = false; + if (valid) { + } + }).catch(() => { + this.loading = false; + }); + // const activeArrive = this.activeArriveRunPlan[row.code]; + // if (activeArrive) { + // activeArrive.changeSectionCode = event; + // // if(activeArrive.changeSectionCode!=) + // document.getElementById('sendRunplan').classList.add('active'); + // } // CTC_MODIFY_TRACK_SECTION // 参数: // * @param stationCode 车站编码 @@ -704,18 +794,18 @@ export default { // force 是否强制 0:不强制。1:强制 }, closeDialog() { - this.closeFlash(); + // this.closeFlash(); this.doClose(); - this.activeDepartRunPlan = {}; - this.activeArriveRunPlan = {}; + // this.activeDepartRunPlan = {}; + // this.activeArriveRunPlan = {}; }, closeFlash() { const sendRunplan = document.getElementById('sendRunplan').className; document.getElementById('sendRunplan').className = sendRunplan.replace('active', ''); }, closeStageFlash() { - const sendRunplan = document.getElementById('stageRunplan').className; - document.getElementById('stageRunplan').className = sendRunplan.replace('active', ''); + const stageRunplan = document.getElementById('stageRunplan').className; + document.getElementById('stageRunplan').className = stageRunplan.replace('active', ''); const stationCode = this.$store.state.training.roleDeviceCode; this.$store.dispatch('socket/deleteRailwaySimulationRunplan', stationCode); }, @@ -764,6 +854,24 @@ export default { this.rpMenuPopShow = false; this.$refs.deleteRunplan.doShow(this.currentRow); }, + // 清除闪烁 + clearFlash() { + if (this.currentRow && this.currentRow.twinkle) { + event.stopPropagation(); + this.rpMenuPopShow = false; + commitOperate(menuOperate.CTC.stationCancleTwinkle, {stationCode:this.currentRow.stationCode, runPlanCode: this.currentRow.code}, 3).then(({valid})=>{ + this.loading = false; + this.clearRpRow(); + if (valid) { + // this.doClose(); + } + }).catch(() => { + this.loading = false; + this.clearRpRow(); + this.noticeInfo(); + }); + } + }, // 发送发车预告 sendNotcie() { // && this.currentRow.departRunPlan && this.currentRow.departRunPlan.adjacentMessage == 0 @@ -1028,6 +1136,14 @@ export default { -moz-animation:changeColor 1s infinite; /* Firefox */ -webkit-animation:changeColor 1s infinite; /* Safari and Chrome */ } +.flashTrip{ + animation:flashColor 1s infinite; + -moz-animation:flashColor 1s infinite; /* Firefox */ + -webkit-animation:flashColor 1s infinite; /* Safari and Chrome */ +} +.noChange{ + line-height: 28px; +} @keyframes changeColor { 0% {background:#f0f0f0;} @@ -1046,6 +1162,24 @@ export default { 50% {background:#ff1900;} 100% {background:#f0f0f0;} } +@keyframes flashColor +{ + 0% {background:#fff;} + 50% {background:#ff1900;} + 100% {background:#fff;} +} +@-moz-keyframes flashColor /* Firefox */ +{ + 0% {background:#fff;} + 50% {background:#ff1900;} + 100% {background:#fff;} +} +@-webkit-keyframes flashColor /* Safari and Chrome */ +{ + 0% {background:#fff;} + 50% {background:#ff1900;} + 100% {background:#fff;} +} .eachRpImage{display: inline-block;vertical-align: top;margin-top: 3px;} .eachRpImageIn{height:26px;cursor: pointer;} .rpMenuPop{ @@ -1122,4 +1256,9 @@ export default { } .passagerTrain{background:#f00;width: 100%;height: 28px;} .goodTrain{background:#00f;width: 100%;height: 28px;} +.fontRed{color:#f00} +.fontBlue{color:#00f} +.fontBlack{color:#000} +.fontPink{color: #FF1493;} +.fontLightBlue{color: #87CEFA;} diff --git a/src/scripts/cmdPlugin/CommandEnum.js b/src/scripts/cmdPlugin/CommandEnum.js index f88a38649..9f71a2e04 100644 --- a/src/scripts/cmdPlugin/CommandEnum.js +++ b/src/scripts/cmdPlugin/CommandEnum.js @@ -395,7 +395,12 @@ export default { CTC_ASSIST_PRESS_BLOCK:{value: 'ASSIST_PRESS_BLOCK', label: '阻塞'}, CTC_ASSIST_PRESS_RESTORE:{value: 'ASSIST_PRESS_RESTORE', label: '复原'}, CTC_ASSIST_PRESS_ACCIDENT:{value: 'ASSIST_PRESS_ACCIDENT', label: '事故'}, - CTC_BATCH_MODIFY_RUN_PLAN:{value: 'CTC_BATCH_MODIFY_RUN_PLAN', label: '批量修改股道'}, + + // CTC_BATCH_MODIFY_RUN_PLAN:{value: 'CTC_BATCH_MODIFY_RUN_PLAN', label: '批量修改股道'}, + CTC_MODIFY_SECTION:{value: 'CTC_MODIFY_SECTION', label: '修改股道'}, + CTC_STATION_SEND_OUT_RUN_PLAN:{value: 'CTC_STATION_SEND_OUT_RUN_PLAN', label: '车站发送计划'}, + CTC_CANCEL_TWINKLE:{value: 'CTC_CANCEL_TWINKLE', label: '车站取消红闪'}, + CTC_REMOVE_RUN_PLAN:{value: 'CTC_REMOVE_RUN_PLAN', label: '移除行车日志'}, CTC_MODIFY_ADJACENT_STATION:{value: 'CTC_MODIFY_ADJACENT_STATION', label: '修改邻站信息'}, CTC_MODIFY_TRIP_NUMBER:{value: 'CTC_MODIFY_TRIP_NUMBER', label: '修改车次号(大铁CTC)'}, @@ -415,14 +420,16 @@ export default { CTC_ZONE_SAVE_TRACK_SECTION:{value:'CTC_ZONE_SAVE_TRACK_SECTION', label: '调度台行车计划修改股道'}, CTC_ZONE_SAVE_TRIP_NUMBER:{value:'CTC_ZONE_SAVE_TRIP_NUMBER', label: '调度台行车计划修改车次'}, - CTC_ZONE_SAVE_PLAN_TIME:{value:'CTC_ZONE_SAVE_PLAN_TIME', label: '调度台行车计划修改到达计划时间'}, - CTC_ZONE_SAVE_DIRECTION:{value:'CTC_ZONE_SAVE_DIRECTION', label: '调度台行车计划修改到出入口'}, + CTC_ZONE_SAVE_PLAN_TIME:{value:'CTC_ZONE_SAVE_PLAN_TIME', label: '调度台行车计划修改时间'}, + CTC_ZONE_SAVE_DIRECTION:{value:'CTC_ZONE_SAVE_DIRECTION', label: '调度台行车计划修改出入口'}, CTC_ZONE_SAVE_STATION:{value:'CTC_ZONE_SAVE_STATION', label: '调度台行车计划修改到发车站'} + }, RAIL: { CMD_RAIL_FILL_IN_TICKET: {value: 'RAIL_FILL_IN_TICKET', label: '填写票据'}, CMD_RAIL_QUERY_TICKET: {value: 'RAIL_QUERY_TICKET', label: '查询票据'}, CMD_RAIL_FILL_IN_REGISTER: {value: 'RAIL_FILL_IN_REGISTER', label: '填写行车簿册'}, - CMD_RAIL_QUERY_REGISTER: {value: 'RAIL_QUERY_REGISTER', label: '查询行车簿册'} + CMD_RAIL_QUERY_REGISTER: {value: 'RAIL_QUERY_REGISTER', label: '查询行车簿册'}, + CMD_RAIL_GIVE_TICKET_TO: {value: 'RAIL_GIVE_TICKET_TO', label: '给出票据'} } }; diff --git a/src/scripts/cmdPlugin/OperationHandler.js b/src/scripts/cmdPlugin/OperationHandler.js index 6a3636d19..06e5a460b 100644 --- a/src/scripts/cmdPlugin/OperationHandler.js +++ b/src/scripts/cmdPlugin/OperationHandler.js @@ -3667,11 +3667,18 @@ export const OperationEvent = { domId: '_Tips-CTC-AssistPressAccident-Menu{TOP}' } }, - // 批量修改股道 - batchModifyTrackSection:{ + // // 批量修改股道 + // batchModifyTrackSection:{ + // menu: { + // operation: '1111', + // domId: '_Tips-CTC-batchModifyTrackSection-Menu{TOP}' + // } + // }, + // 修改股道 + modifyTrackSection:{ menu: { operation: '1111', - domId: '_Tips-CTC-batchModifyTrackSection-Menu{TOP}' + domId: '_Tips-CTC-modifyTrackSection-Menu{TOP}' } }, // 移除行车日志 @@ -3820,7 +3827,37 @@ export const OperationEvent = { operation: '1132', domId: '_Tips-CTC-modifyDispatcherLogerRpSection-Menu{TOP}' } + }, + // 车站发送计划 + stationSendRunplan:{ + menu: { + operation: '1133', + domId: '_Tips-CTC-stationSendRunplan-Menu{TOP}' + } + }, + // 车站取消红闪 + stationCancleTwinkle:{ + menu: { + operation: '1134', + domId: '_Tips-CTC-stationCancleTwinkle-Menu{TOP}' + } + }, + // 调度台行车计划修改时间 + modifyDispatcherLogerRpPlanTime:{ + menu: { + operation: '1135', + domId: '_Tips-CTC-modifyDispatcherLogerRpPlanTime-Menu{TOP}' + } + }, + // 调度台行车计划修改出入口 + modifyDispatcherLogerRpDirection:{ + menu: { + operation: '1136', + domId: '_Tips-CTC-modifyDispatcherLogerRpDirection-Menu{TOP}' + } } + // CTC_ZONE_SAVE_TRIP_NUMBER + // CTC_ZONE_SAVE_STATION }, RailCommand: { railFillInTicket: { @@ -3846,6 +3883,12 @@ export const OperationEvent = { operation: '1204', domId: '_Tips-Rail-railQueryTicket' } + }, + railGiveTicketTo: { + menu: { + operation: '1205', + domId: '_Tips-Rail-railGiveTicketTo' + } } } }; diff --git a/src/store/modules/socket.js b/src/store/modules/socket.js index 125128086..9f5a079d8 100644 --- a/src/store/modules/socket.js +++ b/src/store/modules/socket.js @@ -269,6 +269,14 @@ function handle(state, data) { case 'SIMULATION_RAIL_CTC_DISPATCH_COMMAND': state.dispatchCommandMsg = msg; break; + // 车站发送计划信息 + case 'SIMULATION_CTC_RUN_PLAN_CONFIRM_SEND': + state.changedCtcRunplanMap = msg; + break; + case 'SIMULATION_RAIL_TICKET': + state.ticketInfo = msg; + break; + // // // 大铁项目 调度台 运行图信息 初始化消息 // case 'SIMULATION_RAILWAY_RUN_PLAN_INIT': // state.railwaySimulationRpMsg = {}; @@ -400,6 +408,7 @@ const socket = { overConversition: {}, // 仿真会话结束 exitConversition: {}, // 仿真成员退出会话 conversationInfo: {}, // 仿真会话消息 + ticketInfo: {}, // 路票消息 message: {}, // 仿真聊天 msgQueue: [], // 命令请求列表(旧版控制权转移可能在用,新版不用这个) @@ -445,6 +454,7 @@ const socket = { loggedOutMsg: '', railCtcStatusMsg: {}, // 占线板信息 dispatchCommandMsg: {}, // 调度命令信息 + changedCtcRunplanMap:{}, // 大铁项目 ctc 被修改运行计划的车站信息 railCtcRunplanInitMsg:{}, // 大铁项目 ctc 运行图初始化信息 railCtcRunplanChange:0, // 大铁项目 ctc 运行图信息变化 railCtcStationManageRpMsg:{}, // 大铁项目 ctc 车务管理 端运行图信息 @@ -545,6 +555,9 @@ const socket = { }, clearDispatchCommandMsg: (state, data) => { state.dispatchCommandMsg = {}; + }, + resetRailCtcRunplanInitMsg: (state) => { + state.railCtcRunplanInitMsg = {}; } }, @@ -642,6 +655,9 @@ const socket = { }, deleteRailwaySimulationRunplan:({ commit }, stationCode) => { commit('deleteRailwaySimulationRunplan', stationCode); + }, + resetRailCtcRunplanInitMsg:({ commit }) => { + commit('resetRailCtcRunplanInitMsg'); } } }; diff --git a/src/store/modules/training.js b/src/store/modules/training.js index 52966a432..746f36542 100644 --- a/src/store/modules/training.js +++ b/src/store/modules/training.js @@ -450,7 +450,6 @@ const training = { rtn && rtn.valid && commit('next'); } } - console.log(rtn, '*********'); resolve(rtn); }).catch(error => { // console.error(error); diff --git a/src/views/dispatcherLoger/addDispatcherLogerRunplan.vue b/src/views/dispatcherLoger/addDispatcherLogerRunplan.vue index 976daf1f2..68e9064e2 100644 --- a/src/views/dispatcherLoger/addDispatcherLogerRunplan.vue +++ b/src/views/dispatcherLoger/addDispatcherLogerRunplan.vue @@ -173,7 +173,23 @@ export default { filterDepSectionList:[], filterSectionList:[], trainTypeList:[ - {name:'跨局快速旅客列车', code:'FAST_PASSENGER_TRAIN' } + // 管内列车 + {name:'管内特快旅客列车', code:'LOCAL_EXPRESS_PASSENGER_TRAIN' }, + {name:'管内快速旅客列车', code:'LOCAL_FAST_PASSENGER_TRAIN' }, + {name:'管内普通旅客快车', code:'LOCAL_PASSENGER_TRAIN' }, + {name:'管内普通旅客慢车', code:'LOCAL_SLOW_PASSENGER_TRAIN' }, + {name:'管内临时旅客列车', code:'LOCAL_TEMPORARY_PASSENGER_TRAIN' }, + {name:'管内临时旅游列车', code:'LOCAL_TEMPORARY_TOURIST_TRAIN' }, + // 跨局列车 + {name:'跨局快速旅客列车', code:'FAST_PASSENGER_TRAIN' }, + {name:'跨局临时旅游列车', code:'TEMPORARY_TOURIST_TRAIN' }, + {name:'跨两局普通旅客快车', code:'TWO_PASSENGER_TRAIN' }, + {name:'跨两局普通旅客慢车', code:'TWO_SLOW_PASSENGER_TRAIN' }, + {name:'跨两局临时旅客列车', code:'TWO_TEMPORARY_PASSENGER_TRAIN' }, + {name:'跨三局及其以上普通旅客快车', code:'MORE_PASSENGER_TRAIN' }, + // 其他列车 + {name:'回送出入厂客车底列车', code:'BACK_FACTORY_PASSENGER_TRAIN' }, + {name:'因故折返旅客列车', code:'FAULT_TRUE_BACK_PASSENGER_TRAIN' } ], runTypeList:[ {name:'快速旅客列车', code:'FAST_PASSENGER_TRAIN' } @@ -246,8 +262,8 @@ export default { } }, methods: { - doShow({filterSectionList, mapStationDirectionMap}) { - this.mapStationDirectionList = Object.values(mapStationDirectionMap); + doShow({filterSectionList, mapStationDirectionList}) { + this.mapStationDirectionList = mapStationDirectionList; this.filterSectionList = filterSectionList; this.dialogShow = true; this.$nextTick(function () { diff --git a/src/views/dispatcherLoger/index.vue b/src/views/dispatcherLoger/index.vue index 3fe7c5e7c..32a665db6 100644 --- a/src/views/dispatcherLoger/index.vue +++ b/src/views/dispatcherLoger/index.vue @@ -67,7 +67,22 @@ @@ -75,32 +90,49 @@ - + - + @@ -171,6 +207,7 @@ export default { isShow:false, height: this.$store.state.app.height - 37, filterSectionList:[], + mapStationDirectionData:[], // filterSectionMap:{}, tableData:[], group:'', @@ -182,10 +219,7 @@ export default { computed: { ...mapGetters('map', [ 'sectionList' - ]), - mapStationDirectionData() { - return this.$store.state.map.mapStationDirectionData; - } + ]) }, watch:{ // '$store.state.socket.railwaySimulationRpChange': function (val) { @@ -216,6 +250,7 @@ export default { }, doShow() { this.loadFilterSectionMap(); + this.mapStationDirectionData = Object.values(this.$store.state.map.mapStationDirectionData); // this.tableData = []; // this.loadData(); this.isShow = true; @@ -248,6 +283,55 @@ export default { changeDepartRunPlan(event, row, index) { this.modifyDispatcherLogerRpSection(row, row.departSectionCode, 'D'); }, + // + + changeArrivePlanTime(event, row, index) { + this.modifyDispatcherLogerRpPlanTime(row, row.arrivePlanTime, 'R'); + }, + changeDepartPlanTime(event, row, index) { + this.modifyDispatcherLogerRpPlanTime(row, row.departPlanTime, 'D'); + }, + changeArriveDirectionCode(event, row, index) { + this.modifyDispatcherLogerRpDirection(row, row.arriveDirectionCode, 'R'); + }, + changeDepartDirectionCode(event, row, index) { + this.modifyDispatcherLogerRpDirection(row, row.departDirectionCode, 'D'); + }, + // 调度台行车计划修改出入口 + modifyDispatcherLogerRpDirection(row, directionCode, type) { + const params = {stationCode:row.stationCode, runPlanCode:row.runPlanCode, directionCode:directionCode, model:type}; + commitOperate(menuOperate.CTC.modifyDispatcherLogerRpDirection, params, 3).then(({valid, response})=>{ + if (valid) { + const reslut = response.data; + this.tableData.map(data=>{ + if (data.stationCode == reslut.stationCode && data.runPlanCode == reslut.runPlanCode) { + data.arriveDirectionCode = reslut.arriveDirectionCode; + data.departDirectionCode = reslut.departDirectionCode; + } + }); + } + }).catch(() => { + // this.$message.error('发布失败'); + }); + }, + // 调度台行车计划修改时间 + modifyDispatcherLogerRpPlanTime(row, planTime, type) { + const params = {stationCode:row.stationCode, runPlanCode:row.runPlanCode, planTime:planTime, model:type}; + commitOperate(menuOperate.CTC.modifyDispatcherLogerRpPlanTime, params, 3).then(({valid, response})=>{ + if (valid) { + const reslut = response.data; + this.tableData.map(data=>{ + if (data.stationCode == reslut.stationCode && data.runPlanCode == reslut.runPlanCode) { + data.arrivePlanTime = reslut.arrivePlanTime; + data.departPlanTime = reslut.departPlanTime; + } + }); + } + }).catch(() => { + // this.$message.error('发布失败'); + }); + }, + // 修改发车时间 modifyDispatcherLogerRpSection(row, sectionCode, type) { // stationCode 车站编码 // runPlanCode 运行计划编码 @@ -304,7 +388,7 @@ export default { addRunplan() { this.$refs.addDispatcherLogerRunplan.doShow({ filterSectionList:this.filterSectionList, - mapStationDirectionMap:this.mapStationDirectionData + mapStationDirectionList:this.mapStationDirectionData }); }, selectedTripNumber(row, column, cell, event) { diff --git a/src/views/dispatcherStationManage/cmdManage.vue b/src/views/dispatcherStationManage/cmdManage.vue index dbfb0745c..8086ed8d9 100644 --- a/src/views/dispatcherStationManage/cmdManage.vue +++ b/src/views/dispatcherStationManage/cmdManage.vue @@ -26,14 +26,18 @@
收令箱
- + - + + + @@ -153,22 +157,9 @@ export default { }, getTableData() { const receiverList = Object.values(this.currentInfo.receiverInfos || {}); - const mList = []; - receiverList.forEach(ii => { - const obj = this.memberList.find(item => { - return item.id == ii.receiverId; - }); - if (obj) { - mList.push({ - commandId: this.commandId, - ...ii, - ...obj - }); - } - }); const list = []; - mList.forEach(item => { - const device = this.$store.getters['map/getDeviceByCode'](item.deviceCode); + receiverList.forEach(item => { + const device = this.$store.getters['map/getDeviceByCode'](item.receiverId); const obj = { ...this.currentInfo, ...item, @@ -201,6 +192,7 @@ export default { return 'unsigned-row'; }, doShow() { + this.searchCmd(); this.dialogShow = true; this.$store.commit('socket/clearDispatchCommandMsg'); }, @@ -209,9 +201,30 @@ export default { }, handleCurrentChange(obj) { this.currentInfo = obj; + if (!this.getSignInfo(obj.receiverInfos).receivedTime) { + const data = { + commandId: obj.id + }; + sendCommandNew(this.group, 'CTC_READ_DISPATCH_COMMAND', data).then((res) => { + console.log(res, '---res'); + const index = this.cmdTableData.findIndex(item => { + return item.id == obj.id; + }); + if (index >= 0) { + const obj = this.cmdTableData[index]; + const devCode = this.getActiveUser.deviceCode || ''; + if (obj.receiverInfos[devCode]) { + obj.receiverInfos[devCode].receivedTime = parseTime(this.initTime); + this.cmdTableData.splice(index, 1, obj); + } + } + }).catch(error => { + console.log(error, '---已读命令error'); + }); + } }, getSignInfo(info) { - const obj = info[this.getActiveUser.memberId] || {}; + const obj = info[this.getActiveUser.deviceCode] || {}; return obj; }, getSignedBy(info) { @@ -241,20 +254,40 @@ export default { this.$messageBox(`${this.signedStatusObj[status]}调度命令失败:${error.message}`); }); }, + changeReadStatus(signInfo) { + const index = this.cmdTableData.findIndex(item => { + return item.id == signInfo.commandId; + }); + if (index >= 0) { + const obj = this.cmdTableData[index]; + const devCode = this.getActiveUser.deviceCode || ''; + if (obj.receiverInfos[devCode]) { + const mId = signInfo.signedBy; + obj.receiverInfos[devCode].signedBy = mId; + obj.receiverInfos[devCode].signedStatus = signInfo.signedStatus; + obj.receiverInfos[devCode].time = parseTime(this.initTime); + this.cmdTableData.splice(index, 1, obj); + } + } + }, changeSignedStatus(signInfo) { const index = this.cmdTableData.findIndex(item => { return item.id == signInfo.commandId; }); if (index >= 0) { const obj = this.cmdTableData[index]; - const mId = signInfo.signedBy; - obj.receiverInfos[mId].signedBy = mId; - obj.receiverInfos[mId].signedStatus = signInfo.signedStatus; - obj.receiverInfos[mId].time = parseTime(this.initTime); - this.cmdTableData.splice(index, 1, obj); + const devCode = this.getActiveUser.deviceCode || ''; + if (obj.receiverInfos[devCode]) { + const mId = signInfo.signedBy; + obj.receiverInfos[devCode].signedBy = mId; + obj.receiverInfos[devCode].signedStatus = signInfo.signedStatus; + obj.receiverInfos[devCode].time = parseTime(this.initTime); + this.cmdTableData.splice(index, 1, obj); + } } }, searchCmd() { + this.cmdTableData = []; sendCommandNew(this.group, 'CTC_QUERY_DISPATCH_COMMAND').then((res) => { console.log(res, '---res'); if (res.code == 200) { diff --git a/src/views/dispatcherStationManage/dispatchCmd.vue b/src/views/dispatcherStationManage/dispatchCmd.vue index 53b3c352f..5d2c0586a 100644 --- a/src/views/dispatcherStationManage/dispatchCmd.vue +++ b/src/views/dispatcherStationManage/dispatchCmd.vue @@ -19,7 +19,132 @@
- 新建调度命令 + +
+ + + + + + 小时 +
+ {{ getSimulationTime }} +
+
+ + 刷新 + 新建调度命令 +
+
+
+
缓存命令
+
+ + +
+
+
+ + + + + + + + + + + + + + +
+
+
+
接受命令
+
+ + +
+
+
+ + + + + + + + + + + + + +
+
+
+
发送命令
+
+ + +
+
+
+ + + + + + + + + + + + + + +
+
+
+
签收完成
+
+ + +
+
+
+ + + + + + + + + + + + + +
@@ -126,7 +251,7 @@
- +
@@ -139,15 +264,23 @@
- - - + - - + + + + + + + +
@@ -169,6 +302,7 @@ + + diff --git a/src/views/newMap/mapDraftPicture/createPicture.vue b/src/views/newMap/mapDraftPicture/createPicture.vue new file mode 100644 index 000000000..e4ca7d6fa --- /dev/null +++ b/src/views/newMap/mapDraftPicture/createPicture.vue @@ -0,0 +1,88 @@ + + + + + diff --git a/src/views/newMap/mapDraftPicture/index.vue b/src/views/newMap/mapDraftPicture/index.vue index e08374c54..179f22d42 100644 --- a/src/views/newMap/mapDraftPicture/index.vue +++ b/src/views/newMap/mapDraftPicture/index.vue @@ -24,30 +24,37 @@ :selected="selected" :map-saveing="mapSaveing" @saveMapEvent="saveMapEvent" - @updateMapModel="updateMapModel" + @createPicture="createPicture" + @changePicture="changePicture" @setCenter="setCenter" />
+ +
- diff --git a/src/views/newMap/trainTicket/greenLicence.vue b/src/views/newMap/trainTicket/greenLicence.vue index b6caa44d4..74e91c188 100644 --- a/src/views/newMap/trainTicket/greenLicence.vue +++ b/src/views/newMap/trainTicket/greenLicence.vue @@ -20,7 +20,7 @@ 线上发车。
-
{{ showCentralizedStationName }}(站名印)车站值班员(签名)
+
{{ greenLicenseForm.stationSeal }}(站名印)车站值班员(签名)
@@ -31,6 +31,18 @@
日填发
+
+ + + + 给予 +
@@ -46,15 +58,30 @@ export default { type: Boolean, required: true }, - showCentralizedStationName: { - type: String, - required: true + giveMemberList: { + type: Array, + default() { + return []; + } } }, data() { return { - + memberId: '' }; + }, + computed: { + userId() { + return this.$store.state.user ? this.$store.state.user.id : ''; + } + }, + methods: { + giveTicket() { + if (this.memberId) { + this.$emit('giveTicket', { ticketId: this.greenLicenseForm.id, memberId: this.memberId }); + this.memberId = ''; + } + } } }; diff --git a/src/views/newMap/trainTicket/index.vue b/src/views/newMap/trainTicket/index.vue index 114fe6ae0..1e2577217 100644 --- a/src/views/newMap/trainTicket/index.vue +++ b/src/views/newMap/trainTicket/index.vue @@ -25,8 +25,8 @@ - - + +
提交
@@ -34,17 +34,17 @@
@@ -132,6 +132,7 @@ import {menuOperate, commitOperate} from '@/jmapNew/theme/components/utils/menuO import RailTicket from './trainTicket'; import GreenLicence from './greenLicence'; import RedLicence from './redLicence'; +import { EventBus } from '@/scripts/event-bus'; export default { name: 'Index', components: { @@ -146,13 +147,14 @@ export default { railTicketList: [], greenLicenseList: [], redLicenseList: [], + giveMemberList: [], activeName: 'first', ticketForm: { number: '', tripNumber: '', station: '', nextStation: '', - stationSeal: true, + stationSeal: '', no: '', deputy: false }, @@ -161,7 +163,7 @@ export default { reason: '', tripNumber: '', line: '', - stationSeal: true, + stationSeal: '', signature: '', year: '', moon: '', @@ -183,7 +185,7 @@ export default { noticeHour2: '', noticeMinute2: '', noticeTripNumber2: '', - stationSeal: true, + stationSeal: '', signature: '', year: '', moon: '', @@ -205,21 +207,37 @@ export default { computed: { ...mapGetters('map', [ 'stationList' - ]), - showCentralizedStationName() { - if (this.$store.state.map.showCentralizedStationCode) { - const station = this.$store.getters['map/getDeviceByCode'](this.$store.state.map.showCentralizedStationCode); - if (station) { return station.name; } else { return ''; } - } else { return ''; } + ]) + }, + watch: { + '$store.state.map.showCentralizedStationCode': function (val) { + const station = this.$store.getters['map/getDeviceByCode'](val); + if (station) { + this.ticketForm.station = station.name; + this.ticketForm.stationSeal = station.name; + this.greenLicenseForm.stationSeal = station.name; + this.redLicenseForm.stationSeal = station.name; + } } }, + mounted() { + EventBus.$on('trainTicketMember', (memberList) => { + this.giveMemberList = memberList; + }); + }, methods: { doClose() { this.trainTicketShow = false; }, doShow() { this.trainTicketShow = true; - this.ticketForm.station = this.showCentralizedStationName; + const station = this.$store.getters['map/getDeviceByCode'](this.$store.state.map.showCentralizedStationCode); + if (station) { + this.ticketForm.station = station.name; + this.ticketForm.stationSeal = station.name; + this.greenLicenseForm.stationSeal = station.name; + this.redLicenseForm.stationSeal = station.name; + } }, handleClick() { if (this.activeName === 'second') { @@ -232,11 +250,12 @@ export default { } }, clearData() { - this.ticketForm = {number: '', tripNumber: '', station: '', nextStation: '', stationSeal: true, no: '', deputy: false}; - this.greenLicenseForm = {number: '', reason: '', tripNumber: '', line: '', stationSeal: true, signature: '', year: '', moon: '', day: '' }; + const station = this.$store.getters['map/getDeviceByCode'](this.$store.state.map.showCentralizedStationCode) || {}; + this.ticketForm = {number: '', tripNumber: '', station: station.name, nextStation: '', stationSeal: station.name, no: '', deputy: false}; + this.greenLicenseForm = {number: '', reason: '', tripNumber: '', line: '', stationSeal: station.name, signature: '', year: '', moon: '', day: '' }; this.redLicenseForm = {number: '', licenseReceived: true, licenseTripNumber: '', licenseStation: '', licenseNextStation: '', licenseHour: '', licenseMinute: '', licenseTripNumber2: '', noticeTripNumber: '', noticeHour1: '', noticeMinute1: '', noticeTripNumber1: '', noticeHour2: '', - noticeMinute2: '', noticeTripNumber2: '', stationSeal: true, signature: '', year: '', moon: '', day: ''}; + noticeMinute2: '', noticeTripNumber2: '', stationSeal: station.name, signature: '', year: '', moon: '', day: ''}; }, query() { const params = { type: this.attachmentType }; @@ -265,10 +284,18 @@ export default { } commitOperate(menuOperate.Rail.railFillInTicket, params, 3).then(({valid, operate})=>{ this.clearData(); - this.ticketForm.station = this.showCentralizedStationName; + this.$message.success('提交路票成功!'); }).catch(()=>{ this.$message.error('提交路票失败!'); }); + }, + giveTicket(params) { + commitOperate(menuOperate.Rail.railGiveTicketTo, params, 3).then(({valid, operate}) => { + this.$message.success('给予路票成功!'); + this.query(); + }).catch(()=> { + this.$message.error('给予路票失败!'); + }); } } }; diff --git a/src/views/newMap/trainTicket/redLicence.vue b/src/views/newMap/trainTicket/redLicence.vue index 79cbc8d72..b7db04b4b 100644 --- a/src/views/newMap/trainTicket/redLicence.vue +++ b/src/views/newMap/trainTicket/redLicence.vue @@ -20,11 +20,11 @@ 分发出的第 次列车,邻站到达通知 - - - - - 收到 + + + + + 收到
通     知     书
@@ -48,7 +48,7 @@ 次列车。
-
{{ showCentralizedStationName }}(站名印)车站值班员(签名)
+
{{ redLicenseForm.stationSeal }}(站名印)车站值班员(签名)
@@ -59,6 +59,18 @@
日填发
+
+ + + + 给予 +
@@ -74,15 +86,30 @@ export default { type: Boolean, required: true }, - showCentralizedStationName: { - type: String, - required: true + giveMemberList: { + type: Array, + default() { + return []; + } } }, data() { return { - + memberId: '' }; + }, + computed: { + userId() { + return this.$store.state.user ? this.$store.state.user.id : ''; + } + }, + methods: { + giveTicket() { + if (this.memberId) { + this.$emit('giveTicket', { ticketId: this.redLicenseForm.id, memberId: this.memberId }); + this.memberId = ''; + } + } } }; diff --git a/src/views/newMap/trainTicket/ticketInfo.vue b/src/views/newMap/trainTicket/ticketInfo.vue new file mode 100644 index 000000000..3cf6d53a3 --- /dev/null +++ b/src/views/newMap/trainTicket/ticketInfo.vue @@ -0,0 +1,90 @@ + + + + + diff --git a/src/views/newMap/trainTicket/trainTicket.vue b/src/views/newMap/trainTicket/trainTicket.vue index 5f96d4e07..e1f159717 100644 --- a/src/views/newMap/trainTicket/trainTicket.vue +++ b/src/views/newMap/trainTicket/trainTicket.vue @@ -25,14 +25,23 @@
-
{{ ticketForm.station }}(站名印)
+
{{ ticketForm.stationSeal }}(站名印)
编号
-
- +
+ + + + 给予
@@ -52,12 +61,31 @@ export default { stationList: { type: Array, required: true + }, + giveMemberList: { + type: Array, + default() { + return []; + } } }, data() { return { - + memberId: '' }; + }, + computed: { + userId() { + return this.$store.state.user ? this.$store.state.user.id : ''; + } + }, + methods: { + giveTicket() { + if (this.memberId) { + this.$emit('giveTicket', { ticketId: this.ticketForm.id, memberId: this.memberId }); + this.memberId = ''; + } + } } };