|
|
|
@ -79,8 +79,8 @@ export class PlanComponent implements OnInit {
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
ngAfterViewInit(): void { |
|
|
|
|
this.getGasStationBaseInfo().then((res: any)=>{ //获取单位 基本信息
|
|
|
|
|
console.log(res,"当前加油站信息") |
|
|
|
|
this.getGasStationBaseInfo().then((res: any) => { //获取单位 基本信息
|
|
|
|
|
console.log(res, "当前加油站信息") |
|
|
|
|
let simpleData: InsitutionDataSimple = new InsitutionDataSimple(); |
|
|
|
|
simpleData.id = res.id || 1; //来自选中的单位的信息 ,测试:1
|
|
|
|
|
simpleData.key = `${res.id}` || "ceshi"; //测试:"ceshi"
|
|
|
|
@ -91,6 +91,7 @@ export class PlanComponent implements OnInit {
|
|
|
|
|
if (ModeManager.institutionDemoKey == ModeManager.c_demoKey_null) { //无指定测试单位,则为正式启动,根据当前单位key寻找
|
|
|
|
|
if (has3dData) { //如果已经有三维数据,直接进入
|
|
|
|
|
this.beforeOneSatus = StatusManager.getStatus<LoginSatus>(LoginSatus); |
|
|
|
|
console.log("单位数据", simpleData); |
|
|
|
|
this.beforeOneSatus.onSelectInsSuccess(simpleData) |
|
|
|
|
} else { //如果没有三维数据
|
|
|
|
|
if (ModeManager.s_isMakeMode) //内部制作模式下,询问新建
|
|
|
|
@ -130,7 +131,7 @@ export class PlanComponent implements OnInit {
|
|
|
|
|
getGasStationBaseInfo() { |
|
|
|
|
return new Promise((resolve, reject) => { |
|
|
|
|
let params = { organizationUnitId: this.companyData.id } |
|
|
|
|
this.http.get('/api/services/app/GasStation/Get', { params: params }).subscribe((data: any)=>{ |
|
|
|
|
this.http.get('/api/services/app/GasStation/Get', { params: params }).subscribe((data: any) => { |
|
|
|
|
resolve(data.result) |
|
|
|
|
}) |
|
|
|
|
}) |
|
|
|
@ -158,22 +159,22 @@ export class PlanComponent implements OnInit {
|
|
|
|
|
this.initializePlan() |
|
|
|
|
} |
|
|
|
|
if (type === 7) { //初始化 应急预案 data
|
|
|
|
|
this.isShowChildComponent && this.leftDomain? this.leftDomain.initComponent(type) : null; //手动初始化子组件
|
|
|
|
|
this.isShowChildComponent && this.leftDomain ? this.leftDomain.initComponent(type) : null; //手动初始化子组件
|
|
|
|
|
this.selectFence = type |
|
|
|
|
this.editMode? this.isShowChildComponent = true : this.isShowChildComponent = false |
|
|
|
|
this.editMode ? this.isShowChildComponent = true : this.isShowChildComponent = false |
|
|
|
|
buildingWindow.changeJYZInfoModel(fenceType, true) |
|
|
|
|
MarkWindow.instance ? this.allMarkPlanData = MarkWindow.instance.allMarkPlanData : null; |
|
|
|
|
babylonEventManager.addListener(Event_GetAllMarkPlanData, (data: Event_GetAllMarkPlanData) => { |
|
|
|
|
this.allMarkPlanData = MarkWindow.instance.allMarkPlanData |
|
|
|
|
this.isShowChildComponent && this.leftDomain? this.leftDomain.allMarkPlanData = MarkWindow.instance.allMarkPlanData : null |
|
|
|
|
this.isShowChildComponent && this.leftDomain ? this.leftDomain.allMarkPlanData = MarkWindow.instance.allMarkPlanData : null |
|
|
|
|
}) |
|
|
|
|
this.isShowChildComponent && this.leftDomain? this.leftDomain.allMarkPlanData = MarkWindow.instance.allMarkPlanData : null |
|
|
|
|
this.isShowChildComponent && this.leftDomain ? this.leftDomain.allMarkPlanData = MarkWindow.instance.allMarkPlanData : null |
|
|
|
|
} else { |
|
|
|
|
this.isShowChildComponent && this.leftDomain && type != 4 ? this.leftDomain.initComponent(type) : null; //手动初始化子组件
|
|
|
|
|
this.selectFence = type |
|
|
|
|
this.isShowChildComponent = true |
|
|
|
|
buildingWindow.changeJYZInfoModel(fenceType, true) |
|
|
|
|
if (type === 0) { this.baseInfoMarks.forEach(item=>{ item.isShow = true }) } //初始化基本信息 设备显隐
|
|
|
|
|
if (type === 0) { this.baseInfoMarks.forEach(item => { item.isShow = true }) } //初始化基本信息 设备显隐
|
|
|
|
|
} |
|
|
|
|
} else { //取消选中
|
|
|
|
|
this.selectFence = -1 |
|
|
|
@ -389,7 +390,7 @@ export class PlanComponent implements OnInit {
|
|
|
|
|
window.setTimeout(() => { |
|
|
|
|
this.propertyImg = new Viewer(this.element.nativeElement.querySelector('#propertyImg'), { url: 'data-original' }); |
|
|
|
|
}, 0) |
|
|
|
|
}
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
//上传设备 图片
|
|
|
|
@ -438,8 +439,8 @@ export class PlanComponent implements OnInit {
|
|
|
|
|
publicToggleNode() { |
|
|
|
|
return new Promise((resolve, reject) => { |
|
|
|
|
this.beforePlanNode = this.beforeEmergencyPlan.nodes[this.nzCurrent] |
|
|
|
|
this.isShowChildComponent && this.leftDomain? this.leftDomain.selectPlanId = this.beforeEmergencyPlan.id : null |
|
|
|
|
this.isShowChildComponent && this.leftDomain? this.leftDomain.selectNodeId = this.beforePlanNode.id : null |
|
|
|
|
this.isShowChildComponent && this.leftDomain ? this.leftDomain.selectPlanId = this.beforeEmergencyPlan.id : null |
|
|
|
|
this.isShowChildComponent && this.leftDomain ? this.leftDomain.selectNodeId = this.beforePlanNode.id : null |
|
|
|
|
MarkWindow.instance.selectMarkNode(this.beforeEmergencyPlan.id, this.beforePlanNode.id, false, true) |
|
|
|
|
this.beforePlanNode = MarkWindow.instance.currentMarkNodeInfo.nodeData |
|
|
|
|
this.initViewer() |
|
|
|
@ -649,7 +650,7 @@ export class PlanComponent implements OnInit {
|
|
|
|
|
} |
|
|
|
|
this.isShowLoading = true //打开遮罩
|
|
|
|
|
let institutionKey = sessionStorage.getItem('unitId') || "ceshi"; //单位id
|
|
|
|
|
let resType = isVideo? ResType.Video : ResType.Texture |
|
|
|
|
let resType = isVideo ? ResType.Video : ResType.Texture |
|
|
|
|
let key = `${(new Date()).getMonth() + 1}-${(new Date()).getDate()}-${(new Date()).getHours()}` |
|
|
|
|
let url = DataManager.getResPath_mark(institutionKey, resType, key) //url
|
|
|
|
|
ServeManager.instance.openFileSelect(file, url, (name: string, path: string) => { //上传
|
|
|
|
@ -821,7 +822,7 @@ export class modelBuilding {
|
|
|
|
|
modelType: BuildingType = BuildingType.Normal; |
|
|
|
|
} |
|
|
|
|
//基本信息 设备筛选
|
|
|
|
|
export class baseInfoMark{ |
|
|
|
|
export class baseInfoMark { |
|
|
|
|
markerName: string; |
|
|
|
|
isShow: boolean = true; |
|
|
|
|
constructor(markerName: string) { |
|
|
|
|