From e0211317a92ed309ab50d12d3c8a7a41c8bf9a56 Mon Sep 17 00:00:00 2001 From: liuxianghui <519646741@qq.com> Date: Wed, 23 Feb 2022 14:06:43 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E9=98=80=E9=97=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/babylon/controller/config-manager.ts | 1 + src/app/babylon/controller/data-manager.ts | 4 ++- .../data/institution/building/export-data.ts | 18 +++++++++++++ .../property-data/in/property-data-fm.ts | 25 +++++++++++++++++++ .../model/data/institution/jyz-show-data.ts | 5 ++++ .../data/model-data/model-data-facility.ts | 5 ++++ .../view/facility-window/facility-window.ts | 4 +++ .../facilityinfoinscene-window.ts | 7 ++++-- 8 files changed, 66 insertions(+), 3 deletions(-) create mode 100644 src/app/babylon/model/data/institution/facility/property-data/in/property-data-fm.ts diff --git a/src/app/babylon/controller/config-manager.ts b/src/app/babylon/controller/config-manager.ts index da722ab..77bc248 100644 --- a/src/app/babylon/controller/config-manager.ts +++ b/src/app/babylon/controller/config-manager.ts @@ -99,6 +99,7 @@ export class ConfigManager { case FacilityType.JY_YG: result = "油罐"; break; case FacilityType.JY_SYGX: result = "输油管线"; break; case FacilityType.JY_YQHSGX: result = "油气回收管线"; break; + case FacilityType.JY_FM: result = "阀门"; break; } return result; } diff --git a/src/app/babylon/controller/data-manager.ts b/src/app/babylon/controller/data-manager.ts index 4a0c15c..0f1495f 100644 --- a/src/app/babylon/controller/data-manager.ts +++ b/src/app/babylon/controller/data-manager.ts @@ -12,6 +12,7 @@ import { import { ExportData } from '../model/data/institution/building/export-data'; import { AllFacilityData } from '../model/data/institution/facility/all-facility-data'; import { PropertyData_Base_IMG } from '../model/data/institution/facility/property-data/base/property-data-base-img'; +import { PropertyData_FM } from '../model/data/institution/facility/property-data/in/property-data-fm'; import { PropertyData_JYJ } from '../model/data/institution/facility/property-data/in/property-data-jyj'; import { PropertyData_MHQ } from '../model/data/institution/facility/property-data/in/property-data-mhq'; import { PropertyData_SYGX } from '../model/data/institution/facility/property-data/in/property-data-sygx'; @@ -482,9 +483,10 @@ export class DataManager { case FacilityType.XF_MHQ_GF_25: case FacilityType.XF_MHQ_GF_35: result = new PropertyData_MHQ(key, facilityType); break; case FacilityType.JY_JYJ: result = new PropertyData_JYJ(key, "", "", "", "", "", "",); break; - case FacilityType.JY_YG: result = new PropertyData_YG(key, "", "", "", "", "","", ""); break; + case FacilityType.JY_YG: result = new PropertyData_YG(key, "", "", "", "", "", "", ""); break; case FacilityType.JY_SYGX: result = new PropertyData_SYGX(key); break; case FacilityType.JY_YQHSGX: result = new PropertyData_YQHSGX(key); break; + case FacilityType.JY_FM: result = new PropertyData_FM(key, ""); break; } diff --git a/src/app/babylon/model/data/institution/building/export-data.ts b/src/app/babylon/model/data/institution/building/export-data.ts index 7e584ff..58bd81c 100644 --- a/src/app/babylon/model/data/institution/building/export-data.ts +++ b/src/app/babylon/model/data/institution/building/export-data.ts @@ -3,6 +3,7 @@ import { ConfigManager } from "src/app/babylon/controller/config-manager"; import { TsTool } from "src/app/babylon/tool/ts-tool"; import { FacilityType } from "../../model-data/model-data-facility"; import { FacilityDatasByType } from "../../model-data/model-edit-data"; +import { PropertyData_FM } from "../facility/property-data/in/property-data-fm"; import { PropertyData_JYJ } from "../facility/property-data/in/property-data-jyj"; import { PropertyData_SYGX } from "../facility/property-data/in/property-data-sygx"; import { PropertyData_YG } from "../facility/property-data/in/property-data-yg"; @@ -28,6 +29,8 @@ export class ExportData { // @Type(() => ExportData_XFSB) 消防设备: ExportData_XFSB[] = []; + 阀门: ExportData_FM[] = [] + constructor(facilityByTypes: FacilityDatasByType[]) { for (let i = 0; i < facilityByTypes.length; i++) { let facilities = facilityByTypes[i].facilities; @@ -53,6 +56,8 @@ export class ExportData { break; case FacilityType.JY_YQHSGX: this.油气回收.push(new ExportData_YQHS(facilities[j].propertyData as PropertyData_YQHSGX)); break; + case FacilityType.JY_FM: this.阀门.push(new ExportData_FM(facilities[j].propertyData as PropertyData_FM)); + break; } } } @@ -161,3 +166,16 @@ export class ExportData_XFSB { } } +/** + * 导出的阀门 + */ +export class ExportData_FM { + 名称: string; + 描述: string; + + constructor(yqhs_property: PropertyData_FM) { + this.名称 = yqhs_property.name; + this.描述 = yqhs_property.describe; + + } +} \ No newline at end of file diff --git a/src/app/babylon/model/data/institution/facility/property-data/in/property-data-fm.ts b/src/app/babylon/model/data/institution/facility/property-data/in/property-data-fm.ts new file mode 100644 index 0000000..099a199 --- /dev/null +++ b/src/app/babylon/model/data/institution/facility/property-data/in/property-data-fm.ts @@ -0,0 +1,25 @@ + +import { FacilityType } from "../../../../model-data/model-data-facility"; +import { PropertyData_Base } from "../property-data-base"; + +/** + * 阀门 + */ +export class PropertyData_FM extends PropertyData_Base { + + describe: string = "";//描述 + + constructor(key: string, describe: string) { + super(key, FacilityType.JY_FM); + this.name = "未命名"; + this.describe = describe; + + } + + clone(key: string) { + let result = new PropertyData_FM(key, this.describe); + result.name = this.name; + return result; + } + +} \ No newline at end of file diff --git a/src/app/babylon/model/data/institution/jyz-show-data.ts b/src/app/babylon/model/data/institution/jyz-show-data.ts index 23e717f..b587ebb 100644 --- a/src/app/babylon/model/data/institution/jyz-show-data.ts +++ b/src/app/babylon/model/data/institution/jyz-show-data.ts @@ -74,6 +74,11 @@ export enum JYZInfoMoudleType { */ AQSS = "AQSS", + /** + * 阀门 + */ + FM = "FM", + /** * 罩棚 */ diff --git a/src/app/babylon/model/data/model-data/model-data-facility.ts b/src/app/babylon/model/data/model-data/model-data-facility.ts index d68554f..99c7922 100644 --- a/src/app/babylon/model/data/model-data/model-data-facility.ts +++ b/src/app/babylon/model/data/model-data/model-data-facility.ts @@ -243,6 +243,11 @@ export enum FacilityType { */ JY_YQHSGX = "JY_YQHSGX", + /** + * 阀门 + */ + JY_FM = "JY_FM", + /** * 油气回收管线 阻挡物 */ diff --git a/src/app/babylon/view/facility-window/facility-window.ts b/src/app/babylon/view/facility-window/facility-window.ts index 9751073..f10f0c1 100644 --- a/src/app/babylon/view/facility-window/facility-window.ts +++ b/src/app/babylon/view/facility-window/facility-window.ts @@ -662,6 +662,10 @@ export class FacilityWindow extends UIBase { // console.log("找到油气回收", mesh) this.createNewFacilityByMesh(mesh, FacilityType.JY_YQHSGX); } + else if (TsTool.stringContain(mesh.name, FacilityType.JY_FM)) { + console.log("找到阀门", mesh) + this.createNewFacilityByMesh(mesh, FacilityType.JY_FM); + } } /** diff --git a/src/app/babylon/view/facilityinfoinscene-window/facilityinfoinscene-window.ts b/src/app/babylon/view/facilityinfoinscene-window/facilityinfoinscene-window.ts index 9347015..a222e04 100644 --- a/src/app/babylon/view/facilityinfoinscene-window/facilityinfoinscene-window.ts +++ b/src/app/babylon/view/facilityinfoinscene-window/facilityinfoinscene-window.ts @@ -507,6 +507,7 @@ export class FacilityInfoInSceneWindow extends UIBase { || (currentMoudle == null || currentMoudle == JYZInfoMoudleType.YG) && facilityInfosByType[i].type == FacilityType.JY_YG || (currentMoudle == null || currentMoudle == JYZInfoMoudleType.SYG) && facilityInfosByType[i].type == FacilityType.JY_SYGX || (currentMoudle == null || currentMoudle == JYZInfoMoudleType.YQHSGX) && facilityInfosByType[i].type == FacilityType.JY_YQHSGX + || (currentMoudle == null || currentMoudle == JYZInfoMoudleType.FM) && facilityInfosByType[i].type == FacilityType.JY_FM ) { allJYJInfo = allJYJInfo.concat(facilityInfosByType[i].facilityInfo); } @@ -552,9 +553,10 @@ export class FacilityInfoInSceneWindow extends UIBase { if (facilityData.facilityType != FacilityType.JY_JYJ && facilityData.facilityType != FacilityType.JY_YG && facilityData.facilityType != FacilityType.JY_SYGX && - facilityData.facilityType != FacilityType.JY_YQHSGX + facilityData.facilityType != FacilityType.JY_YQHSGX && + facilityData.facilityType != FacilityType.JY_FM ) { - //只有加油机和油罐和输油管、油气回收有高亮显示和取消 + //只有加油机和油罐和输油管、油气回收、阀门有高亮显示和取消 return; } //} @@ -567,6 +569,7 @@ export class FacilityInfoInSceneWindow extends UIBase { || BuildingWindow.instance.currentJYZInfoMoudleType == JYZInfoMoudleType.YG || BuildingWindow.instance.currentJYZInfoMoudleType == JYZInfoMoudleType.SYG || BuildingWindow.instance.currentJYZInfoMoudleType == JYZInfoMoudleType.YQHSGX + || BuildingWindow.instance.currentJYZInfoMoudleType == JYZInfoMoudleType.FM ) { SceneManager.Instance.removeFromHighLight(facilityInfo.modelBox as Mesh); } From 15792612b1bcee60c0d6fc89612bdcb5c97376fa Mon Sep 17 00:00:00 2001 From: cpf <1105965053@qq.com> Date: Wed, 23 Feb 2022 14:26:12 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E9=98=80=E9=97=A8=E5=AE=8C=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/pages/plan/plan.component.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/app/pages/plan/plan.component.ts b/src/app/pages/plan/plan.component.ts index 3b47b46..ca77515 100644 --- a/src/app/pages/plan/plan.component.ts +++ b/src/app/pages/plan/plan.component.ts @@ -173,7 +173,7 @@ export class PlanComponent implements OnInit { //开发模式 选择单位 弹窗 modelInit(InsList) { } - allFence: string[] = ["基本信息", "加油机", "油罐设备", "消防设施", "安全疏散", "输油管线", "油气回收", "应急预案"]; //头部 功能栏 + allFence: string[] = ["基本信息", "加油机", "油罐设备", "消防设施", "安全疏散", "输油管线", "油气回收", "应急预案", "阀门"]; //头部 功能栏 baseInfoMarks: baseInfoMark[] = [new baseInfoMark("毗邻"), new baseInfoMark("区域"), new baseInfoMark("图片"), new baseInfoMark("点位")] //基本信息 设备筛选list selectFence: number = -1; //选中 头部功能栏 isShowChildComponent: boolean = false; //是否 显示左侧子组件 @@ -238,6 +238,8 @@ export class PlanComponent implements OnInit { fenceType = JYZInfoMoudleType.YQHSGX } else if (type === 7) { fenceType = JYZInfoMoudleType.YJCZ + } else if (type === 8) { + fenceType = JYZInfoMoudleType.YJCZ } return fenceType } From 4671f0d5a60ce5ea9d9d0200a477260b9148dae1 Mon Sep 17 00:00:00 2001 From: cpf <1105965053@qq.com> Date: Wed, 23 Feb 2022 15:00:59 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E9=98=80=E9=97=A8=E5=AE=8C=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/left-domain/left-domain.component.html | 15 +++++++++++++++ .../pages/left-domain/left-domain.component.ts | 4 +++- src/app/pages/plan/plan.component.ts | 2 +- 3 files changed, 19 insertions(+), 2 deletions(-) diff --git a/src/app/pages/left-domain/left-domain.component.html b/src/app/pages/left-domain/left-domain.component.html index 891bfe6..c5457af 100644 --- a/src/app/pages/left-domain/left-domain.component.html +++ b/src/app/pages/left-domain/left-domain.component.html @@ -205,6 +205,21 @@ + +
描述
+