调整宁波线路区段计算提示位置逻辑
This commit is contained in:
parent
649704d3ee
commit
901dad45ee
@ -815,14 +815,14 @@ export default class Section extends Group {
|
||||
/** 计算提示位置*/
|
||||
getShapeTipPoint() {
|
||||
let rect = this.getBoundingRect();
|
||||
let distance = this.style.Section.line.width / 2;
|
||||
const distance = this.style.Section.line.width / 2;
|
||||
if (this.section) {
|
||||
rect = this.section.getBoundingRect();
|
||||
if (this.model.type !== '02' && this.model.nameShow) {
|
||||
if (this.model.trainPosType == '01') {
|
||||
distance = distance + this.style.Section.text.distance + this.style.Section.text.fontSize;
|
||||
}
|
||||
}
|
||||
// if (this.model.type !== '02' && this.model.nameShow) {
|
||||
// if (this.model.trainPosType == '01') {
|
||||
// distance = distance + this.style.Section.text.distance + this.style.Section.text.fontSize;
|
||||
// }
|
||||
// }
|
||||
}
|
||||
return {
|
||||
x: rect.x + rect.width / 2,
|
||||
|
@ -237,7 +237,10 @@ export default {
|
||||
},
|
||||
// 设置速度
|
||||
setSpeed() {
|
||||
const sectionCode = this.selected.parentCode ? this.selected.parentCode : this.selected.code;
|
||||
let sectionCode = this.selected.code;
|
||||
if (this.selected.type == '02' || this.selected.type == '03') {
|
||||
sectionCode = this.selected.parentCode;
|
||||
}
|
||||
commitOperate(menuOperate.Section.setSpeed, {sectionCode:sectionCode}, 0).then(({valid, operate})=>{
|
||||
if (valid) {
|
||||
this.$refs.speedLimitControl.doShow(operate, this.selected);
|
||||
|
Loading…
Reference in New Issue
Block a user