diff --git a/debug.log b/debug.log index 0411790..9ef0104 100644 --- a/debug.log +++ b/debug.log @@ -1,3 +1,4 @@ [1214/094922.722:ERROR:directory_reader_win.cc(43)] FindFirstFile: 系统找不到指定的路径。 (0x3) [1215/082617.914:ERROR:directory_reader_win.cc(43)] FindFirstFile: 系统找不到指定的路径。 (0x3) [1215/093432.367:ERROR:directory_reader_win.cc(43)] FindFirstFile: 系统找不到指定的路径。 (0x3) +[1217/083219.853:ERROR:directory_reader_win.cc(43)] FindFirstFile: 系统找不到指定的路径。 (0x3) diff --git a/src/app/canvas-share-data.service.ts b/src/app/canvas-share-data.service.ts index bca405e..59bcfa3 100644 --- a/src/app/canvas-share-data.service.ts +++ b/src/app/canvas-share-data.service.ts @@ -81,14 +81,20 @@ export class CanvasShareDataService { const returnData = this.allDisposalNode.find(item => item.id === parentId); return returnData; } + } + /** + * 鏇存柊寤虹瓚鏁版嵁 + */ + public updateBuildingData() { + } /** * 鑾峰彇鍗曚綅姣楅偦淇℃伅 */ public getCompanyAdjoinInfo(): CompanyAdjoinInfo[] { const list: CompanyAdjoinInfo[] = []; - Object.keys(this.originaleveryStoreyData.data).forEach((key) => { - const item = this.originaleveryStoreyData.data[key]; + Object.keys(this.originalcompanyBuildingData.data).forEach((key) => { + const item = this.originalcompanyBuildingData.data[key]; if (item.Name === '姣楅偦') { const adjoin = new CompanyAdjoinInfo(); adjoin.AssetId = item.Id; @@ -114,8 +120,8 @@ export class CanvasShareDataService { */ public getBuildingAdjoinInfo(): BuildingAdjoinInfo[] { const list: BuildingAdjoinInfo[] = []; - Object.keys(this.originaleveryStoreyData.data).forEach((key) => { - const item = this.originaleveryStoreyData.data[key]; + Object.keys(this.originalcompanyBuildingData.data).forEach((key) => { + const item = this.originalcompanyBuildingData.data[key]; if (item.Name === '姣楅偦') { const adjoin = new BuildingAdjoinInfo(); adjoin.AssetId = item.Id; @@ -141,8 +147,8 @@ export class CanvasShareDataService { */ public getCompanyImportantLocations(): CompanyImportantLocationInfo[] { const list: CompanyImportantLocationInfo[] = []; - Object.keys(this.originaleveryStoreyData.data).forEach((key) => { - const item = this.originaleveryStoreyData.data[key]; + Object.keys(this.originalcompanyBuildingData.data).forEach((key) => { + const item = this.originalcompanyBuildingData.data[key]; if (item.Name === '閲嶇偣閮ㄤ綅') { const important = new CompanyImportantLocationInfo(); important.AssetId = item.Id; @@ -174,8 +180,8 @@ export class CanvasShareDataService { */ public getBuildingImportantLocations(): BuildingImportantLocationInfo[] { const list: BuildingImportantLocationInfo[] = []; - Object.keys(this.originaleveryStoreyData.data).forEach((key) => { - const item = this.originaleveryStoreyData.data[key]; + Object.keys(this.originalcompanyBuildingData.data).forEach((key) => { + const item = this.originalcompanyBuildingData.data[key]; if (item.Name === '閲嶇偣閮ㄤ綅') { const important = new BuildingImportantLocationInfo(); important.AssetId = item.Id; @@ -207,8 +213,8 @@ export class CanvasShareDataService { */ public getAllCompanyFacilityAssetInfo(): CompanyFacilityAssetInfo[] { const list: CompanyFacilityAssetInfo[] = []; - Object.keys(this.originaleveryStoreyData.data).forEach((key) => { - const item = this.originaleveryStoreyData.data[key]; + Object.keys(this.originalcompanyBuildingData.data).forEach((key) => { + const item = this.originalcompanyBuildingData.data[key]; if (this.facilityAssetsName.has(item.Name)) { const facility = new CompanyFacilityAssetInfo(); facility.CompanyId = sessionStorage.getItem('companyId'); @@ -228,8 +234,8 @@ export class CanvasShareDataService { */ public getAllBuildingFacilityAssetInfo(): BuildingFacilityAssetInfo[] { const list: BuildingFacilityAssetInfo[] = []; - Object.keys(this.originaleveryStoreyData.data).forEach((key) => { - const item = this.originaleveryStoreyData.data[key]; + Object.keys(this.originalcompanyBuildingData.data).forEach((key) => { + const item = this.originalcompanyBuildingData.data[key]; if (this.facilityAssetsName.has(item.Name)) { const facility = new BuildingFacilityAssetInfo(); facility.BuildingId = this.selectStorey.buildingId; diff --git a/src/app/ui/collection-tools/collection-tools.component.ts b/src/app/ui/collection-tools/collection-tools.component.ts index 4712954..2bb3e4c 100644 --- a/src/app/ui/collection-tools/collection-tools.component.ts +++ b/src/app/ui/collection-tools/collection-tools.component.ts @@ -715,7 +715,7 @@ export class CollectionToolsComponent implements OnInit { //鎵归噺淇濆瓨寤虹瓚娑堥槻璁炬柦绱犳潗 let buildingFacilityAssets = this.canvasData.getAllBuildingFacilityAssetInfo() - this.http.post(`/api/CompanyAccount/BuildingFacilityAssets/Batch?buildingId=${this.canvasData.selectStorey.buildingId}&buildingAreaId=${this.canvasData.selectStorey.id}`,buildingFacilityAssets).subscribe(data => { + this.http.post(`/api/CompanyAccount/BuildingFacilityAssets/Batch?buildingId=${this.canvasData.selectStorey.buildingId}`,buildingFacilityAssets).subscribe(data => { this.saveNum.push("1") if(this.saveNum.length == 5){ this.canvasData.isChange = false diff --git a/src/app/working-area/working-area.component.ts b/src/app/working-area/working-area.component.ts index 7368ed4..d5b4dad 100644 --- a/src/app/working-area/working-area.component.ts +++ b/src/app/working-area/working-area.component.ts @@ -159,66 +159,26 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV this.selection.objects.forEach(item => { if (this.allowEdit && this.canvasData.gameMode === item.assetData.GameMode) { - console.log(this.canvasData.gameMode); - switch (this.canvasData.gameMode) { - case 0: - delete this.canvasData.originaleveryStoreyData.data[item.assetData.Id]; - this.backgroundImage.removeChild(this.backgroundImage.getChildByName(item.assetData.Id)); - this.canvasData.isChange = true; - break; - case 1: - delete this.canvasData.selectPanelPoint.Data.DefinedIncrement[item.assetData.Id]; - delete this.canvasData.selectPanelPoint.Data.Increment[item.assetData.Id]; - delete this.canvasData.selectPanelPoint.Data.Stock[item.assetData.Id]; - this.backgroundImage.removeChild(this.backgroundImage.getChildByName(item.assetData.Id)); - this.canvasData.isChange = true; - break; + switch (this.canvasData.gameMode) { + case 0: + delete this.canvasData.originaleveryStoreyData.data[item.assetData.Id]; + this.backgroundImage.removeChild(this.backgroundImage.getChildByName(item.assetData.Id)); + this.canvasData.isChange = true; + break; + case 1: + delete this.canvasData.selectPanelPoint.Data.DefinedIncrement[item.assetData.Id]; + delete this.canvasData.selectPanelPoint.Data.Increment[item.assetData.Id]; + delete this.canvasData.selectPanelPoint.Data.Stock[item.assetData.Id]; + this.backgroundImage.removeChild(this.backgroundImage.getChildByName(item.assetData.Id)); + this.canvasData.isChange = true; + break; } - this.selection.deselectAll(); - } + } }); + this.selection.deselectAll(); this.emit('deleteIcon'); } }); - // 鎵撳嵃褰撳墠宸ヤ綔鍖轰俊鎭 - this.eventManager.addGlobalEventListener('window', 'keypress', (event: any) => { - // console.log(event.keyCode); - if (event.keyCode === 32) { - switch (this.paintMode) { - case 0: - console.log(`褰撳墠鐨勭粯鍒舵ā寮忔槸锛氬崟鐐瑰浘鏍嘸); - break; - case 1: - console.log(`褰撳墠鐨勭粯鍒舵ā寮忔槸锛氱嚎娈靛浘鏍嘸); - break; - case 2: - console.log(`褰撳墠鐨勭粯鍒舵ā寮忔槸锛氳嚜瀹氫箟澶氳竟褰); - break; - case 3: - console.log(`褰撳墠鐨勭粯鍒舵ā寮忔槸锛氭按甯﹀杈瑰舰`); - break; - case 4: - console.log(`褰撳墠鐨勭粯鍒舵ā寮忔槸锛氭殏鏃燻); - break; - case 5: - console.log(`褰撳墠鐨勭粯鍒舵ā寮忔槸锛氭殏鏃燻); - break; - case 6: - console.log(`褰撳墠鐨勭粯鍒舵ā寮忔槸锛氱粨鏉熺粯鍒禶); - break; - default: - break; - } - console.log('褰撳墠妤煎眰鐨勬暟鎹細'); - console.log(this.canvasData.originaleveryStoreyData.data); - - console.log('缁樺埗涓殑绠$嚎锛'); - console.log(this.paintingPipeline); - - console.log('澶勭疆棰勬鏁版嵁锛'); - console.log(this.canvasData.selectPanelPoint.Data); - } - }); } /** * 椤甸潰鍒濆鍖 @@ -321,6 +281,9 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV this.circleShadow.position = this.backgroundImage.toLocal(this.mousePosition); this.refreshPreviewLineSegment(this.currentClickPoint.position, this.circleShadow.position); } + /** + * 鏄剧ず妗嗛 + */ if (this.rectToolGraphics.visible === true) { const init = this.initialScreenMousePos; @@ -339,18 +302,12 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV this.rectToolGraphics.drawRect(final.x, final.y, init.x - final.x, init.y - final.y); } this.rectToolGraphics.endFill(); - // this.rectToolGraphics.closePath(); } - // if (this.paintingArrows !== null) { - // this.paintingArrows.assetData.pointB = new PIXI.Point(this.circleShadow.position.x, this.circleShadow.position.y); - // this.paintingArrows.refresh(); - // } }); /** * 閫変腑浜嬩欢 */ this.on('select', obj => { - // this.moveIconToScreenCenter(obj); if (this.allowEdit) { if (obj instanceof MultipointIcon) { if (obj.assetData.GameMode === this.canvasData.gameMode) { @@ -388,6 +345,9 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV obj.filters = []; } }); + /** + * 鏍规嵁鑳屾櫙缂╂斁浜嬩欢 + */ this.on('backgroundScale', scale => { this.backgroundImage?.children.forEach(item => { if (item instanceof AxImageShape) { @@ -414,9 +374,13 @@ export class WorkingAreaComponent extends EventEmitter implements OnInit, AfterV }); }); + /** + * 鍒涘缓鍥炬爣浜嬩欢 + */ this.on('createIcon', obj => { if (obj.assetData.GameMode === GameMode.BasicInformation) { - this.canvasData.originaleveryStoreyData.data[obj.assetData.Id] = obj.assetData; + // 娣诲姞妤煎眰鏁版嵁 + this.canvasData.originaleveryStoreyData.data[obj.assetData.Id] = obj.assetData; } else { if (this.canvasData.selectPanelPoint.Data === undefined || this.canvasData.selectPanelPoint.Data === null) {