diff --git a/src/api/assist.js b/src/api/assist.js new file mode 100644 index 000000000..09791c67d --- /dev/null +++ b/src/api/assist.js @@ -0,0 +1,36 @@ +import request from '@/utils/request'; + +// 查询指示灯关联信息列表 +export function queryAssistListPaged(params, mapId) { + return request({ + // url: `/api/assist/indicator/section/list/${mapId}`, + url: `/api/station/direction/list/${mapId}`, + method: 'get', + params + }); +} +// 根据id查询单个指示灯关联信息 +export function queryAssistById(mapId){ + return request({ + // url: `/api/assist/indicator/section/${id}`, + url: `/api/station/direction/${mapId}`, + method: 'get' + }) +} +// 保存指示灯关联信息 +export function saveAssist(data, mapId) { + return request({ + // url: `/api/assist/indicator/section/save/${mapId}`, + url: `/api/station/direction/save/${mapId}`, + method: 'post', + data + }) +} +// 删除指示灯关联关系 +export function deleteAssist(id) { + return request({ + // url: `/api/assist/indicator/section/delete/${id}`, + url: `/api/station/direction/delete/${id}`, + method: 'delete' + }) +} diff --git a/src/api/jmap/mapdraft.js b/src/api/jmap/mapdraft.js index b98648520..ef7de6b20 100644 --- a/src/api/jmap/mapdraft.js +++ b/src/api/jmap/mapdraft.js @@ -743,3 +743,10 @@ export function generateDepotCiData(mapId, stationCode) { method: 'post' }); } +// 大铁线路批量生成进路 +export function generateRoute(mapId) { + return request({ + url: `/api/draftMap/${mapId}/route/railway/generate`, + method: 'post' + }); +} diff --git a/src/assets/datie/arrow.png b/src/assets/datie/arrow.png new file mode 100644 index 000000000..2d5169ba7 Binary files /dev/null and b/src/assets/datie/arrow.png differ diff --git a/src/assets/datie/camera.png b/src/assets/datie/camera.png new file mode 100644 index 000000000..93a846223 Binary files /dev/null and b/src/assets/datie/camera.png differ diff --git a/src/assets/datie/controlPanel.png b/src/assets/datie/controlPanel.png new file mode 100644 index 000000000..ab644a275 Binary files /dev/null and b/src/assets/datie/controlPanel.png differ diff --git a/src/assets/datie/controlPanel2.png b/src/assets/datie/controlPanel2.png new file mode 100644 index 000000000..73e212692 Binary files /dev/null and b/src/assets/datie/controlPanel2.png differ diff --git a/src/assets/datie/link.png b/src/assets/datie/link.png new file mode 100644 index 000000000..c29f30344 Binary files /dev/null and b/src/assets/datie/link.png differ diff --git a/src/assets/datie/picT3.png b/src/assets/datie/picT3.png new file mode 100644 index 000000000..377ee83e0 Binary files /dev/null and b/src/assets/datie/picT3.png differ diff --git a/src/assets/datie/train.png b/src/assets/datie/train.png new file mode 100644 index 000000000..99ef4e2d0 Binary files /dev/null and b/src/assets/datie/train.png differ diff --git a/src/jmapNew/config/skinCode/datie_02.js b/src/jmapNew/config/skinCode/datie_02.js index f05984fb4..f303b3f28 100644 --- a/src/jmapNew/config/skinCode/datie_02.js +++ b/src/jmapNew/config/skinCode/datie_02.js @@ -430,6 +430,8 @@ class SkinCode extends defaultStyle { veryControl: { show: true, offset: { x: 0, y: 0 }, + lightColor: '#f00', + defaultColor: '#7F7F7F', text: '非常站控' }, selfDiscipline: { @@ -440,11 +442,15 @@ class SkinCode extends defaultStyle { selfDisciplineControl: { show: true, offset: { x: 0, y: 0 }, + lightColor: '#0f0', + defaultColor: '#7F7F7F', text: '自律控制' }, veryControlButton: { offset: { x: 0, y: 0 }, - text: '非常站控' + text: '非常站控', + lightColor: '#ff0', + defaultColor: '#ccc', } } }; @@ -794,7 +800,9 @@ class SkinCode extends defaultStyle { ], // 特殊列车类型需设置显示格式 lrPadding: 4, // 两边间隔 upPadding: 4, // 上边距离 - trainBodyFillColor: '#000099', // 列车车身填充颜色 + trainBodyFillColor: '#88DF8E', // 列车车身填充颜色 + trainSidelineColor: '#F00', + trainSidelineStopColor: '#000', trainNameFormat: 'serviceNumber:targetCode'// 列车显示格式 }, directionArrow: { @@ -804,7 +812,7 @@ class SkinCode extends defaultStyle { trainBody: true, earlyColor: '#00FF00', lateColor: '#800000', - normalColor: '#FFF' + normalColor: '#F00' }, hsda: { lrPaddingHSDA: 3, // HSDA两边间隔 @@ -818,13 +826,15 @@ class SkinCode extends defaultStyle { trainNumber: { targetCodePrefix: '000', // 目的地码前缀 defaultTargetCode: 'DDD', // 默认目的地码 - trainTargetTextAlign: 'left', // 目的地码文字显示位置 + fontColor: '#F00', + trainTargetTextAlign: 'left', // 目的地码文字显示位置 trainNumberOffset: { x: 24, y: 4}// 目的地码偏移量 }, trainServer: { serviceNumberPrefix: '000', // 服务号(表号)前缀 defaultServiceNumber: 'TTT', // 默认服务号(表号) - defaultServerNoColor: '#FFFFFF', // 默认服务号状态显示颜色 + defaultServerNoColor: '#F00', // 默认服务号状态显示颜色 + fontColor: '#F00', trainServerOffset: { x: 4, y: 4} // 列车服务号偏移 }, trainTarget: { @@ -839,21 +849,23 @@ class SkinCode extends defaultStyle { trainTargetNumberOffset: {x: -4, y: 4}// 车组号偏移量 }, trainHead: { - trainConntWidth: 3, // 列车竖杠的宽度 - trainHeadFillColor: '#000000', // 列车车头矩形填充颜色 + trainConntWidth: 10, // 列车竖杠的宽度 + trainHeadFillColor: '#189B4D', // 列车车头矩形填充颜色 + trainHeadRectNoChange: true, // 列车车头矩形填充颜色不变 trainHeadRectHeight: 20, // 列车车头矩形高度 - directionStopType:'normal', // special 西安二号线 停车 列车方向图标不消失 normal 正常 + directionStopType:'specialAll', // special 西安二号线 停车 列车方向图标不消失 normal 正常 trainHeadHeight: 'trainBox', // 列车车头高度取决于trainBox高度 - trainHeadArrowWidth: 6, // 列车车头三角宽度 - trainHeadArrowOffsetX: 5 // 列车车头三角偏移 + trainHeadArrowWidth: 15, // 列车车头三角宽度 + trainHeadArrowOffsetX: 0, // 列车车头三角偏移 + trainHeadRectOffsetX: 10 }, common: { trainHeight: 20, // 列车高度 - trainHeadDistance: 4, // 列车和车头之间的间距 + trainHeadDistance: 2, // 列车和车头之间的间距 trainWidth: 48, // 列车长度 trainTextFontSize: 12, // 列车字号 fontFamily: 'consolas', // 默认字体 族类 - haveTextHSDA: true, // 是否需创建textHSDA对象 + haveTextHSDA: false, // 是否需创建textHSDA对象 haveArrowText: true, // 是否需创建arrowText对象 textOffset: 4, // 字体偏移(用以控制字体据车头的距离) trainWidthMoreText: 8, // 计算列车长度时--列车长比text多出尺寸 @@ -878,7 +890,7 @@ class SkinCode extends defaultStyle { directionType: [ { type: 1, - lineLShow: false, + lineLShow: true, lineRShow: true, arrowLShow: false, arrowRShow: true @@ -886,7 +898,7 @@ class SkinCode extends defaultStyle { { type: 0, lineLShow: true, - lineRShow: false, + lineRShow: true, arrowLShow: true, arrowRShow: false } @@ -894,13 +906,17 @@ class SkinCode extends defaultStyle { directionStopType: [ { type: 1, - lineLShow: false, - lineRShow: true + lineLShow: true, + arrowLShow: false, + lineRShow: false, + arrowRShow: true }, { type: 0, - lineLShow: true, - lineRShow: false + lineLShow: false, + arrowLShow: true, + lineRShow: true, + arrowRShow: false } ], // 列车停止方向类型对应车头显示状态 1从左往右 0从右往左 driveModeStatus: [ @@ -916,8 +932,8 @@ class SkinCode extends defaultStyle { }, { status: 'RM', - trainLColor: '#C2C2C2', - trainRColor: '#C2C2C2' + trainLColor: '#fff', + trainRColor: '#fff' }, { status: 'NRM', @@ -947,16 +963,35 @@ class SkinCode extends defaultStyle { fontFamily:'宋体' } }; - this[deviceType.PickOrDepartArrow] = { - triangleLength: 10, - lineWidth: 4, - length: 20, + this[deviceType.DepartArrow] = { + triangleLength: 15, + lineWidth: 8, + length: 35, distance: 15, fill: '#000', stroke: '#fff', fontSize: 11, - defaultText: '接发车', - defaultColor: '#ccc' + defaultText: '发车', + defaultColor: '#ccc', + occupiedColor:'#f00', + noOccupiedColor:'#00ff00', + blockStatusColor:'#00ff00', + noBlockStatusColor:'#ffff00', + }; + this[deviceType.PickArrow] = { + triangleLength: 15, + lineWidth: 8, + length: 35, + distance: 15, + fill: '#000', + stroke: '#fff', + fontSize: 11, + defaultText: '接车', + defaultColor: '#ccc', + occupiedColor:'#f00', + noOccupiedColor:'#ffff00', + blockStatusColor:'#00ff00', + noBlockStatusColor:'#ffff00', }; this[deviceType.Occlusion] = { text: { @@ -1032,7 +1067,8 @@ class SkinCode extends defaultStyle { }, lamp: { radiusR: 6, - controlColor: '#ccc' + controlColor: '#ccc', + occupiedColor:'#ffffff', } }; this[deviceType.SectionOccupied] = { @@ -1043,7 +1079,8 @@ class SkinCode extends defaultStyle { }, lamp: { radiusR: 6, - controlColor: '#ccc' + controlColor: '#ccc', + occupiedColor:'#ff0000', } }; } diff --git a/src/jmapNew/config/skinCode/xian_02.js b/src/jmapNew/config/skinCode/xian_02.js index 091a11515..7e631f9b2 100644 --- a/src/jmapNew/config/skinCode/xian_02.js +++ b/src/jmapNew/config/skinCode/xian_02.js @@ -810,12 +810,16 @@ class SkinCode extends defaultStyle { { type: 1, lineLShow: false, - lineRShow: true + arrowLShow: false, + lineRShow: false, + arrowRShow: true, }, { type: 0, - lineLShow: true, - lineRShow: false + lineLShow: false, + arrowLShow: true, + lineRShow: false, + arrowRShow: false, } ], // 列车停止方向类型对应车头显示状态 1从左往右 0从右往左 driveModeStatus: [ diff --git a/src/jmapNew/constant/deviceRender.js b/src/jmapNew/constant/deviceRender.js index c8cf5434e..e859ef897 100644 --- a/src/jmapNew/constant/deviceRender.js +++ b/src/jmapNew/constant/deviceRender.js @@ -285,9 +285,14 @@ deviceRender[deviceType.IndicatorLight] = { _type: deviceType.IndicatorLight, zlevel: 1 }; -/** 接发车指示灯 */ -deviceRender[deviceType.PickOrDepartArrow] = { - _type: deviceType.PickOrDepartArrow, +/** 接车指示灯 */ +deviceRender[deviceType.PickArrow] = { + _type: deviceType.PickArrow, + zlevel: 1 +}; +/** 发车指示灯 */ +deviceRender[deviceType.DepartArrow] = { + _type: deviceType.DepartArrow, zlevel: 1 }; /** 区间占用 区间监控 */ diff --git a/src/jmapNew/constant/deviceType.js b/src/jmapNew/constant/deviceType.js index 88359412a..9904005df 100644 --- a/src/jmapNew/constant/deviceType.js +++ b/src/jmapNew/constant/deviceType.js @@ -51,7 +51,8 @@ const deviceType = { DirectionRod: 'DirectionRod', Responder: 'Responder', SignalButton: 'SignalButton', - PickOrDepartArrow: 'PickOrDepartArrow', + PickArrow: 'PickArrow', + DepartArrow: 'DepartArrow', Occlusion: 'Occlusion', Accident: 'Accident', Recovery: 'Recovery', diff --git a/src/jmapNew/map.js b/src/jmapNew/map.js index 48d4cd0b1..956be2648 100644 --- a/src/jmapNew/map.js +++ b/src/jmapNew/map.js @@ -471,6 +471,101 @@ class Jlmap { } } store.commit('map/mapStationStateUpdate'); + } else if (elem.deviceType === 'STATION_DIRECTION') { + const mapStationDirectionData = store.state.map.mapStationDirectionData; + // 大铁项目 车站方向 + const directionData = mapStationDirectionData[code]; + // store.state.map.map.indicatorLightList; + // 改方按钮状态 + const signalButtonList = store.state.map.map.signalButtonList; + const selectButtonList = signalButtonList.filter(elem=>{ + return elem.labelEnum === directionData.labelEnum && elem.stationCode == directionData.stationCode; + }); + const selectMap = {'ASSIST':'mainAssistStatus', + 'PICK_ASSIST':'receiveAssistStatus', + 'DEPART_ASSIST':'deliverAssistStatus', + 'CHANGE_DIRECTION':'changeDirectionStatus', + // 闭塞按钮 + 'OCCLUSION':'blockStatus', + // 事故按钮 + 'ACCIDENT':'accidentStatus', + // 复原按钮 + 'RECOVERY':'restoreStatus' + }; + // { value: 'ASSIST', label: '总辅助按钮' }, + // { value: 'PICK_ASSIST', label: '接辅助按钮' }, + // { value: 'DEPART_ASSIST', label: '发辅助按钮' }, + selectButtonList.forEach(each=>{ + const buttonModel = this.mapDevice[each.code]; + const selectedStatus = selectMap[buttonModel.type]; + if (selectedStatus != undefined && elem[selectedStatus] != undefined) { + buttonModel.pressDown = elem[selectedStatus]; + this.$painter.update(buttonModel); + } + }); + + // 接车 发车 区间占用 辅助状态 + const indicatorLightList = store.state.map.map.indicatorLightList; + const indicatorList = indicatorLightList.filter(elem=>{ + return elem.labelEnum === directionData.labelEnum && elem.stationCode == directionData.stationCode; + }); + indicatorList.forEach(each=>{ + const model = this.mapDevice[each.code]; + switch (each._type) { + case 'PickArrow': { + // 接车灯状态 + if (elem.runStatus != undefined || model.runStatus != undefined) { + if (elem.runStatus) { model.runStatus = elem.runStatus; } + if (elem.runModel) { model.runModel = elem.runModel; } + if (elem.receiveAspect != undefined) { + model.aspect = elem.receiveAspect; + } + if (elem.readyStatus != undefined ) { + model.readyStatus = elem.readyStatus; + } + this.$painter.update(model); + } + break; + } + case 'DepartArrow': { + // 发车灯状态 + if (elem.runStatus != undefined || model.runStatus != undefined) { + if (elem.runStatus) { model.runStatus = elem.runStatus; } + if (elem.runModel) { model.runModel = elem.runModel; } + if (elem.deliverAspect != undefined) { + model.aspect = elem.deliverAspect; + } + if (elem.readyStatus != undefined ) { + model.readyStatus = elem.readyStatus; + } + this.$painter.update(model); + } + break; + } + case 'SectionOccupied': { + // 区间占用 + if (elem.sectionAspect != undefined) { + model.aspect = elem.sectionAspect; + this.$painter.update(model); + } + break; + } + case 'AssistStatus': { + // 辅助状态 + if (elem.assistAspect != undefined) { + model.aspect = elem.assistAspect; + this.$painter.update(model); + } + break; + } + default: + break; + } + }); + // { name: '总辅助', value: 'TotalAssist' }, + // { name: '发车辅助', value: 'DepartAssist' }, + // { name: '接车辅助', value: 'PickAssist' }, + } else { if (elem.deviceType === 'TRAIN') { this.isUpdateShowTrainList = true; diff --git a/src/jmapNew/parser/parser-graph.js b/src/jmapNew/parser/parser-graph.js index ba73b2e75..ec111bc16 100644 --- a/src/jmapNew/parser/parser-graph.js +++ b/src/jmapNew/parser/parser-graph.js @@ -350,7 +350,8 @@ export function updateMapData(state, model) { case deviceType.Axle: updateForList(model, state, 'indicatorLightList'); break; case deviceType.SwitchFault: updateForList(model, state, 'indicatorLightList'); break; case deviceType.IndicatorLight: updateForList(model, state, 'indicatorLightList'); break; - case deviceType.PickOrDepartArrow: updateForList(model, state, 'indicatorLightList'); break; + case deviceType.PickArrow: updateForList(model, state, 'indicatorLightList');break; + case deviceType.DepartArrow: updateForList(model, state, 'indicatorLightList'); break; case deviceType.Occlusion: updateForList(model, state, 'indicatorLightList'); break; case deviceType.Accident: updateForList(model, state, 'indicatorLightList'); break; case deviceType.Recovery: updateForList(model, state, 'indicatorLightList'); break; diff --git a/src/jmapNew/shape/graph/SaidLamp/EAxle.js b/src/jmapNew/shape/graph/SaidLamp/EAxle.js index 8ac219f93..835a22106 100644 --- a/src/jmapNew/shape/graph/SaidLamp/EAxle.js +++ b/src/jmapNew/shape/graph/SaidLamp/EAxle.js @@ -73,4 +73,7 @@ export default class EAxle extends Group { this.add(this.arc1); this.add(this.arc2); } + + recover() { + } } diff --git a/src/jmapNew/shape/graph/SaidLamp/EControlSwitch.js b/src/jmapNew/shape/graph/SaidLamp/EControlSwitch.js index 764e64818..55d5fdc79 100644 --- a/src/jmapNew/shape/graph/SaidLamp/EControlSwitch.js +++ b/src/jmapNew/shape/graph/SaidLamp/EControlSwitch.js @@ -14,4 +14,7 @@ export default class EControlSwitch extends Group { this.path = createPathSvg(this.model); this.add(this.path); } + + recover() { + } } diff --git a/src/jmapNew/shape/graph/SaidLamp/EDeviceStatus.js b/src/jmapNew/shape/graph/SaidLamp/EDeviceStatus.js index f1379d572..f9315e9fe 100644 --- a/src/jmapNew/shape/graph/SaidLamp/EDeviceStatus.js +++ b/src/jmapNew/shape/graph/SaidLamp/EDeviceStatus.js @@ -136,4 +136,7 @@ export default class EDeviceStatus extends Group { // this.add(this.pfa); // this.add(this.pfb); } + + recover() { + } } diff --git a/src/jmapNew/shape/graph/SaidLamp/EFoldbackMode.js b/src/jmapNew/shape/graph/SaidLamp/EFoldbackMode.js index f74c838dd..2cd31893c 100644 --- a/src/jmapNew/shape/graph/SaidLamp/EFoldbackMode.js +++ b/src/jmapNew/shape/graph/SaidLamp/EFoldbackMode.js @@ -124,4 +124,7 @@ export default class EFoldbackMode extends Group { this.add(this.lateralLineRect); this.add(this.lateralLine); } + + recover() { + } } diff --git a/src/jmapNew/shape/graph/SaidLamp/EIndicatorLight.js b/src/jmapNew/shape/graph/SaidLamp/EIndicatorLight.js index a5ba63843..b53eee65e 100644 --- a/src/jmapNew/shape/graph/SaidLamp/EIndicatorLight.js +++ b/src/jmapNew/shape/graph/SaidLamp/EIndicatorLight.js @@ -80,4 +80,7 @@ export default class IndicatorLight extends Group { setControlColor(color) { this.indicator.setStyle({fill: color}); } + + recover() { + } } diff --git a/src/jmapNew/shape/graph/SaidLamp/ELampFilament.js b/src/jmapNew/shape/graph/SaidLamp/ELampFilament.js index 266fefbfc..966e325f9 100644 --- a/src/jmapNew/shape/graph/SaidLamp/ELampFilament.js +++ b/src/jmapNew/shape/graph/SaidLamp/ELampFilament.js @@ -17,4 +17,7 @@ export default class ELampFilament extends Group { setControlColor(color) { this.path.setStyle({fill: color}); } + + recover() { + } } diff --git a/src/jmapNew/shape/graph/SaidLamp/EModeStatus.js b/src/jmapNew/shape/graph/SaidLamp/EModeStatus.js index 89b4d1a90..6bea75a44 100644 --- a/src/jmapNew/shape/graph/SaidLamp/EModeStatus.js +++ b/src/jmapNew/shape/graph/SaidLamp/EModeStatus.js @@ -77,4 +77,7 @@ export default class EDeviceStatus extends Group { this.add(this.stationCommunication); this.add(this.verifyBypass); } + + recover() { + } } diff --git a/src/jmapNew/shape/graph/SaidLamp/EPickOrDepartArrow.js b/src/jmapNew/shape/graph/SaidLamp/EPickOrDepartArrow.js index 1af75865e..3cf04a426 100644 --- a/src/jmapNew/shape/graph/SaidLamp/EPickOrDepartArrow.js +++ b/src/jmapNew/shape/graph/SaidLamp/EPickOrDepartArrow.js @@ -3,54 +3,78 @@ import Text from 'zrender/src/graphic/Text'; import Polygon from 'zrender/src/graphic/shape/Polygon'; export default class EPickOrDepartArrow extends Group { - constructor(model) { - super(); - this.model = model; - this.zlevel = model.zlevel; - this._subType = model._subType; - this.z = model.z; - this.create(model); - } - create(model) { - const style = this.model.style; - this.arrow = new Polygon({ - zlevel: this.zlevel, - z: this.z, - origin: [model.x + style.PickOrDepartArrow.length/2, model.y], - rotation: model.right ? Math.PI : 0, - shape: { - points: [ - [model.x, model.y], - [model.x + style.PickOrDepartArrow.triangleLength, model.y - style.PickOrDepartArrow.triangleLength / 2], - [model.x + style.PickOrDepartArrow.triangleLength, model.y - style.PickOrDepartArrow.lineWidth / 2], - [model.x + style.PickOrDepartArrow.length, model.y - style.PickOrDepartArrow.lineWidth / 2], - [model.x + style.PickOrDepartArrow.length, model.y + style.PickOrDepartArrow.lineWidth / 2], - [model.x + style.PickOrDepartArrow.triangleLength, model.y + style.PickOrDepartArrow.lineWidth / 2], - [model.x + style.PickOrDepartArrow.triangleLength, model.y + style.PickOrDepartArrow.triangleLength / 2] - ] - }, - style: { - fill: style.PickOrDepartArrow.fill, - stroke: style.PickOrDepartArrow.stroke, - lineWidth: 1 - } - }); - this.arrowText = new Text({ - zlevel: this.zlevel, - z: this.z, - style: { - x: model.x + style.PickOrDepartArrow.length / 2, - y: model.y + style.PickOrDepartArrow.distance, - fontWeight: style.textStyle.fontWeight, - fontSize: style.PickOrDepartArrow.fontSize, - fontFamily: style.fontFamily, - text: model.text, - textFill: style.PickOrDepartArrow.defaultColor, - textAlign: style.textStyle.textAlign, - textVerticalAlign: style.textStyle.textVerticalAlign - } - }); - this.add(this.arrow); - this.add(this.arrowText); - } + constructor(model) { + super(); + this.model = model; + this.zlevel = model.zlevel; + this._subType = model._subType; + this.z = model.z; + this.create(model); + } + create(model) { + const style = this.model.style; + this.arrow = new Polygon({ + zlevel: this.zlevel, + z: this.z, + origin: [model.x + style[this._subType].length / 2, model.y], + rotation: model.right ? Math.PI : 0, + shape: { + points: [ + [model.x, model.y], + [model.x + style[this._subType].triangleLength, model.y - style[this._subType].triangleLength / 2], + [model.x + style[this._subType].triangleLength, model.y - style[this._subType].lineWidth / 2], + [model.x + style[this._subType].length, model.y - style[this._subType].lineWidth / 2], + [model.x + style[this._subType].length, model.y + style[this._subType].lineWidth / 2], + [model.x + style[this._subType].triangleLength, model.y + style[this._subType].lineWidth / 2], + [model.x + style[this._subType].triangleLength, model.y + style[this._subType].triangleLength / 2] + ] + }, + style: { + fill: style[this._subType].fill, + stroke: style[this._subType].stroke, + lineWidth: 1 + } + }); + this.arrowText = new Text({ + zlevel: this.zlevel, + z: this.z, + style: { + x: model.x + style[this._subType].length / 2, + y: model.y + style[this._subType].distance, + fontWeight: style.textStyle.fontWeight, + fontSize: style[this._subType].fontSize, + fontFamily: style.fontFamily, + text: model.text, + textFill: style[this._subType].defaultColor, + textAlign: style.textStyle.textAlign, + textVerticalAlign: style.textStyle.textVerticalAlign + } + }); + this.add(this.arrow); + this.add(this.arrowText); + } + + setControlFlashing(color) { + if (color) { + const style = this.model.style; + this.arrow.animateStyle(true) + .when(0, { fill: style[this._subType].fill }) + .when(1000, { stroke: color }) + .when(2000, { fill: style[this._subType].fill }) + .start(); + } + } + + recover() { + const style = this.model.style; + this.arrow.stopAnimation(false); + this.arrow.setStyle('fill', style[this._subType].fill); + } + + setControlColor(color) { + if (color) { + this.arrow.setStyle('fill', color); + } + + } } diff --git a/src/jmapNew/shape/graph/SaidLamp/EUnmanned.js b/src/jmapNew/shape/graph/SaidLamp/EUnmanned.js index 52ddac674..920860196 100644 --- a/src/jmapNew/shape/graph/SaidLamp/EUnmanned.js +++ b/src/jmapNew/shape/graph/SaidLamp/EUnmanned.js @@ -14,4 +14,7 @@ export default class EUnmanned extends Group { this.path = createPathSvg(this.model); this.add(this.path); } + + recover() { + } } diff --git a/src/jmapNew/shape/graph/SaidLamp/index.js b/src/jmapNew/shape/graph/SaidLamp/index.js index eee827dd9..d5bd1ecb8 100644 --- a/src/jmapNew/shape/graph/SaidLamp/index.js +++ b/src/jmapNew/shape/graph/SaidLamp/index.js @@ -33,8 +33,8 @@ export default class SaidLamp extends Group { create() { const model = this.model; const lampDevice = ['LeuControl', 'IntersiteControl', 'CenterCommunication', 'AtsControl', 'LocalControl', 'ChainControl', 'Maintain', - 'PowerSupply', 'MaintenanceLamps', 'ZcCommunication', 'SwitchFault', 'SectionOccupied', 'AssistStatus', 'TotalAssist', 'DepartAssist', - 'PickAssist', 'Recovery', 'Accident', 'Occlusion']; + 'PowerSupply', 'MaintenanceLamps', 'ZcCommunication', 'SwitchFault', 'SectionOccupied', 'AssistStatus', 'TotalAssist', 'TotalAssist', 'PickAssist', 'Recovery', 'Accident', 'Occlusion']; + if (lampDevice.includes(this._type)) { this.control = new EControl({ zlevel: this.zlevel, @@ -179,19 +179,19 @@ export default class SaidLamp extends Group { _subType: 'IndicatorLight' }); this.add(this.control); - } else if (this._type === 'PickOrDepartArrow') { + } else if (this._type === 'PickArrow' || this._type === 'DepartArrow') { this.control = new EPickOrDepartArrow({ - zlevel: this.zlevel, - z: this.z, - x: model.position.x, - y: model.position.y, - text: model.name, - right: model.right, - style: this.style, - _subType: 'PickOrDepartArrow' - }); - this.add(this.control); - } + zlevel: this.zlevel, + z: this.z, + x: model.position.x, + y: model.position.y, + text: model.name, + right: model.right, + style: this.style, + _subType: this._type + }); + this.add(this.control); + } } // 设置状态 @@ -200,16 +200,89 @@ export default class SaidLamp extends Group { if (!store.getters['map/checkDeviceShow'](this._code)) { this.control && this.control.hide(); } else { + // 区段占用,辅助状态,接发车箭头 + const datieType = [deviceType.SectionOccupied, deviceType.AssistStatus, deviceType.PickArrow, deviceType.DepartArrow]; if (model._type === deviceType.PowerSupply && model.name.includes('2')) { this.control && this.control.setControlColor(this.deviceStyle.lamp.offColor); this.control && this.control.setControlStroke(this.deviceStyle.lamp.strokeColor, 1); } else if ((model._type === deviceType.AtsControl || model._type === deviceType.LocalControl || model._type === deviceType.ChainControl) && model.name.includes('B')) { this.control && this.control.setControlColor(this.deviceStyle.lamp.offColor); + } else if (datieType.includes(model._type)) { + if (model.aspect) { + const signalButtons = [deviceType.PickArrow, deviceType.DepartArrow]; + if (signalButtons.includes(model._type)) { + // if (model.runModel == 'S') { // 闭塞 + // console.log(model.runModel, model.runStatus, model.aspect, model.blockStatus, model._type, '88888888'); + // if (model.runStatus == 'NO') { + // this.control && this.control.setControlColor(this.deviceStyle.fill); + // } else { + // // blockStatus:false * 指示灯(F)的时候为黄色,true为绿色 + // // 指示灯(O)为红色 + // if (model.blockStatus != undefined) { + // if (model.aspect == 'O') { + // this.control && this.control.setControlColor(this.deviceStyle.occupiedColor); + // } else if (model.aspect == 'F') { + // if (model.blockStatus) { + // this.control && this.control.setControlColor(this.deviceStyle.blockStatusColor); + // } else { + // this.control && this.control.setControlColor(this.deviceStyle.noBlockStatusColor); + // } + // } + // } + // } + // } else { + if (model.runStatus == 'A' || (model.runStatus == 'R' && model._type == deviceType.PickArrow ) || (model.runStatus == 'D' && model._type == deviceType.DepartArrow)) { + if (model.runModel == 'S') { + // blockStatus:false * 指示灯(F)的时候为黄色,true为绿色 + // 指示灯(O)为红色 + if (model.readyStatus != undefined) { + if (model.aspect == 'O') { + this.control && this.control.setControlColor(this.deviceStyle.occupiedColor); + } else if (model.aspect == 'F') { + if (model.readyStatus) { + this.control && this.control.setControlColor(this.deviceStyle.blockStatusColor); + } else { + this.control && this.control.setControlColor(this.deviceStyle.noBlockStatusColor); + } + } + } + } else { + // 发车状态:接车灯灭,发车灯默认是绿色,占用时红色 + // 接车状态:发车灯灭,接车灯默认是黄色,占用时红色 + if (model.aspect == 'O') { + this.control && this.control.setControlColor(this.deviceStyle.occupiedColor); + } else if (model.aspect == 'F') { + this.control && this.control.setControlColor(this.deviceStyle.noOccupiedColor); + } + } + + } + // 发车状态----接车灯灭 接车状态-----发车灯灭 + if (model.runStatus == 'NO' || (model.runStatus == 'R' && model._type == deviceType.DepartArrow) || (model.runStatus == 'D' && model._type == deviceType.PickArrow)) { + this.control && this.control.setControlColor(this.deviceStyle.fill); + } + // } + + } else { + switch (model.aspect) { + case 'O': + this.control && this.control.setControlColor(this.deviceStyle.lamp.occupiedColor); + break; + case 'F': + this.control && this.control.setControlColor(this.deviceStyle.lamp.controlColor); + break; + default: + break; + } + } + } + } } } recover() { this.control && this.control.show(); + this.control && this.control.recover(); } createMouseEvent() { if (this.deviceStyle.mouseOverStyle) { diff --git a/src/jmapNew/shape/graph/Section/index.js b/src/jmapNew/shape/graph/Section/index.js index ded68bad7..368b5801d 100644 --- a/src/jmapNew/shape/graph/Section/index.js +++ b/src/jmapNew/shape/graph/Section/index.js @@ -482,6 +482,7 @@ export default class Section extends Group { this.setAshShow(); model.preGreen && this.line.setStyle({stroke: '#00FF00'}); model.preBlue && this.line.setStyle({stroke: '#4A76B7'}); + model.preWhite && this.line.setStyle({stroke: '#fff'}) } else { this.handleSwitchSection(model, flag); // 顺序代表优先级 diff --git a/src/jmapNew/shape/graph/Signal/index.js b/src/jmapNew/shape/graph/Signal/index.js index 153d5e8f3..63b04db42 100644 --- a/src/jmapNew/shape/graph/Signal/index.js +++ b/src/jmapNew/shape/graph/Signal/index.js @@ -697,6 +697,11 @@ class Signal extends Group { } } } + // 双黄灯 + doubleYellow() { + this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.yellowColor); + this.lamps[1] && this.lamps[1].setColor(this.style.Signal.lamp.yellowColor); + } lampWhite() { if (this.lamps.length === 1) { this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.whiteColor); @@ -935,7 +940,7 @@ class Signal extends Group { recover() { this.sigName && this.sigName.show(); this.sigName && this.sigName.setAnimationEnd(); - this.lamps && this.lamps.forEach(item=> { item.show(); item.setGuideSectorShowHide(false); }); + this.lamps && this.lamps.forEach(item=> { item.show(); item.setGuideSectorShowHide(false); item.setBorderColor(this.style.Signal.lamp.borderColor) }); this.sigName.setStyle({ textBorderWidth: 0 }); this.sigName.setColor(this.style.Signal.text.defaultColor); this.remainTimeName && this.remainTimeName.hide(); @@ -984,7 +989,7 @@ class Signal extends Group { if (this.model.signalButtonList && this.model.signalButtonList.length) { this.model.signalButtonList.forEach(item => { const button = store.getters['map/getDeviceByCode'](item); - button && button.instance && button.instance.recover(); + button && button.instance && button.instance.setState({}); }); } } @@ -1042,6 +1047,10 @@ class Signal extends Group { this.lampBlue(); break; } + case 'YY': { + this.doubleYellow(); + break; + } default: { this.close(model.logicLight); // 信号关闭 break; diff --git a/src/jmapNew/shape/graph/SignalButton/index.js b/src/jmapNew/shape/graph/SignalButton/index.js index f7c52d48d..5aedfe2de 100644 --- a/src/jmapNew/shape/graph/SignalButton/index.js +++ b/src/jmapNew/shape/graph/SignalButton/index.js @@ -2,6 +2,7 @@ import Group from 'zrender/src/container/Group'; import Rect from 'zrender/src/graphic/shape/Rect'; import Line from 'zrender/src/graphic/shape/Line'; import Text from 'zrender/src/graphic/Text'; +import Arc from 'zrender/src/graphic/shape/Arc'; import store from '@/store/index'; export default class SignalButton extends Group { @@ -12,7 +13,8 @@ export default class SignalButton extends Group { this.zlevel = model.zlevel; this.z = 0; this.model = model; - this.style = style.Line; + this.style = style; + // Line this.create(); this.setState(model); } @@ -69,7 +71,72 @@ export default class SignalButton extends Group { }); this.add(this.rightLine); this.rightLine.hide(); - if (model.type === 'PASS') { + this.leftBoard = new Line({ + zlevel: this.zlevel, + z: this.z + 1, + shape: { + x1: model.position.x - 1, + y1: model.position.y - 1, + x2: model.position.x - 1, + y2: model.position.y + 15 + }, + style: { + lineWidth: 2, + stroke: '#FFFFFF' + } + }); + this.add(this.leftBoard); + this.leftBoard.hide(); + this.topBoard = new Line({ + zlevel: this.zlevel, + z: this.z + 1, + shape: { + x1: model.position.x - 1, + y1: model.position.y - 1, + x2: model.position.x + 15, + y2: model.position.y - 1 + }, + style: { + lineWidth: 2, + stroke: '#FFFFFF' + } + }); + this.add(this.topBoard); + this.topBoard.hide(); + this.rightBoard = new Line({ + zlevel: this.zlevel, + z: this.z + 1, + shape: { + x1: model.position.x + 15, + y1: model.position.y - 1, + x2: model.position.x + 15, + y2: model.position.y + 15 + }, + style: { + lineWidth: 2, + stroke: '#A0A0A0' + } + }); + this.add(this.rightBoard); + this.rightBoard.hide(); + this.bottomBoard = new Line({ + zlevel: this.zlevel, + z: this.z + 1, + shape: { + x1: model.position.x - 1, + y1: model.position.y + 15, + x2: model.position.x + 15, + y2: model.position.y + 15 + }, + style: { + lineWidth: 2, + stroke: '#A0A0A0' + } + }); + this.add(this.bottomBoard); + this.bottomBoard.hide(); + const hasTextList = ['PASS', 'ASSIST', 'PICK_ASSIST', 'DEPART_ASSIST', 'ACCIDENT', 'CHANGE_DIRECTION', 'RECOVERY', 'OCCLUSION']; + if (hasTextList.includes(model.type)) { this.buttonText = new Text({ zlevel: this.zlevel, z: this.z, @@ -87,6 +154,23 @@ export default class SignalButton extends Group { }); this.add(this.buttonText); } + // if (model.type === 'CHANGE_DIRECTION') { + // this.arcFlash = new Arc({ + // _subType: 'change_direction_flash', + // zlevel: this.zlevel, + // z: this.z, + // shape: { + // cx: model.position.x + 18 + 7, + // cy: model.position.y + 7, + // r: 6 + // }, + // style: { + // lineWidth: 0, + // fill: '#ffff00' + // } + // }); + // this.add(this.arcFlash); + // } } startAnimate() { this.rectButton && this.rectButton.animateStyle(true) @@ -97,21 +181,22 @@ export default class SignalButton extends Group { } stopAnimation() { this.rectButton && this.rectButton.stopAnimation(true); + // this.arcFlash && this.arcFlash.stopAnimation(false); } getTypeColor() { let color = ''; - const list = ['ASSIST', 'ACCIDENT', 'PICK_ASSIST', 'DEPART_ASSIST', 'CHANGE_DIRECTION']; + const list = ['ASSIST', 'ACCIDENT', 'PICK_ASSIST', 'DEPART_ASSIST', 'CHANGE_DIRECTION', 'RECOVERY', 'OCCLUSION']; if (this.model.type === 'FLEXIBLE' || this.model.type === 'SHUNT_TERMINAL') { color = '#808080'; } else if (this.model.type === 'GUIDE') { color = '#5050E1'; } else if (list.includes(this.model.type)) { - color = '#ccc' - } else { + color = '#ccc'; + } else { color = '#008000'; } return color; - }//12 + }// recover() { this.stopAnimation(); this.rectButton && this.rectButton.setStyle({ fill:this.getTypeColor() }); @@ -119,6 +204,10 @@ export default class SignalButton extends Group { this.leftLine && this.leftLine.hide(); this.rectButton && this.rectButton.show(); this.buttonText && this.buttonText.show(); + this.leftBoard && this.leftBoard.hide(); + this.rightBoard && this.rightBoard.hide(); + this.topBoard && this.topBoard.hide(); + this.bottomBoard && this.bottomBoard.hide(); } blockShow() { this.rightLine && this.rightLine.show(); @@ -126,6 +215,28 @@ export default class SignalButton extends Group { } setState(model) { this.recover(); + // { value: 'ASSIST', label: '总辅助按钮' }, + // { value: 'PICK_ASSIST', label: '接辅助按钮' }, + // { value: 'DEPART_ASSIST', label: '发辅助按钮' }, + const list = ['ASSIST', 'PICK_ASSIST', 'DEPART_ASSIST', 'CHANGE_DIRECTION', 'ACCIDENT', 'RECOVERY', 'OCCLUSION']; + if (list.includes(model.type)) { + if (this.rectButton) { + if (model.pressDown) { + this.rectButton.setStyle({ fill:'#FFFF00' }); + // this.arcFlash.show(); + // const style = this.style; + // this.arcFlash.animateStyle(true) + // .when(0, { fill: style.backgroundColor }) + // .when(500, { fill: '#FFFF00' }) + // .when(1000, { fill: style.backgroundColor }) + // .start(); + } else { + this.rectButton.setStyle({ fill:this.getTypeColor() }); + // this.arcFlash.stopAnimation(false); + // this.arcFlash.hide(); + } + } + } if (!store.getters['map/checkDeviceShow'](this._code)) { this.buttonText && this.buttonText.hide(); this.rectButton && this.rectButton.hide(); @@ -136,7 +247,6 @@ export default class SignalButton extends Group { this.startAnimate(); } } - } getAnchorPoint() { } diff --git a/src/jmapNew/shape/graph/Station/index.js b/src/jmapNew/shape/graph/Station/index.js index 1dbe18501..fb4395d2c 100644 --- a/src/jmapNew/shape/graph/Station/index.js +++ b/src/jmapNew/shape/graph/Station/index.js @@ -315,7 +315,7 @@ export default class Station extends Group { zlevel: this.zlevel, z: this.z, point: { - x: model.controlModePoint.x - this.style.Station.StationControl.lamp.distance * 2 + this.style.Station.StationControl.selfDiscipline.offset.x, + x: model.controlModePoint.x - this.style.Station.StationControl.lamp.distance * 3 / 2 + this.style.Station.StationControl.selfDiscipline.offset.x, y: model.controlModePoint.y + this.style.Station.StationControl.selfDiscipline.offset.y }, context: this.style.Station.StationControl.selfDiscipline.text, @@ -330,7 +330,7 @@ export default class Station extends Group { zlevel: this.zlevel, z: this.z, point: { - x: model.controlModePoint.x - this.style.Station.StationControl.lamp.distance + this.style.Station.StationControl.selfDisciplineControl.offset.x, + x: model.controlModePoint.x - this.style.Station.StationControl.lamp.distance / 2 + this.style.Station.StationControl.selfDisciplineControl.offset.x, y: model.controlModePoint.y + this.style.Station.StationControl.selfDisciplineControl.offset.y }, context: this.style.Station.StationControl.selfDisciplineControl.text, @@ -349,13 +349,12 @@ export default class Station extends Group { zlevel: this.zlevel, z: this.z, point: { - x: model.controlModePoint.x + this.style.Station.StationControl.lamp.distance * 3 / 2 + this.style.Station.StationControl.veryControl.offset.x, + x: model.controlModePoint.x + this.style.Station.StationControl.lamp.distance / 2 + this.style.Station.StationControl.veryControl.offset.x, y: model.controlModePoint.y + this.style.Station.StationControl.centerControl.offset.y }, context: this.style.Station.StationControl.veryControl.text, pop: false }); - console.log(this.veryControl, 'veryContro'); this.add(this.veryControl); } if (this.style.Station.StationControl.veryControlButton) { @@ -364,7 +363,7 @@ export default class Station extends Group { z: this.z, _subType: 'veryControlButton', shape: { - x: model.controlModePoint.x + this.style.Station.StationControl.lamp.distance * 5 / 2 + this.style.Station.StationControl.veryControlButton.offset.x - this.style.Station.StationControl.lamp.radiusR, + x: model.controlModePoint.x + this.style.Station.StationControl.lamp.distance * 3 / 2 + this.style.Station.StationControl.veryControlButton.offset.x - this.style.Station.StationControl.lamp.radiusR, y: model.controlModePoint.y + this.style.Station.StationControl.veryControlButton.offset.y - this.style.Station.StationControl.lamp.radiusR, width: this.style.Station.StationControl.lamp.radiusR * 2, height: this.style.Station.StationControl.lamp.radiusR * 2 @@ -372,7 +371,7 @@ export default class Station extends Group { style: { lineWidth: 1, stroke: '#fff', - fill: '#ccc' + fill: this.style.Station.StationControl.veryControlButton.defaultColor } }); this.add(this.veryControlButton); @@ -382,7 +381,7 @@ export default class Station extends Group { _subType: 'veryControlButtonText', position: [0, 0], style: { - x: model.controlModePoint.x + this.style.Station.StationControl.lamp.distance * 5 / 2 + this.style.Station.StationControl.veryControlButton.offset.y, + x: model.controlModePoint.x + this.style.Station.StationControl.lamp.distance * 3 / 2 + this.style.Station.StationControl.veryControlButton.offset.y, y: model.controlModePoint.y + this.style.Station.StationControl.veryControlButton.offset.y + this.style.Station.StationControl.lamp.radiusR + this.style.Station.StationControl.text.distance, fontWeight: this.style.Station.StationControl.text.fontWeight, fontSize: this.style.Station.StationControl.text.fontSize, @@ -575,7 +574,7 @@ export default class Station extends Group { }); this.add(this.interconnectedControl); } - } + } handleCenter() { // 中控 this.noneBeforeMode = 'Center'; @@ -606,6 +605,7 @@ export default class Station extends Group { this.centerControl && this.centerControl.setColor(this.style.Station.StationControl.lamp.grayColor); this.substationArrowsControl && this.substationArrowsControl.setColor(this.style.Station.StationControl.lamp.greenColor); this.stationControlCC && this.stationControlCC.setStyle({text:'LC', textFill:this.style.Station.StationControl.text.stationControlColor}); + this.selfDisciplineControl && this.selfDisciplineControl.setColor(this.style.Station.StationControl.selfDisciplineControl.lightColor); // if (this.style.Station.StationControl.disPlayNone) { // this.stationText && this.stationText.setStyle('textFill', '#fff'); // if (this.model.subheadDisplay) { // 副标题 @@ -644,7 +644,9 @@ export default class Station extends Group { this.centerControl && this.centerControl.setTextColor(this.style.Station.StationControl.lamp.grayColor); this.interconnectedControl && this.interconnectedControl.setColor(this.style.Station.StationControl.lamp.purpleColor); this.interconnectedControl && this.interconnectedControl.setTextColor(this.style.Station.StationControl.lamp.purpleColor); - } + this.veryControl && this.veryControl.setColor(this.style.Station.StationControl.veryControl.lightColor); + this.veryControlButton && this.veryControlButton.setStyle({ fill: this.style.Station.StationControl.veryControlButton.lightColor }); + } handleNone() { // 空 if (this.style.Station.stationText.noneModeColor) { @@ -671,6 +673,10 @@ export default class Station extends Group { this.troButton && this.troButton.hide(); this.substationArrowsControl && this.substationArrowsControl.setColor(this.style.Station.StationControl.lamp.grayColor); this.emergencyArrowsControl && this.emergencyArrowsControl.setColor(this.style.Station.StationControl.lamp.grayColor); + this.stationControlCC && this.stationControlCC.setStyle({text:'EL', textFill:this.style.Station.StationControl.text.emergencyControlColor}); + this.veryControl && this.veryControl.setColor(this.style.Station.StationControl.veryControl.defaultColor); + this.selfDisciplineControl && this.selfDisciplineControl.setColor(this.style.Station.StationControl.selfDisciplineControl.defaultColor); + this.veryControlButton && this.veryControlButton.setStyle({ fill: this.style.Station.StationControl.veryControlButton.defaultColor }); if (this.style.Station.stationText.isSpecialType) { this.stationText.setColor(this.style.Station.stationText.noneModeColor); this.stationText.setBackground(this.style.Station.stationText.defaultBackColor); @@ -693,6 +699,7 @@ export default class Station extends Group { } else if (!store.getters['map/checkDeviceShow'](this._code)) { this.eachChild(item => { item.hide(); }); } else { + store.getters['map/checkStationGuideMaster'](this._code, model.sguideMasterLock, model.xguideMasterLock); model.controlMode && this['handle' + model.controlMode](); model.preResetValidDuration && this.handlePreResetLamp(); model.controller && this.handleComplexControl(model.controller); diff --git a/src/jmapNew/shape/graph/Switch/index.js b/src/jmapNew/shape/graph/Switch/index.js index ab2e81593..8c7976b21 100644 --- a/src/jmapNew/shape/graph/Switch/index.js +++ b/src/jmapNew/shape/graph/Switch/index.js @@ -725,6 +725,7 @@ export default class Switch extends Group { model.isCiConfirm && this.setCiConfirm(); // 道岔使能显示 model.singleLock && this.setMonolock(model.pos); // 道岔单锁 + model.guideMasterLock && this.setMonolock(model.pos); // 引导总锁 model.blockade && this.block(model.pos); // 道岔封锁 model.singleLock && model.blockade && this.blockMonolock(); // 单锁&锁闭状态 const path = window.location.href; diff --git a/src/jmapNew/shape/graph/Train/TrainBody.js b/src/jmapNew/shape/graph/Train/TrainBody.js index 5f4341fe3..5d9b93d9e 100644 --- a/src/jmapNew/shape/graph/Train/TrainBody.js +++ b/src/jmapNew/shape/graph/Train/TrainBody.js @@ -299,6 +299,9 @@ export default class TrainBody extends Group { this.trainBodyBox && this.trainBodyBox.setColor('fill', color); // Style('fill', color); } + setTrainBorderColor(color) { + this.trainBodyBox && this.trainBodyBox.setColor('stroke', color); + } setHShow(isShow) { if (this.textH) { isShow ? this.textH.show() : this.textH.hide(); diff --git a/src/jmapNew/shape/graph/Train/TrainHead.js b/src/jmapNew/shape/graph/Train/TrainHead.js index 9728a27ce..ebe383bd5 100644 --- a/src/jmapNew/shape/graph/Train/TrainHead.js +++ b/src/jmapNew/shape/graph/Train/TrainHead.js @@ -54,7 +54,9 @@ export default class TrainHead extends Group { this.add(this.arrow); } setColor(color) { - this.line && this.line.setStyle('fill', color); + if (!this.model.style.Train.trainHead.trainHeadRectNoChange){ + this.line && this.line.setStyle('fill', color); + } this.arrow && this.arrow.setStyle('fill', color); } setLineShow(isShow) { diff --git a/src/jmapNew/shape/graph/Train/index.js b/src/jmapNew/shape/graph/Train/index.js index d636c186c..2358832a0 100644 --- a/src/jmapNew/shape/graph/Train/index.js +++ b/src/jmapNew/shape/graph/Train/index.js @@ -50,10 +50,10 @@ export default class Train extends Group { }; if (model.right) { this.point.x = this.point.x - style.Train.trainHead.trainConntWidth * this.newScale - style.Train.common.trainWidth / 2; - this.point.y = this.point.y - style.Train.common.trainHeight / 2 + model.overLapIndex * (style.Train.common.trainHeight + 5); + this.point.y = this.point.y + model.overLapIndex * (style.Train.common.trainHeight + 5); } else { this.point.x = this.point.x + style.Train.trainHead.trainConntWidth * this.newScale - style.Train.common.trainWidth / 2; - this.point.y = this.point.y + model.trainWindowModel.height - style.Train.common.trainHeight / 2 - model.overLapIndex * (style.Train.common.trainHeight + 5); + this.point.y = this.point.y - model.overLapIndex * (style.Train.common.trainHeight + 5); } } else { this.point = model.position; @@ -226,6 +226,7 @@ export default class Train extends Group { this.trainR && this.trainR.setLineShow(false); this.trainL && this.trainL.setArrowShow(false); this.trainR && this.trainR.setArrowShow(false); + this.trainB && this.trainB.setTrainBorderColor(this.style.Train.trainBody.trainSidelineColor || this.style.trainSidelineColor); } // 设置运行方向状态类型 @@ -260,13 +261,26 @@ export default class Train extends Group { if (right == item.type) { if (this.style.Train.trainHead.directionStopType == 'special') { if (flag) { - this.trainL && this.trainL.setArrowShow(!item.lineLShow); - this.trainR && this.trainR.setArrowShow(!item.lineRShow); + this.trainL && this.trainL.setArrowShow(!item.arrowLShow); + this.trainR && this.trainR.setArrowShow(!item.arrowRShow); } else { - this.trainL && this.trainL.setArrowShow(item.lineLShow); - this.trainR && this.trainR.setArrowShow(item.lineRShow); + this.trainL && this.trainL.setArrowShow(item.arrowLShow); + this.trainR && this.trainR.setArrowShow(item.arrowRShow); } - } else { + } else if(this.style.Train.trainHead.directionStopType == 'specialAll'){ + if (flag) { + this.trainL && this.trainL.setArrowShow(!item.arrowLShow); + this.trainR && this.trainR.setArrowShow(!item.arrowRShow); + this.trainL && this.trainL.setLineShow(!item.lineLShow); + this.trainR && this.trainR.setLineShow(!item.lineRShow); + } else { + this.trainL && this.trainL.setArrowShow(item.arrowLShow); + this.trainR && this.trainR.setArrowShow(item.arrowRShow); + this.trainL && this.trainL.setLineShow(item.lineLShow); + this.trainR && this.trainR.setLineShow(item.lineRShow); + } + this.trainB && this.trainB.setTrainBorderColor(this.style.Train.trainBody.trainSidelineStopColor); + } else { if (flag) { this.trainL && this.trainL.setLineShow(!item.lineLShow); this.trainR && this.trainR.setLineShow(!item.lineRShow); diff --git a/src/jmapNew/shape/graph/element/EControl.js b/src/jmapNew/shape/graph/element/EControl.js index 00c07b03f..1b01a84d7 100644 --- a/src/jmapNew/shape/graph/element/EControl.js +++ b/src/jmapNew/shape/graph/element/EControl.js @@ -103,6 +103,19 @@ export default class EControl extends Group { this.control.setStyle('fill', color); } } + setControlFlashing(color) { + if (color) { + this.control.animateStyle(true) + .when(0, { fill: this.arcStyle.fill }) + .when(1000, { stroke: color }) + .when(2000, { fill: this.arcStyle.fill }) + .start(); + } + } + recover() { + this.control.stopAnimation(false); + this.control.setStyle('fill', this.arcStyle.fill); + } setControlStroke(color, lineWidth) { this.control.setStyle('lineWidth', lineWidth); this.control.setStyle('stroke', color); diff --git a/src/jmapNew/shape/graph/index.js b/src/jmapNew/shape/graph/index.js index db2761975..7260b670e 100644 --- a/src/jmapNew/shape/graph/index.js +++ b/src/jmapNew/shape/graph/index.js @@ -77,7 +77,8 @@ mapShape[deviceType.ReturnModeGroup] = SaidLamp; mapShape[deviceType.Axle] = SaidLamp; mapShape[deviceType.SwitchFault] = SaidLamp; mapShape[deviceType.IndicatorLight] = SaidLamp; -mapShape[deviceType.PickOrDepartArrow] = SaidLamp; +mapShape[deviceType.PickArrow] = SaidLamp; +mapShape[deviceType.DepartArrow] = SaidLamp; mapShape[deviceType.Occlusion] = SaidLamp; mapShape[deviceType.Accident] = SaidLamp; mapShape[deviceType.Recovery] = SaidLamp; diff --git a/src/jmapNew/theme/components/utils/menuOperate.js b/src/jmapNew/theme/components/utils/menuOperate.js index 5d118e358..bd277352a 100644 --- a/src/jmapNew/theme/components/utils/menuOperate.js +++ b/src/jmapNew/theme/components/utils/menuOperate.js @@ -492,7 +492,24 @@ export const menuOperate = { operation: OperationEvent.Train.deleteDestinationTrainId.menu.operation, cmdType: CMD.TrainWindow.CMD_TRAIN_SET_MANUAL } - } + }, + CTC: { + //接预 + receivingNotice: { + operation: OperationEvent.CTCCommand.receivingNotice.menu.operation, + cmdType: CMD.CTC.CTC_RECEIVING_NOTICE + }, + // 发预 + departureNotice: { + operation: OperationEvent.CTCCommand.departureNotice.menu.operation, + cmdType: CMD.CTC.CTC_DEPARTURE_NOTICE + }, + // 自动触发 + autoTrigger: { + operation: OperationEvent.CTCCommand.autoTrigger.menu.operation, + cmdType: CMD.CTC.CTC_AUTO_TRIGGER + } + } }; diff --git a/src/jmapNew/theme/datie_02/menus/dialog/childDialog/passwordInputBox.vue b/src/jmapNew/theme/datie_02/menus/dialog/childDialog/passwordInputBox.vue index 2f41411df..6a406a2b9 100644 --- a/src/jmapNew/theme/datie_02/menus/dialog/childDialog/passwordInputBox.vue +++ b/src/jmapNew/theme/datie_02/menus/dialog/childDialog/passwordInputBox.vue @@ -115,6 +115,7 @@ export default { if (operate.operateNext) { this.operation = operate.operateNext; } + console.log(this.operate, '--------------0000operate'); this.dialogShow = true; this.checkHasInput = false; this.$nextTick(function () { diff --git a/src/jmapNew/theme/datie_02/menus/dialog/mapVisual.vue b/src/jmapNew/theme/datie_02/menus/dialog/mapVisual.vue new file mode 100644 index 000000000..479b9be60 --- /dev/null +++ b/src/jmapNew/theme/datie_02/menus/dialog/mapVisual.vue @@ -0,0 +1,245 @@ + + + + diff --git a/src/jmapNew/theme/datie_02/menus/dialog/recDep.vue b/src/jmapNew/theme/datie_02/menus/dialog/recDep.vue new file mode 100644 index 000000000..d30bf974a --- /dev/null +++ b/src/jmapNew/theme/datie_02/menus/dialog/recDep.vue @@ -0,0 +1,146 @@ + + + + diff --git a/src/jmapNew/theme/datie_02/menus/dialog/routeSelection1.vue b/src/jmapNew/theme/datie_02/menus/dialog/routeSelection1.vue new file mode 100644 index 000000000..576f58038 --- /dev/null +++ b/src/jmapNew/theme/datie_02/menus/dialog/routeSelection1.vue @@ -0,0 +1,308 @@ + + + + diff --git a/src/jmapNew/theme/datie_02/menus/dialog/trainSetPlan.vue b/src/jmapNew/theme/datie_02/menus/dialog/trainSetPlan.vue new file mode 100644 index 000000000..17421e391 --- /dev/null +++ b/src/jmapNew/theme/datie_02/menus/dialog/trainSetPlan.vue @@ -0,0 +1,181 @@ + + + + diff --git a/src/jmapNew/theme/datie_02/menus/index.vue b/src/jmapNew/theme/datie_02/menus/index.vue index 952041774..074dd82d4 100644 --- a/src/jmapNew/theme/datie_02/menus/index.vue +++ b/src/jmapNew/theme/datie_02/menus/index.vue @@ -1,24 +1,25 @@ diff --git a/src/views/newMap/displayNew/menuSchema.vue b/src/views/newMap/displayNew/menuSchema.vue index 00de64468..7040eb560 100644 --- a/src/views/newMap/displayNew/menuSchema.vue +++ b/src/views/newMap/displayNew/menuSchema.vue @@ -12,15 +12,16 @@ @@ -42,6 +44,7 @@ import SelectStation from './selectStation'; import RunPlanLoad from './demon/runPlanLoad'; import RunPlanView from './demon/runPlanView'; import FaultChoose from './demon/faultChoose'; +import LineBoard from '../displayCity/lineBoard'; import AddQuest from './demon/addQuest'; import { OperateMode } from '@/scripts/ConstDic'; import { getByGroupStationList } from '@/api/jmap/map'; @@ -62,7 +65,8 @@ export default { FaultChoose, AddQuest, // RunPlanEdit, - SelectStation + SelectStation, + LineBoard }, props: { offset: { @@ -206,6 +210,9 @@ export default { } }); }, + showLineBoard() { + this.$refs.lineBoard.doShow(); + }, changeOperateMode() { this.faultMode = !this.faultMode; let mode = OperateMode.NORMAL; diff --git a/src/views/newMap/jlmapNew/index.vue b/src/views/newMap/jlmapNew/index.vue index 7ba28584a..d955fd5e1 100644 --- a/src/views/newMap/jlmapNew/index.vue +++ b/src/views/newMap/jlmapNew/index.vue @@ -312,6 +312,7 @@ export default { const lineCode = this.$store.state.map.map.skinVO.code; if (Vue.prototype.$theme) { this.localStationShow = Vue.prototype.$theme._localShowMode[lineCode] === 'ecStation'; + console.log(this.localStationShow, '============'); } this.$store.dispatch('map/setTrainWindowShow', this.previewOrMapDraw); }, @@ -498,7 +499,7 @@ export default { for (const key in mapDevice) { list.push(mapDevice[key]); } - + console.log(list, stationCode, '============='); this.$jlmap.updateShowStation(list, stationCode); !setCenter && stationCode && this.setCenter(stationCode); }, diff --git a/src/views/newMap/jointTrainingNew/index.vue b/src/views/newMap/jointTrainingNew/index.vue index 904d293a5..f02718b5b 100644 --- a/src/views/newMap/jointTrainingNew/index.vue +++ b/src/views/newMap/jointTrainingNew/index.vue @@ -490,6 +490,16 @@ export default { this.mapViewLoadedOver && this.setShowStation(''); this.drivingShow = false; break; + case 'RAIL_CTC': + this.$store.dispatch('training/setPrdType', '10'); + this.$store.dispatch('training/setRoles', 'RAIL_CTC'); + this.$refs.menuSchema.chiShowStation = deviceCode; + this.showStation = deviceCode; + this.$jlmap.amendDevice([...this.sectionList, ...this.signalList, ...this.trainWindowList]); + this.mapViewLoadedOver && this.switchStationMode(deviceCode); + this.jl3dmaintainershow = false; + this.drivingShow = false; + break; default: this.$store.dispatch('training/setPrdType', ''); this.$store.dispatch('training/setRoles', 'AUDIENCE'); diff --git a/src/views/newMap/jointTrainingNew/memberManage/membersManage.vue b/src/views/newMap/jointTrainingNew/memberManage/membersManage.vue index 67c46434b..8762b6923 100644 --- a/src/views/newMap/jointTrainingNew/memberManage/membersManage.vue +++ b/src/views/newMap/jointTrainingNew/memberManage/membersManage.vue @@ -113,7 +113,10 @@ export default { }, { labelName: '车辆段', children: [] - }] + },{ + labelName: 'CTC操作员', + children: [] + }] }; }, computed: { @@ -146,6 +149,7 @@ export default { const stationSupervisorList = []; const driverList = []; const maintainerList = []; + const ctcOperatorList = []; val.forEach(item => { const device = this.$store.getters['map/getDeviceByCode'](item.deviceCode); switch (item.type) { @@ -173,6 +177,10 @@ export default { this.memberData[item.id].labelName = '通号' + (item.name || ''); maintainerList.push(this.memberData[item.id]); break; + case 'RAIL_CTC': + this.memberData[item.id].labelName = 'CTC操作员' + device.name; + ctcOperatorList.push(this.memberData[item.id]); + break } }); this.treeData = [{ @@ -199,7 +207,11 @@ export default { labelName: '电力调度', id: 'electricDispatcher', children: electricDispatcherList - } + }, { + labelName: 'CTC操作员', + id: 'ctcOperator', + children: ctcOperatorList + } ]; this.$nextTick(() => { if (this.$refs.tree) { diff --git a/src/views/newMap/jointTrainingNew/menuDemon.vue b/src/views/newMap/jointTrainingNew/menuDemon.vue index 040904a76..7c6db1393 100644 --- a/src/views/newMap/jointTrainingNew/menuDemon.vue +++ b/src/views/newMap/jointTrainingNew/menuDemon.vue @@ -33,8 +33,8 @@ @@ -129,12 +129,15 @@ export default { lineCode() { return this.$route.query.lineCode; }, + datie(){ + return this.$route.query.lineCode == '16' + }, mapId() { return this.$route.query.mapId; }, isShowScheduling() { // 行调与管理员 可显示 - return (this.$store.state.training.prdType == '02' || this.isAdmin) && (!this.$route.query.projectDevice); + return (this.$store.state.training.prdType == '02' || this.isAdmin) && (!this.$route.query.projectDevice) && this.$route.query.lineCode !== '16'; }, isDISPATCHER() { return (this.$store.state.training.prdType == '01' || this.$store.state.training.prdType == '02' || this.isAdmin) && (!this.$route.query.projectDevice || this.project == 'sdy'); diff --git a/src/views/newMap/jointTrainingNew/menuSchema.vue b/src/views/newMap/jointTrainingNew/menuSchema.vue index a2ed6f27c..6f55ca285 100644 --- a/src/views/newMap/jointTrainingNew/menuSchema.vue +++ b/src/views/newMap/jointTrainingNew/menuSchema.vue @@ -13,12 +13,13 @@ /> + 占线板 IBP盘 大屏 ISCS - {{ $t('joinTraining.runGraphPreview') }} + {{ $t('joinTraining.runGraphPreview') }} @@ -29,6 +30,7 @@ + @@ -44,11 +46,13 @@ import { loadRunPlanData } from '@/utils/loaddata'; import { EventBus } from '@/scripts/event-bus'; import { timesSpeedPlayback } from '@/api/rtSimulation'; import { queryHasIscs } from '@/api/iscs'; +import LineBoard from '../displayCity/lineBoard'; export default { name: 'MenuDemonSchema', components:{ JoinRunPlanView, - SelectIbp + SelectIbp, + LineBoard }, props: { group: { @@ -134,6 +138,9 @@ export default { running() { return this.$store.state.training.started; }, + datie(){ + return this.$route.query.lineCode == '16' + }, isScreen() { return this.$store.state.training.prdType === '07'; }, @@ -303,6 +310,9 @@ export default { this.$message.error('设置倍速失败!'); }); }, + showLineBoard() { + this.$refs.lineBoard.doShow(); + }, // 点击ibp预览 goIbp() { // this.$refs.selectIbp.doShow(); diff --git a/src/views/newMap/newMapdraft/ciConfig.vue b/src/views/newMap/newMapdraft/ciConfig.vue index 24b2de0ca..d30f6a5e5 100644 --- a/src/views/newMap/newMapdraft/ciConfig.vue +++ b/src/views/newMap/newMapdraft/ciConfig.vue @@ -93,7 +93,7 @@ export default { 'routeNameUseEndOppositeSignalName', 'generateTbRoute', 'tbRouteNameUseEndOppositeSignalName', 'routeSignalAlwaysGreen', 'routeApartByOverlap', 'overlapOnlySwitch', 'overlapSwitchNpOnly', 'overlapSignalOppositeSwitchNpOnly', 'generateCycle', 'routeButton', 'likeHa1', 'getNearlySignal', 'overlapSettingByTrigger', 'generateFls', 'signalApproachNotPassPreSignal', - 'generateDestination', 'ctcOverlapOnlyTurnBackStationLock', 'routeInterlockDoNotIncludeStandHoldTrain', 'handleDepot' + 'generateDestination', 'ctcOverlapOnlyTurnBackStationLock', 'routeInterlockDoNotIncludeStandHoldTrain', 'handleDepot', 'railway' ], multipleList: ['sharingECStations'], selectList: [], @@ -129,7 +129,8 @@ export default { sharingECStations: '共享紧急关闭效果的车站', ctcOverlapOnlyTurnBackStationLock: 'CTC列车进路延续保护仅折返站处锁闭', routeInterlockDoNotIncludeStandHoldTrain: '进路联锁不包含站台扣车', - handleDepot: '是否处理停车场/车辆段逻辑' + handleDepot: '是否处理停车场/车辆段逻辑', + railway: '是否大铁线路' } }; }, diff --git a/src/views/newMap/newMapdraft/dataRelation/bigroutingoperate/detail.vue b/src/views/newMap/newMapdraft/dataRelation/bigroutingoperate/detail.vue index 97e898c24..771738d52 100644 --- a/src/views/newMap/newMapdraft/dataRelation/bigroutingoperate/detail.vue +++ b/src/views/newMap/newMapdraft/dataRelation/bigroutingoperate/detail.vue @@ -1,7 +1,11 @@ diff --git a/src/views/newMap/newMapdraft/dataRelation/index.vue b/src/views/newMap/newMapdraft/dataRelation/index.vue index cb22506f1..c775bc312 100644 --- a/src/views/newMap/newMapdraft/dataRelation/index.vue +++ b/src/views/newMap/newMapdraft/dataRelation/index.vue @@ -32,6 +32,7 @@ import RouteOperate from './routeoperate/index'; import RoutingOperate from './routingoperate/index'; import BigRoutingOperate from './bigroutingoperate/index'; +import IndicatorAssociatedInfo from './indicatorAssociatedInfo/index'; import AutomaticOperate from './automaticoperate/index'; // import PathOperate from './pathoperate/index'; import RunLevelOperate from './runLeveloperate/index'; @@ -56,7 +57,8 @@ export default { SignalOperate, TurnedOperate, DwellTimeOperate, - ContinueProtectOperate + ContinueProtectOperate, + IndicatorAssociatedInfo // DestinationOperate }, props: { @@ -94,10 +96,11 @@ export default { }, mounted() { this.initLoad(); - if (this.$route.query.lineCode == '15') { + if (this.$route.query.lineCode == '15' || this.$route.query.lineCode == '16') { this.tabList = [ {label: '大铁进路', name:'bigRoutingOperate', menus:BigRoutingOperate}, - {label: this.$t('map.routing'), name:'routing', menus:RoutingOperate} + {label: '指示灯关联', name: 'indicatorAssociatedInfo', menus: IndicatorAssociatedInfo} + // {label: this.$t('map.routing'), name:'routing', menus:RoutingOperate} ]; this.enabledTab = 'bigRoutingOperate'; } else { diff --git a/src/views/newMap/newMapdraft/dataRelation/indicatorAssociatedInfo/detail.vue b/src/views/newMap/newMapdraft/dataRelation/indicatorAssociatedInfo/detail.vue new file mode 100644 index 000000000..0888fcca2 --- /dev/null +++ b/src/views/newMap/newMapdraft/dataRelation/indicatorAssociatedInfo/detail.vue @@ -0,0 +1,134 @@ + + diff --git a/src/views/newMap/newMapdraft/dataRelation/indicatorAssociatedInfo/index.vue b/src/views/newMap/newMapdraft/dataRelation/indicatorAssociatedInfo/index.vue new file mode 100644 index 000000000..f84bd881d --- /dev/null +++ b/src/views/newMap/newMapdraft/dataRelation/indicatorAssociatedInfo/index.vue @@ -0,0 +1,96 @@ + + diff --git a/src/views/newMap/newMapdraft/dataRelation/indicatorAssociatedInfo/route.vue b/src/views/newMap/newMapdraft/dataRelation/indicatorAssociatedInfo/route.vue new file mode 100644 index 000000000..881da06d9 --- /dev/null +++ b/src/views/newMap/newMapdraft/dataRelation/indicatorAssociatedInfo/route.vue @@ -0,0 +1,208 @@ + + + diff --git a/src/views/newMap/newMapdraft/mapoperate/checkboxDraft.vue b/src/views/newMap/newMapdraft/mapoperate/checkboxDraft.vue index 3871bc87a..8f6900bbd 100644 --- a/src/views/newMap/newMapdraft/mapoperate/checkboxDraft.vue +++ b/src/views/newMap/newMapdraft/mapoperate/checkboxDraft.vue @@ -57,7 +57,7 @@ @mouseenter="mouseenter(nor)" @mouseleave="mouseleave(nor)" > -
{{ nor.name }}
+
{{ nor.name || nor.code }}
@@ -119,7 +119,12 @@ export default { type: 'Signal', name: '信号机列表', list: [] - } + }, + { + type: 'SignalButton', + name: '信号按钮列表', + list: [] + } ] }; }, @@ -156,7 +161,9 @@ export default { this.modelList[1].list.push(item); } else if (item._type == 'Signal') { this.modelList[2].list.push(item); - } + } else if (item._type == 'SignalButton') { + this.modelList[3].list.push(item); + } if (item.stationCode == this.seclectDeviceList[0].stationCode) { count++; } @@ -317,7 +324,12 @@ export default { type: 'Signal', name: '信号机列表', list: [] - } + }, + { + type: 'SignalButton', + name: '信号按钮列表', + list: [] + } ]; }, mouseenter(model) { diff --git a/src/views/newMap/newMapdraft/mapoperate/controlLamp.vue b/src/views/newMap/newMapdraft/mapoperate/controlLamp.vue index 26670103d..a97025f0a 100644 --- a/src/views/newMap/newMapdraft/mapoperate/controlLamp.vue +++ b/src/views/newMap/newMapdraft/mapoperate/controlLamp.vue @@ -99,7 +99,8 @@ export default { 'Recovery', 'Accident', 'Occlusion', - 'PickOrDepartArrow' + 'PickArrow', + 'DepartArrow' ], noNameTypeList: ['FaultStatusGroup', 'ModeStatusGroup', 'LampFilament', 'ReturnModeGroup', 'ControlSwitch', 'Axle'], typeList: [ @@ -130,9 +131,10 @@ export default { { name: '复原', value: 'Recovery' }, { name: '事故', value: 'Accident' }, { name: '闭塞', value: 'Occlusion' }, - { name: '接发车箭头', value: 'PickOrDepartArrow' } + { name: '接车箭头', value: 'PickArrow' }, + { name: '发车箭头', value: 'DepartArrow' } ], - hasDirectionList: ['SectionOccupied', 'AssistStatus', 'TotalAssist', 'DepartAssist', 'PickAssist', 'Recovery', 'Accident', 'Occlusion', 'PickOrDepartArrow'], + hasDirectionList: ['SectionOccupied', 'AssistStatus', 'TotalAssist', 'DepartAssist', 'PickAssist', 'Recovery', 'Accident', 'Occlusion', 'PickArrow', 'DepartArrow'], directionList: [{label: 'X',value: 'X'},{label: 'XF',value: 'XF'},{label: 'XD',value: 'XD'}, {label:'S',value:'S'},{label:'SF',value:'SF'},{label:'SD',value: 'SD'}], editModel:getModel('ControlLamp'), addModel:getModel('ControlLamp'), @@ -165,8 +167,8 @@ export default { ] }, { prop: 'mfNum', label: '报警指示故障数量:', type: 'number', min: 0, isHidden: this.editModel.type !== 'FaultStatusGroup' }, { prop: 'pfNum', label: '电源故障数量:', type: 'number', min: 0, isHidden: this.editModel.type !== 'FaultStatusGroup'}, - { prop: 'right', label: '朝右:', type: 'checkbox', isHidden: this.editModel.type !== 'PickOrDepartArrow' }, - { prop: 'direction', label: '方向:', type: 'select', optionLabel: 'label', optionValue: 'value', options: this.directionList, isHidden: !this.hasDirectionList.includes(this.editModel.type) }, + { prop: 'right', label: '朝右:', type: 'checkbox', isHidden: this.editModel.type !== 'DepartArrow' && this.editModel.type !== 'PickArrow' }, + { prop: 'labelEnum', label: '方向:', type: 'select', optionLabel: 'label', optionValue: 'value', options: this.directionList, isHidden: !this.hasDirectionList.includes(this.editModel.type) }, { prop: 'switchCode', label: '所属道岔:', type: 'selectHover', optionLabel: 'name&&code', optionValue: 'code', options: this.switchList, isHidden: this.editModel.type !== 'SwitchFault', hover: this.hover, buttonType: 'switchSelectCode', buttonShowType: this.isButtonType }, { prop:'stationCode', label: '所属车站:', type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.stationList} ] @@ -191,7 +193,7 @@ export default { ] }, { prop: 'mfNum', label: '报警指示故障数量:', type: 'number', min: 0, isHidden: this.addModel.type !== 'FaultStatusGroup' }, { prop: 'pfNum', label: '电源故障数量:', type: 'number', min: 0, isHidden: this.addModel.type !== 'FaultStatusGroup'}, - { prop: 'direction', label: '方向:', type: 'select', optionLabel: 'label', optionValue: 'value', options: this.directionList, isHidden: !this.hasDirectionList.includes(this.addModel.type) }, + { prop: 'labelEnum', label: '方向:', type: 'select', optionLabel: 'label', optionValue: 'value', options: this.directionList, isHidden: !this.hasDirectionList.includes(this.addModel.type) }, { prop: 'switchCode', label: '所属道岔:', type: 'selectHover', optionLabel: 'name&&code', optionValue: 'code', options: this.switchList, isHidden: this.addModel.type !== 'SwitchFault', hover: this.hover, buttonType: 'switchSelectCode', buttonShowType: this.isButtonType } ] } @@ -222,7 +224,7 @@ export default { switchCode: [ { required: true, message: '请选择所属道岔!', trigger: 'change'} ], - direction: [ + labelEnum: [ { required: true, message: '请选择方向!', trigger: 'change'} ] }; @@ -292,7 +294,8 @@ export default { this.RecoveryList = []; this.AccidentList = []; this.OcclusionList = []; - this.PickOrDepartArrowList = []; + this.DepartArrowList = []; + this.PickArrowList = []; indicatorLightList.forEach(item => { switch (item._type) { case 'AtsControl': @@ -376,8 +379,11 @@ export default { case 'Occlusion': this.OcclusionList.push(item); break; - case 'PickOrDepartArrow': - this.PickOrDepartArrowList.push(item); + case 'PickArrow': + this.PickArrowList.push(item); + break; + case 'DepartArrow': + this.DepartArrowList.push(item); break; } }); @@ -465,8 +471,11 @@ export default { case 'Occlusion': this.selectLists = this.OcclusionList; break; - case 'PickOrDepartArrow': - this.selectLists = this.PickOrDepartArrowList; + case 'PickArrow': + this.selectLists = this.PickArrowList; + break; + case 'DepartArrow': + this.selectLists = this.DepartArrowList; break; default : this.selectLists = this.intersiteControlList; @@ -478,6 +487,7 @@ export default { this.deviceSelect(this.$store.getters['map/getDeviceByCode'](code)); }, deviceSelect(selected) { + console.log(selected, '======'); if (this.field.toUpperCase() === 'switchSelectCode'.toUpperCase() && selected._type.toUpperCase() === 'Switch'.toUpperCase()) { if (this.activeName === 'first') { this.editModel.switchCode = selected.code; @@ -576,8 +586,11 @@ export default { case 'Occlusion': idPrefix = 'occlusion'; break; - case 'PickOrDepartArrow': - idPrefix = 'podArrow' + case 'PickArrow': + idPrefix = 'pickArrow'; + break; + case 'DepartArrow': + idPrefix = 'departArrow'; break; } return idPrefix; diff --git a/src/views/newMap/newMapdraft/mapoperate/index.vue b/src/views/newMap/newMapdraft/mapoperate/index.vue index d77a7041f..d93335d52 100644 --- a/src/views/newMap/newMapdraft/mapoperate/index.vue +++ b/src/views/newMap/newMapdraft/mapoperate/index.vue @@ -208,7 +208,10 @@ export default { this.$emit('showMap'); }, handleSelectControlPage(device) { - const controlLampTypeList = ['AtsControl', 'CenterCommunication', 'ChainControl', 'IntersiteControl', 'LeuControl', 'LocalControl', 'Maintain', 'SwitchFault', 'PowerSupply', 'NoOneReturn', 'MaintenanceLamps', 'ZcCommunication', 'FaultStatusGroup', 'ModeStatusGroup', 'LampFilament', 'ReturnModeGroup', 'ControlSwitch', 'Axle', 'IndicatorLight']; + const controlLampTypeList = ['AtsControl', 'CenterCommunication', 'ChainControl', 'IntersiteControl', 'LeuControl', 'LocalControl', 'Maintain', + 'SwitchFault', 'PowerSupply', 'NoOneReturn', 'MaintenanceLamps', 'ZcCommunication', 'FaultStatusGroup', 'ModeStatusGroup', 'LampFilament', + 'ReturnModeGroup', 'ControlSwitch', 'Axle', 'IndicatorLight', 'SectionOccupied', 'AssistStatus', 'TotalAssist', 'DepartAssist', 'PickAssist', + 'Recovery', 'Accident', 'Occlusion', 'PickArrow' ,'DepartArrow']; const type = device._type; if (this.selectDevice) { this.enabledTab = this.selectDevice; diff --git a/src/views/newMap/newMapdraft/mapoperate/models.js b/src/views/newMap/newMapdraft/mapoperate/models.js index 484846ab5..986f919cf 100644 --- a/src/views/newMap/newMapdraft/mapoperate/models.js +++ b/src/views/newMap/newMapdraft/mapoperate/models.js @@ -112,6 +112,7 @@ class Model { this.tp = { x: 0, y: 0 }; this.belongStationCode = ''; this.srCode = ''; + this.throat = ''; } StationModel() { this._type = 'Station'; @@ -201,6 +202,7 @@ class Model { this.mfNum = 0; this.pfNum = 0; this.switchCode = ''; + this.labelEnum = ''; this.right = false; } } diff --git a/src/views/newMap/newMapdraft/mapoperate/signal/index.vue b/src/views/newMap/newMapdraft/mapoperate/signal/index.vue index 916ca7690..24595f18a 100644 --- a/src/views/newMap/newMapdraft/mapoperate/signal/index.vue +++ b/src/views/newMap/newMapdraft/mapoperate/signal/index.vue @@ -69,13 +69,17 @@ export default { { code: 'EXIT', name: '出站信号机' }, { code: 'SHUNTING2', name: '列车兼调车信号机' }, { code: 'INBOUND', name: '进段信号机' }, - { code: 'OUTBOUND', name: '出段信号机' } + { code: 'OUTBOUND', name: '出段信号机' }, + { code: 'RECEIVING', name: '接车信号机(大铁)' }, + { code: 'DEPARTURE', name: '发车信号机(大铁)'} ], signalModelList:[ { code: 'RGY', name: '红绿黄三灯信号机'}, { code: 'R', name: '单红灯信号机'}, { code: 'BW', name: '蓝白调车信号机'}, - { code: 'YRW', name: '黄红白列车兼调车信号机' } + { code: 'YRW', name: '黄红白列车兼调车信号机' }, + { code: 'YGRYW', name: '黄绿红黄白信号机' }, + { code: 'YGRGW', name: '黄绿红绿白信号机' } ], field:'', editModel: getModel('Signal'), diff --git a/src/views/newMap/newMapdraft/mapoperate/signalButton.vue b/src/views/newMap/newMapdraft/mapoperate/signalButton.vue index 04743c41d..57a7e573f 100644 --- a/src/views/newMap/newMapdraft/mapoperate/signalButton.vue +++ b/src/views/newMap/newMapdraft/mapoperate/signalButton.vue @@ -56,7 +56,7 @@ export default { signalCode: '', sectionCode: '', switchCode: '', - direction: '', + labelEnum: '', position: { x: 0, y: 0 @@ -84,14 +84,16 @@ export default { { value: 'PASS', label: '通过按钮' }, { value: 'GUIDE', label: '引导按钮' }, { value: 'FLEXIBLE', label: '变通按钮' }, - { value: 'RAMP_TERMINAL', label: '坡道终端按钮' }, + { value: 'RAMP_TERMINAL', label: '坡道终端按钮'}, { value: 'TRAIN_TERMINAL', label: '列车终端按钮'}, { value: 'SHUNT_TERMINAL', label: '调车终端按钮'}, { value: 'ASSIST', label: '总辅助按钮' }, { value: 'PICK_ASSIST', label: '接辅助按钮' }, { value: 'DEPART_ASSIST', label: '发辅助按钮' }, { value: 'ACCIDENT', label: '事故按钮' }, - { value: 'CHANGE_DIRECTION', label: '改方按钮' } + { value: 'CHANGE_DIRECTION', label: '改方按钮' }, + { value: 'RECOVERY', label: '复原按钮' }, + { value: 'OCCLUSION', label: '闭塞按钮' } ], centralizedStationList: [], // 设备集中站列表 directionList: [{label:'X',value:'X'},{label:'XF',value:'XF'},{label:'XD',value:'XD'},{label:'S',value:'S'},{label:'SF',value:'SF'},{label:'SD',value:'SD'}], @@ -120,7 +122,7 @@ export default { 'position.y': [ { required: true, message: this.$t('rules.pleaseEnterYCoordinate'), trigger: 'blur' } ], - direction: [ + labelEnum: [ { required: true, message: '请选择方向', trigger: 'change' } ] } @@ -156,7 +158,7 @@ export default { { prop: 'signalCode', label: '关联信号机:', type: 'selectHover', optionLabel: 'name&&code', optionValue: 'code', clearable: true, options: this.signalList, hover: this.hover, buttonType: 'linkSignal', buttonShowType: this.isLinkSignalShow, isHidden: !this.isLinkSignal }, { prop: 'sectionCode', label: '关联区段:', type: 'selectHover', optionLabel: 'name&&code', optionValue: 'code', clearable: true, options: this.sectionList, hover: this.hover, buttonType: 'linkSection', buttonShowType: this.isLinkSectionShow, isHidden: !this.isLinkSection }, { prop: 'switchCode', label: '关联道岔:', type: 'selectHover', optionLabel: 'name&&code', optionValue: 'code', clearable: true, options: this.switchList, hover: this.hover, buttonType: 'linkSwitch', buttonShowType: this.isLinkSwitchShow, isHidden: !this.isLinkSwitch }, - { prop: 'direction', label: '方向:', type: 'select', optionLabel: 'label', optionValue: 'value', options: this.directionList, isHidden: !this.isLinkDirection }, + { prop: 'labelEnum', label: '方向:', type: 'select', optionLabel: 'label', optionValue: 'value', options: this.directionList, isHidden: !this.isLinkDirection }, { prop: 'position', label: this.$t('map.textPoints'), type: 'coordinate', width: '120px', children: [ { prop: 'position.x', firstLevel: 'position', secondLevel: 'x', label: 'x:', type: 'number', labelWidth: '25px', disabled: false }, { prop: 'position.y', firstLevel: 'position', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '25px', disabled: false } @@ -213,7 +215,7 @@ export default { return this.editModel.type === 'FLEXIBLE'; }, isLinkDirection() { - return ['ASSIST', 'PICK_ASSIST', 'DEPART_ASSIST', 'ACCIDENT', 'CHANGE_DIRECTION'].includes(this.editModel.type); + return ['ASSIST', 'PICK_ASSIST', 'DEPART_ASSIST', 'ACCIDENT', 'CHANGE_DIRECTION', 'RECOVERY', 'OCCLUSION'].includes(this.editModel.type); } }, methods: { @@ -242,7 +244,7 @@ export default { this.editModel.signalCode = ''; this.editModel.switchCode = ''; this.editModel.sectionCode = ''; - this.editModel.direction = ''; + this.editModel.labelEnum = ''; this.activeName = 'first'; this.editModel = deepAssign(this.editModel, selected); } else if (this.field === 'linkSignal' && selected && selected._type.toUpperCase() === 'Signal'.toUpperCase()) { @@ -288,11 +290,11 @@ export default { }, updateMapModel(data) { if (this.isLinkSignal) { - data.sectionCode = ''; data.switchCode = ''; data.direction = ''; + data.sectionCode = ''; data.switchCode = ''; data.labelEnum = ''; } else if (this.isLinkSection) { - data.signalCode = ''; data.switchCode = ''; data.direction = ''; + data.signalCode = ''; data.switchCode = ''; data.labelEnum = ''; } else if (this.isLinkSwitch) { - data.signalCode = ''; data.sectionCode = ''; data.direction = ''; + data.signalCode = ''; data.sectionCode = ''; data.labelEnum = ''; } else if (this.isLinkDirection) { data.sectionCode = ''; data.signalCode = ''; data.switchCode = ''; } diff --git a/src/views/newMap/newMapdraft/mapoperate/switch/batchSet.vue b/src/views/newMap/newMapdraft/mapoperate/switch/batchSet.vue new file mode 100644 index 000000000..a2af778fd --- /dev/null +++ b/src/views/newMap/newMapdraft/mapoperate/switch/batchSet.vue @@ -0,0 +1,102 @@ + + + diff --git a/src/views/newMap/newMapdraft/mapoperate/switch/create.vue b/src/views/newMap/newMapdraft/mapoperate/switch/create.vue index fd1e273b7..c71f016ef 100644 --- a/src/views/newMap/newMapdraft/mapoperate/switch/create.vue +++ b/src/views/newMap/newMapdraft/mapoperate/switch/create.vue @@ -77,8 +77,9 @@ export default { x: skew.x, y: skew.y }, - pos: 'N' // 默认状态定位 + pos: 'N', // 默认状态定位 // N-定位 R-反位 NO-无(失表) EX-挤叉 + throat: '' }; const model = Object.assign(switchModel, data); const swch = this.findSwitchData(model.sectionACode, model.sectionBCode, model.sectionCCode); @@ -136,8 +137,9 @@ export default { x: skew.x, y: skew.y }, - pos: 'N' // 默认状态定位 + pos: 'N', // 默认状态定位 // N-定位 R-反位 NO-无(失表) EX-挤叉 + throat: '' }; const model = Object.assign(switchModel, data); const swch = this.findSwitchData(model.sectionACode, model.sectionBCode, model.sectionCCode); diff --git a/src/views/newMap/newMapdraft/mapoperate/switch/index.vue b/src/views/newMap/newMapdraft/mapoperate/switch/index.vue index 43b90820f..3dc3eff56 100644 --- a/src/views/newMap/newMapdraft/mapoperate/switch/index.vue +++ b/src/views/newMap/newMapdraft/mapoperate/switch/index.vue @@ -9,6 +9,9 @@ + + + @@ -16,6 +19,7 @@ import SwitchModel from './switchModle'; import CreateSwitch from './create'; import CreateAxle from './createAxle'; +import BatchSet from './batchSet'; import { mapGetters } from 'vuex'; export default { @@ -23,7 +27,8 @@ export default { components: { SwitchModel, CreateSwitch, - CreateAxle + CreateAxle, + BatchSet }, props: { selected: { @@ -64,7 +69,9 @@ export default { deviceSelect(selected) { if (selected && selected._type.toUpperCase() === 'Switch'.toUpperCase() && this.field.toUpperCase() === 'relevanceSwitchList'.toUpperCase()) { this.$refs.createAxle.pushData(selected.code); - } else if (selected && selected._type.toUpperCase() === 'Switch'.toUpperCase()) { + } else if(selected && selected._type.toUpperCase() === 'Switch'.toUpperCase() && this.field.toUpperCase() === 'switchList'.toUpperCase()) { + this.$refs.batchSet.pushData(selected.code); + } else if (selected && selected._type.toUpperCase() === 'Switch'.toUpperCase()) { this.activeName = 'first'; this.$refs.switchModel.setModel(selected); } diff --git a/src/views/newMap/newMapdraft/mapoperate/switch/switchModle.vue b/src/views/newMap/newMapdraft/mapoperate/switch/switchModle.vue index 5c64810b2..052255c04 100644 --- a/src/views/newMap/newMapdraft/mapoperate/switch/switchModle.vue +++ b/src/views/newMap/newMapdraft/mapoperate/switch/switchModle.vue @@ -43,6 +43,7 @@ export default { { prop: 'namePosition.x', firstLevel: 'namePosition', secondLevel: 'x', label: 'x:', type: 'number', labelWidth: '25px' }, { prop: 'namePosition.y', firstLevel: 'namePosition', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '25px' } ] }, + { prop: 'throat', label: '所属咽喉区:', type: 'select', optionLabel: 'name', optionValue: 'code', options: [{name: 'S', code: 'S'}, {name: 'X', code: 'X'}] }, { prop: 'srCode', label: '沙盘设备编号', type: 'input' }, { prop: 'tp', label: this.$t('map.switchTp'), type: 'coordinate', width: '160px', children: [ { prop: 'tp.x', firstLevel: 'tp', secondLevel: 'x', label: 'x:', type: 'number', labelWidth: '25px' }, diff --git a/src/views/system/configLine/config.vue b/src/views/system/configLine/config.vue index c6a2e40ec..8626f4597 100644 --- a/src/views/system/configLine/config.vue +++ b/src/views/system/configLine/config.vue @@ -115,7 +115,8 @@ export default { 'routeDefaultCheckConflict', 'tripNumberIsUnique', 'standTbStrategyIsInvalid', - 'updateTripPlanByServiceNumber' + 'updateTripPlanByServiceNumber', + 'hasCTC' ], selectList: ['runMode', 'singleApproachLockCancelRoute'], generalConfig: [ @@ -164,7 +165,8 @@ export default { 'routeDefaultCheckConflict', 'tripNumberIsUnique', 'standTbStrategyIsInvalid', - 'updateTripPlanByServiceNumber' + 'updateTripPlanByServiceNumber', + 'hasCTC' ], rangeList: ['noParkingSM', 'parkingSM'], speedList: ['rmAtpSpeed', 'urmAtpSpeed'], @@ -219,7 +221,8 @@ export default { routeDefaultCheckConflict: '进路默认开启冲突检测', tripNumberIsUnique: '运行图中车次号是否唯一', standTbStrategyIsInvalid: '站台折返策略不生效', - updateTripPlanByServiceNumber: '根据服务号更新车次计划' + updateTripPlanByServiceNumber: '根据服务号更新车次计划', + hasCTC: '有CTC系统(大铁)' } }; },