From 32bdff9496a1dc1add88714b6b6a1ad93fd75b22 Mon Sep 17 00:00:00 2001 From: cpf <1105965053@qq.com> Date: Tue, 18 Aug 2020 09:44:25 +0800 Subject: [PATCH] =?UTF-8?q?[=E5=AE=8C=E5=96=84]=20=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E4=B8=AD=E5=AD=98=E5=82=A8=E6=95=B0=E6=8D=AE=E5=AE=8C=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/canvas-share-data.service.ts | 1 + .../ui/collection-tools/collection-tools.component.ts | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/app/canvas-share-data.service.ts b/src/app/canvas-share-data.service.ts index 3cc2c43..49ae59d 100644 --- a/src/app/canvas-share-data.service.ts +++ b/src/app/canvas-share-data.service.ts @@ -7,6 +7,7 @@ export class CanvasShareDataService { constructor() { } + selectStorey:any; //选择当前 楼层 数据 originalcompanyBuildingData:any; // 单位/建筑 数据 originaleveryStoreyData:any; // 总平面图/楼层/区域 楼层数据 diff --git a/src/app/ui/collection-tools/collection-tools.component.ts b/src/app/ui/collection-tools/collection-tools.component.ts index c808898..5eca7a7 100644 --- a/src/app/ui/collection-tools/collection-tools.component.ts +++ b/src/app/ui/collection-tools/collection-tools.component.ts @@ -709,7 +709,8 @@ export class CollectionToolsComponent implements OnInit { this.getSitePlanCompanyData() //获取 单位 数据 this.http.get('/api/CompanyAccount/SitePlans').subscribe(data=>{ this.sitePlanData = data - this.selectingSitePlan = this.sitePlanData[0] || '' + this.selectingSitePlan = this.sitePlanData[0] || {} + this.canvasData.selectStorey = this.sitePlanData[0] || {} //服务中 存一份数据 this.selectSitePlanIndex = 0 this.getSitePlanStorey(this.selectingSitePlan) //获取 平面图 楼层数据 @@ -725,7 +726,8 @@ export class CollectionToolsComponent implements OnInit { this.getBuildingData(params) //获取 建筑 数据 this.http.get('/api/CompanyAccount/BuildingAreas',{params}).subscribe(data=>{ this.sitePlanData = data - this.selectingSitePlan = this.sitePlanData[0] || '' + this.selectingSitePlan = this.sitePlanData[0] || {} + this.canvasData.selectStorey = this.sitePlanData[0] || {} //服务中 存一份数据 this.selectSitePlanIndex = 0 this.getBuildingStorey(this.selectingSitePlan) //获取 建筑 楼层数据 @@ -781,6 +783,7 @@ export class CollectionToolsComponent implements OnInit { if (this.selectSitePlanIndex != index) { this.selectingSitePlan = item this.selectSitePlanIndex = index + this.canvasData.selectStorey = item //服务中 存一份数据 if (this.checkedBuildingIndex==-1) { //总平面图时 this.getSitePlanStorey(item) //获取 平面图 楼层数据 } else { //楼层/区域时 @@ -997,6 +1000,7 @@ export class CollectionToolsComponent implements OnInit { this.http.get('/api/CompanyAccount/SitePlans').subscribe(data=>{ this.sitePlanData = data this.selectingSitePlan = this.sitePlanData[this.selectSitePlanIndex] + this.canvasData.selectStorey = this.sitePlanData[this.selectSitePlanIndex] //服务中 存一份数据 const config = new MatSnackBarConfig(); config.verticalPosition = 'top'; config.duration = 3000 @@ -1012,6 +1016,7 @@ export class CollectionToolsComponent implements OnInit { this.http.get('/api/CompanyAccount/BuildingAreas',{params}).subscribe(data=>{ this.sitePlanData = data this.selectingSitePlan = this.sitePlanData[this.selectSitePlanIndex] + this.canvasData.selectStorey = this.sitePlanData[this.selectSitePlanIndex] //服务中 存一份数据 const config = new MatSnackBarConfig(); config.verticalPosition = 'top'; config.duration = 3000