소스 검색

fix intersection point geo file

Victor Domingues 5 년 전
부모
커밋
22cbf54398
2개의 변경된 파일2개의 추가작업 그리고 4개의 파일을 삭제
  1. 1 3
      src/app/components/intersection-component/models/intersection-model.js
  2. 1 1
      src/app/core/models/application/actions/action.js

+ 1 - 3
src/app/components/intersection-component/models/intersection-model.js

@@ -10,9 +10,7 @@ export class IntersectionModel extends PointModel {
     this.visible = visible;
     this.index = index;
     this.color = -65536;
-    this.definitions = [];
-    this.definitions.push(this.r);
-    this.definitions.push(this.s);
+    this.definitions = [{ id: this.r.id }, { id: this.s.id }, { id: this.index + 1 }];
   }
 
   update(aggregator, event) {

+ 1 - 1
src/app/core/models/application/actions/action.js

@@ -56,7 +56,7 @@ export class Action {
     return `${key}:${value}`;
   }
   r(str) {
-    return str.replace(",", " ");
+    return str.replace(/,/g, " ");
   }
   rehydrate() {
     this.id = this.genericObject.id;