diff --git a/src/jmapNew/config/skinCode/haerbin_01.js b/src/jmapNew/config/skinCode/haerbin_01.js index ca1d7e141..652cfa49d 100644 --- a/src/jmapNew/config/skinCode/haerbin_01.js +++ b/src/jmapNew/config/skinCode/haerbin_01.js @@ -141,7 +141,7 @@ class SkinCode extends defaultStyle { standardShow: true, // 灯柱显示 standardLength: 4, // 高柱长度 standardHeight: 5, // 灯柱高度 - standardColor: '#3149C3', // 灯柱颜色 + standardColor: '#FF0000', // 灯柱颜色 standardWidth: 4 // 灯柱宽度 }, text: { @@ -151,22 +151,22 @@ class SkinCode extends defaultStyle { fontSize: 11, // 信号机名称字体大小 fontWeight: 'bold', // 信号机名称字体粗细 defaultColor: '#FFFFFF', // 信号灯字体默认色 - blockColor: '#EF0C08', // 信号灯字体锁定颜色 + blockColor: '#ffffff', // 信号灯字体锁定颜色 checkColor: '#00FF00', // 信号字体 - nameBorderShow: true // 信号机名字边框显示 + nameBorderShow: false // 信号机名字边框显示 }, lamp: { bgShow: true, // 是否被选中 logicDisplayNone: true, // 逻辑点灯斜线不显示 - guidName: 'defult', // 默认引导类型 + guidName: 'haerbin_01', // 默认引导类型 stopWidth: 2, // 禁止线宽度 - borderWidth: 1, // 信号灯边框线宽度 - borderColor: '#3149C3', // 信号灯边框线颜色 + borderWidth: 0, // 信号灯边框线宽度 + borderColor: '#FF0000', // 信号灯边框线颜色 (虚拟信号机) radiusR: 4, // 信号灯半径 blockColor: '#EF0C08', // 信号灯锁闭 grayColor: '#7F7F7F', // 信号灯灰色 redColor: '#FF0000', // 信号灯红色 - greenColor: '#00FF00', // 信号灯绿色 + greenColor: '#000080', // 信号灯绿色 yellowColor: '#FFFF00', // 信号灯黄色 whiteColor: '#FFFFFF', // 信号灯白色 blueColor: '#0070C0' // 信号灯蓝色 diff --git a/src/jmapNew/shape/Section/index.js b/src/jmapNew/shape/Section/index.js index b0c66f4a1..b6939449b 100644 --- a/src/jmapNew/shape/Section/index.js +++ b/src/jmapNew/shape/Section/index.js @@ -702,7 +702,6 @@ export default class Section extends Group { stroke: this.style.Section.line.protectiveLockColor, lineWidth: this.style.Section.line.width + this.style.Section.line.beyondWidth }); - this.setModelTypeLevel(); } } @@ -752,7 +751,6 @@ export default class Section extends Group { { time: 1000, styles: { stroke: this.style.backgroundColor } }, { time: 2000, styles: { lineWidth: lineWidth } } ]); - this.setModelTypeLevel(); } } diff --git a/src/jmapNew/shape/Signal/ESigPost.js b/src/jmapNew/shape/Signal/ESigPost.js index 8ba53dd64..7845ef30d 100644 --- a/src/jmapNew/shape/Signal/ESigPost.js +++ b/src/jmapNew/shape/Signal/ESigPost.js @@ -11,7 +11,7 @@ class ESigPost extends Group { create() { const model = this.model; const style = this.model.style; - + // 竖杆 this.ver = new Polyline({ _subType: 'SignalLamp', _val: '3', @@ -28,7 +28,7 @@ class ESigPost extends Group { stroke: style.Signal.post.standardColor } }); - + // 横杆 this.hor = new Polyline({ zlevel: model.zlevel, z: model.z, @@ -53,6 +53,13 @@ class ESigPost extends Group { } } + setColor(color) { + if (color) { + this.ver && this.ver.setStyle({ stroke: color }); + this.hor && this.hor.setStyle({ stroke: color }); + } + } + getLampPosition(type) { const model = this.model; const style = this.model.style; diff --git a/src/jmapNew/shape/Signal/index.js b/src/jmapNew/shape/Signal/index.js index b09289afb..4bcbd7bdc 100644 --- a/src/jmapNew/shape/Signal/index.js +++ b/src/jmapNew/shape/Signal/index.js @@ -42,7 +42,7 @@ class Signal extends Group { const drict = this.model.right ? 1 : -1; // 朝向 左:右 const posit = this.model.positionType == '01' ? -1 : 1; // 位置 上:下 - // 信号机高柱矮柱 + // 信号机高柱矮柱 (信号机底座) this.sigPost = new ESigPost({ zlevel: this.zlevel, z: this.z, @@ -56,7 +56,7 @@ class Signal extends Group { // 信号灯 const endPoint = this.sigPost.getLampPosition(model.lampPostType); this.lamps = []; - if (style.Signal.lamp.guidName == 'ningbo_01' && this.count == 1) { + if ((style.Signal.lamp.guidName == 'ningbo_01' || style.Signal.lamp.guidName == 'haerbin_01') && this.count == 1) { this.count = 2; } for (let i = 0; i < this.count; i++) { @@ -305,26 +305,30 @@ class Signal extends Group { this.lamps[0].setColor(this.style.Signal.lamp.greenColor); } } + this.virtualSignal && this.virtualSignal.setColor(this.style.Signal.lamp.greenColor); + if (this.style.Signal.lamp.guidName == 'haerbin_01') { // 设置底座颜色 + this.sigPost.setColor('#00FF00'); + } } /* count 1单灯 2双灯 lightType 逻辑点灯 true,物理点灯 false */ openLateral() { // 侧向开放 if (this.count == 2 && !this.model.lightType) { if (this.lamps[0]) { this.lamps[0].setStop(false); - this.lamps[0].setColor(this.style.backgroundColor); + this.lamps[0].setColor(this.style.Signal.lamp.yellowColor); } if (this.lamps[1]) { this.lamps[1].setStop(false); - this.lamps[1].setColor(this.style.Signal.lamp.yellowColor); + this.lamps[1].setColor(this.style.backgroundColor); } } else if (this.count == 2 && this.model.lightType) { if (this.lamps[0]) { this.lamps[0].setStop(true); - this.lamps[0].setColor(this.style.backgroundColor); + this.lamps[0].setColor(this.style.Signal.lamp.yellowColor); } if (this.lamps[1]) { this.lamps[1].setStop(true); - this.lamps[1].setColor(this.style.Signal.lamp.yellowColor); + this.lamps[1].setColor(this.style.backgroundColor); } } else if (this.count == 1 && !this.model.lightType) { if (this.lamps[0]) { @@ -342,6 +346,9 @@ class Signal extends Group { this.lamps[0].setColor(this.style.Signal.lamp.greenColor); } } + if (this.style.Signal.lamp.guidName == 'haerbin_01') { // 设置底座颜色 + this.sigPost.setColor('#00FF00'); + } } // 列车进路 trainRoute() { @@ -362,9 +369,12 @@ class Signal extends Group { // 引导 guid() { - if (this.style.Signal.lamp.guidName == 'ningbo_01') { + if (this.style.Signal.lamp.guidName == 'ningbo_01' || this.style.Signal.lamp.guidName == 'haerbin_01') { this.lamps[1].show(); } + if (this.style.Signal.lamp.guidName == 'haerbin_01') { // 设置底座颜色 + this.sigPost.setColor('#00FF00'); + } if (this.count == 2 && !this.model.lightType && this.style.Signal.lamp.guidName != 'chengdu_03') { // 双灯 物理点灯 允许引导信号 if (this.lamps[0]) { this.lamps[0].setStop(false); @@ -384,7 +394,9 @@ class Signal extends Group { block() { if (this.count == 1) { this.lamps[0].setColor(this.style.Signal.lamp.redColor); - // this.siglamp.setNameBorder(1) + } + if (this.style.Signal.lamp.guidName == 'haerbin_01') { // 设置底座颜色 + this.sigPost.setColor('#000080'); } this.sigName.setColor(this.style.Signal.text.blockColor); if (this.style.Signal.text.nameBorderShow) { @@ -482,6 +494,7 @@ class Signal extends Group { this.sigAuto.animationRecover(); this.sigRoute.hide(); this.sigName.setColor(this.style.Signal.text.defaultColor); + this.sigPost.setColor(this.style.Signal.post.standardColor); // 设置底座默认颜色 if (this.style.Signal.lamp.guidName == 'chengdu_03') { this.lamps[0].setStyle({ lineWidth: this.style.Signal.lamp.borderWidth }); } @@ -506,10 +519,16 @@ class Signal extends Group { model.blockade && this.block(); /** 设置灯的颜色 */ + // model.redOpen = 0; + // model.yellowOpen = 0; + // model.greenOpen = 1; model.redOpen && model.yellowOpen && !model.greenOpen && this.guid(); // 引导信号显示 model.redOpen && !model.yellowOpen && !model.greenOpen && this.close(); // 信号关闭 model.greenOpen && !model.redOpen && !model.yellowOpen && this.openPositive(); // 信号正向开放 model.yellowOpen && !model.redOpen && !model.greenOpen && this.openLateral(); // 信号侧向开放 + if (this.style.Signal.lamp.guidName == 'haerbin_01') { // 设置底座颜色 + model.yellowOpen && !model.redOpen && !model.greenOpen && this.openPositive(); // 信号侧向开放 + } /** 进路交人工控或自动控 */ !model.atsControl && this.setArtificialRouteClose(); diff --git a/src/jmapNew/theme/haerbin_01/menus/menuBar.vue b/src/jmapNew/theme/haerbin_01/menus/menuBar.vue index f94446720..2ed61b32d 100644 --- a/src/jmapNew/theme/haerbin_01/menus/menuBar.vue +++ b/src/jmapNew/theme/haerbin_01/menus/menuBar.vue @@ -215,7 +215,7 @@ export default {