diff --git a/src/jmap/shape/Signal/ESigAuto.js b/src/jmap/shape/Signal/ESigAuto.js index e7d31d827..70044bf00 100644 --- a/src/jmap/shape/Signal/ESigAuto.js +++ b/src/jmap/shape/Signal/ESigAuto.js @@ -1,6 +1,6 @@ import Polygon from 'zrender/src/graphic/shape/Polygon'; import Group from 'zrender/src/container/Group'; -import { arrows } from '../utils/ShapePoints'; +import { arrow } from '../utils/ShapePoints'; class ESigPass extends Group { constructor(model) { @@ -14,10 +14,10 @@ class ESigPass extends Group { const model = this.model; const style = this.model.style; const rotation = model.drict != 1? 0 : Math.PI; - const point = arrows(model.x, model.y, style.Signal.signalAutoWidth, style.Signal.lamp.radiusR * 0.8); + const point = arrow(model.x, model.y, style.Signal.signalAutoWidth, style.Signal.lamp.radiusR * 0.8); this.isNew = true; - this.arrows = new Polygon({ + this.arrow = new Polygon({ zlevel: model.zlevel, z: model.z, rotation: rotation, @@ -30,20 +30,20 @@ class ESigPass extends Group { fill: model.fill } }); - this.add(this.arrows); + this.add(this.arrow); } } // 停止动画 animationRecover() { this.create(); - this.arrows.stopAnimation(false); + this.arrow.stopAnimation(false); } // 箭头颜色 setColor(color) { this.create(); - this.arrows.setStyle('fill', color); + this.arrow.setStyle('fill', color); } // 箭头闪烁 @@ -51,9 +51,9 @@ class ESigPass extends Group { this.create(); const style = this.model.style; - const fill = this.arrows.style.Signal.fill; + const fill = this.arrow.style.fill; - this.arrows.animate(true) + this.arrow.animate(true) .when(1000, { fill: style.backgroundColor, stroke: style.style.backgroundColor }) .when(2000, { fill: fill, stroke: style.style.Signal.sidelineColor }) .when(3000, { fill: style.style.backgroundColor, stroke: style.style.backgroundColor }) @@ -64,7 +64,7 @@ class ESigPass extends Group { // 隐藏 hide() { this.create(); - this.arrows.hide(); + this.arrow.hide(); } // 显示 diff --git a/src/jmap/shape/Signal/index.js b/src/jmap/shape/Signal/index.js index 181671a5a..51a738823 100644 --- a/src/jmap/shape/Signal/index.js +++ b/src/jmap/shape/Signal/index.js @@ -459,6 +459,7 @@ class Signal extends Group { } /** 设置自动类型*/ + model.autoType = '04'; switch (model.autoType) { case '01': this.setAutoClose(); break; // 隐藏 隐藏自动信号和自动进路 case '02': this.setAutoSignalOpen(); break; // 显示 设置自动信号模式状态类型 @@ -467,12 +468,12 @@ class Signal extends Group { } /** 延时解锁*/ - model.delayType = '02'; - switch (model.delayType) { - case '01': this.setDelayUnlock(); break; // 未延时解锁 - case '02': this.setDelayUnlock(); break; // 人工闭塞延时解锁 - case '03': this.setDelayUnlock(); break; // 自动闭塞延时解锁 - } + // model.delayType = '02'; + // switch (model.delayType) { + // case '01': this.setDelayUnlock(); break; // 未延时解锁 + // case '02': this.setDelayUnlock(); break; // 人工闭塞延时解锁 + // case '03': this.setDelayUnlock(); break; // 自动闭塞延时解锁 + // } /** 信号机进路办理,先停止动画,再判断当前颜色是否闪烁*/ if (model.routeSetting && (model.autoType == '03' || model.autoType == '04')) {