调整修改区段bug
This commit is contained in:
parent
5feb81e1c1
commit
7ce6cf6e8a
@ -429,7 +429,7 @@ export default {
|
||||
this.handleInit();
|
||||
this.activeName = 'first';
|
||||
this.editModel = deepAssign(this.editModel, selected);
|
||||
this.oldPoint = selected.points;
|
||||
this.oldPoint = JSON.parse(JSON.stringify(selected.points));
|
||||
this.oldLeftSectionCode = selected.leftSectionCode;
|
||||
this.oldRightSectionCode = selected.rightSectionCode;
|
||||
if (this.field.toUpperCase() === 'splitSection'.toUpperCase()) {
|
||||
@ -540,7 +540,8 @@ export default {
|
||||
copySection.stationCode = model.stationCode; // 给元素 子逻辑区段设置 设备集中站
|
||||
if (this.checkPointsCoincide(this.oldPoint[0], copySection.points[0])) {
|
||||
copySection.points[0] = model.points[0];
|
||||
} else if (this.checkPointsCoincide(this.oldPoint[this.oldPoint.length - 1], copySection.points[copySection.points.length - 1])) {
|
||||
}
|
||||
if (this.checkPointsCoincide(this.oldPoint[this.oldPoint.length - 1], copySection.points[copySection.points.length - 1])) {
|
||||
copySection.points[copySection.points.length - 1] = model.points[model.points.length - 1];
|
||||
}
|
||||
models.push(copySection);
|
||||
@ -653,6 +654,9 @@ export default {
|
||||
!sectionMap[startPoint].deepFlag && models.push(model);
|
||||
startOffset = (startOffset * 1000 + model.lengthFact * 1000) / 1000;
|
||||
startPoint = model.points[model.points.length - 1].x + 's' + model.points[model.points.length - 1].y;
|
||||
if (model.points[model.points.length - 1].x == model.points[0].x && model.points[model.points.length - 1].y == model.points[0].y) {
|
||||
return models;
|
||||
}
|
||||
}
|
||||
}
|
||||
return models;
|
||||
|
Loading…
Reference in New Issue
Block a user