|
|
@ -4,7 +4,7 @@ |
|
|
|
* @Author: sueRimn |
|
|
|
* @Author: sueRimn |
|
|
|
* @Date: 2020-12-25 16:13:50 |
|
|
|
* @Date: 2020-12-25 16:13:50 |
|
|
|
* @LastEditors: sueRimn |
|
|
|
* @LastEditors: sueRimn |
|
|
|
* @LastEditTime: 2021-02-06 10:51:26 |
|
|
|
* @LastEditTime: 2021-02-07 14:37:44 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
import { Component, Inject, OnInit } from '@angular/core'; |
|
|
|
import { Component, Inject, OnInit } from '@angular/core'; |
|
|
|
import { FormControl } from '@angular/forms'; |
|
|
|
import { FormControl } from '@angular/forms'; |
|
|
@ -79,6 +79,7 @@ export class WaitExamineerComponent implements OnInit { |
|
|
|
ngOnDestroy () { |
|
|
|
ngOnDestroy () { |
|
|
|
/* this.indexbar.clear() |
|
|
|
/* this.indexbar.clear() |
|
|
|
this.indexbar.dispose() */ |
|
|
|
this.indexbar.dispose() */ |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
iframeSrc |
|
|
|
iframeSrc |
|
|
@ -151,13 +152,16 @@ export class WaitExamineerComponent implements OnInit { |
|
|
|
this.getAlltabledate() |
|
|
|
this.getAlltabledate() |
|
|
|
} |
|
|
|
} |
|
|
|
//radio点击事件
|
|
|
|
//radio点击事件
|
|
|
|
|
|
|
|
viewer//全景图对象
|
|
|
|
radioClick(e,item){ |
|
|
|
radioClick(e,item){ |
|
|
|
//e.target.parentElement.bgColor='#2196F3'
|
|
|
|
//e.target.parentElement.bgColor='#2196F3'
|
|
|
|
console.log(e,item) |
|
|
|
console.log(e,item) |
|
|
|
|
|
|
|
this.organizationName='' |
|
|
|
this.id=item.id |
|
|
|
this.id=item.id |
|
|
|
this.fetchUrl='' |
|
|
|
this.fetchUrl='' |
|
|
|
|
|
|
|
this.viewer={} |
|
|
|
this.http.get(`/api/PlanComponents/${item.itemId}`).subscribe((data:any)=>{ |
|
|
|
this.http.get(`/api/PlanComponents/${item.itemId}`).subscribe((data:any)=>{ |
|
|
|
|
|
|
|
console.log(data) |
|
|
|
this.companyId=data.companyId |
|
|
|
this.companyId=data.companyId |
|
|
|
this.companyName=data.companyName |
|
|
|
this.companyName=data.companyName |
|
|
|
if(data.planType!=2&&data.planType!=1){ |
|
|
|
if(data.planType!=2&&data.planType!=1){ |
|
|
@ -166,7 +170,7 @@ export class WaitExamineerComponent implements OnInit { |
|
|
|
if(this.fetchUrl.substr(0,index)=='psw'){ |
|
|
|
if(this.fetchUrl.substr(0,index)=='psw'){ |
|
|
|
this.showtype=1 |
|
|
|
this.showtype=1 |
|
|
|
window.setTimeout(()=>{ |
|
|
|
window.setTimeout(()=>{ |
|
|
|
const viewer = new Viewer({ |
|
|
|
this.viewer = new Viewer({ |
|
|
|
container: document.querySelector('#viewer'), |
|
|
|
container: document.querySelector('#viewer'), |
|
|
|
panorama:'/api/Objects/PlanPlatform/'+ this.fetchUrl, |
|
|
|
panorama:'/api/Objects/PlanPlatform/'+ this.fetchUrl, |
|
|
|
|
|
|
|
|
|
|
@ -178,7 +182,10 @@ export class WaitExamineerComponent implements OnInit { |
|
|
|
} |
|
|
|
} |
|
|
|
}else{ |
|
|
|
}else{ |
|
|
|
this.organizationName=item.organizationName |
|
|
|
this.organizationName=item.organizationName |
|
|
|
this.getPlanData() |
|
|
|
this.planData = data |
|
|
|
|
|
|
|
this.handleData() |
|
|
|
|
|
|
|
return |
|
|
|
|
|
|
|
|
|
|
|
//this.src=`/planAudit/planpass?id=${data.companyId}&companyName=${data.companyName}&auditPlanId=${data.id}&auditStatus=${data.auditStatus}&planType=1`
|
|
|
|
//this.src=`/planAudit/planpass?id=${data.companyId}&companyName=${data.companyName}&auditPlanId=${data.id}&auditStatus=${data.auditStatus}&planType=1`
|
|
|
|
//this.iframeSrc=this.sanitizer.bypassSecurityTrustResourceUrl(this.src);
|
|
|
|
//this.iframeSrc=this.sanitizer.bypassSecurityTrustResourceUrl(this.src);
|
|
|
|
//window.open(`/planAudit/planpass?id=${data.companyId}&companyName=${data.companyName}&auditPlanId=${data.id}&auditStatus=${data.auditStatus}&planType=1`)
|
|
|
|
//window.open(`/planAudit/planpass?id=${data.companyId}&companyName=${data.companyName}&auditPlanId=${data.id}&auditStatus=${data.auditStatus}&planType=1`)
|
|
|
@ -232,43 +239,40 @@ export class WaitExamineerComponent implements OnInit { |
|
|
|
//window.open(`http://121.5.10.84/apps/editor/openPreview?data=${base64}`)
|
|
|
|
//window.open(`http://121.5.10.84/apps/editor/openPreview?data=${base64}`)
|
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
getPlanData () { |
|
|
|
|
|
|
|
let header = {
|
|
|
|
|
|
|
|
CompanyName: this.companyName || '', |
|
|
|
|
|
|
|
//AuditStatus: this.id || '',
|
|
|
|
|
|
|
|
PageSize: '100', |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
console.log(header) |
|
|
|
|
|
|
|
this.http.get('/api/PlanAudits',{params:header}).subscribe((data:any)=>{ |
|
|
|
|
|
|
|
data.items.forEach(element => { |
|
|
|
|
|
|
|
/* if (element.id===this.id) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} */ |
|
|
|
|
|
|
|
this.planData = element |
|
|
|
|
|
|
|
this.organizationName = element.committerOrganizationName |
|
|
|
|
|
|
|
this.handleData() |
|
|
|
|
|
|
|
return |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//查看二维三维预案
|
|
|
|
//查看二维三维预案
|
|
|
|
thirdPartyURL |
|
|
|
thirdPartyURL |
|
|
|
planType |
|
|
|
planType |
|
|
|
|
|
|
|
twoOrthree |
|
|
|
handleData () { |
|
|
|
handleData () { |
|
|
|
|
|
|
|
this.compantData={name:'',buildingTypes:[],address:''} |
|
|
|
this.planType = this.planData.planMode |
|
|
|
this.planType = this.planData.planMode |
|
|
|
let data = this.planData |
|
|
|
let data = this.planData |
|
|
|
console.log(this.planData) |
|
|
|
console.log(data) |
|
|
|
|
|
|
|
if(data.planType==1){ |
|
|
|
|
|
|
|
this.twoOrthree=2 |
|
|
|
|
|
|
|
}else if(data.planType==2){ |
|
|
|
|
|
|
|
this.twoOrthree=3 |
|
|
|
|
|
|
|
} |
|
|
|
if (this.planData.planMode==0) { //预案planMode=0时, 查看word
|
|
|
|
if (this.planData.planMode==0) { //预案planMode=0时, 查看word
|
|
|
|
//this.lookWord()
|
|
|
|
//this.lookWord()
|
|
|
|
} else if (this.planData.planMode==1) { //预案planMode=1时, 解析文档
|
|
|
|
} else if (this.planData.planMode==1) { //预案planMode=1时, 解析文档
|
|
|
|
|
|
|
|
|
|
|
|
} else if (this.planData.planMode==2) { //预案planMode=2时, 跳查看页面组件
|
|
|
|
} else if (this.planData.planMode==2) { //预案planMode=2时, 跳查看页面组件
|
|
|
|
|
|
|
|
this.showtype=2 |
|
|
|
|
|
|
|
this.http.get(`/api/Plans/${data.companyId}`).subscribe((data:any)=>{ |
|
|
|
|
|
|
|
data && data.company? this.compantData = data.company : null |
|
|
|
|
|
|
|
}) |
|
|
|
sessionStorage.setItem("buildingTypeId", this.compantData.buildingTypes.length? this.compantData.buildingTypes[0].id: undefined); |
|
|
|
sessionStorage.setItem("buildingTypeId", this.compantData.buildingTypes.length? this.compantData.buildingTypes[0].id: undefined); |
|
|
|
sessionStorage.setItem("companyId",this.companyId); |
|
|
|
sessionStorage.setItem("companyId",this.companyId); |
|
|
|
sessionStorage.setItem("planId",this.id); |
|
|
|
sessionStorage.setItem("planId",this.id); |
|
|
|
sessionStorage.setItem("editable",'0'); |
|
|
|
sessionStorage.setItem("editable",'0'); |
|
|
|
} else if (this.planData.planMode==3) { //预案planMode=3时, 第三方网址
|
|
|
|
sessionStorage.setItem("planName",data.name) |
|
|
|
|
|
|
|
let companyId = sessionStorage.getItem("companyId") |
|
|
|
|
|
|
|
this.thirdPartyURL=this.sanitizer.bypassSecurityTrustResourceUrl(`/planAudit/planpass?id=${this.companyId}&companyName=${data.companyName}&auditPlanId=${data.id}&auditStatus=${data.auditStatus}&planType=1`); |
|
|
|
|
|
|
|
//window.open(`/keyUnit/viewunitinfoplan?id=${companyId}`)
|
|
|
|
|
|
|
|
} else if (this.planData.planMode==3) { //预案planMode=3时, 第三方网址'
|
|
|
|
this.showtype=2 |
|
|
|
this.showtype=2 |
|
|
|
this.http.get(`/api/Plans/${data.companyId}`).subscribe((data:any)=>{ |
|
|
|
this.http.get(`/api/Plans/${data.companyId}`).subscribe((data:any)=>{ |
|
|
|
data && data.company? this.compantData = data.company : null |
|
|
|
data && data.company? this.compantData = data.company : null |
|
|
@ -281,7 +285,7 @@ export class WaitExamineerComponent implements OnInit { |
|
|
|
|
|
|
|
|
|
|
|
//打开三维预案弹窗
|
|
|
|
//打开三维预案弹窗
|
|
|
|
oopen3Dshow(){ |
|
|
|
oopen3Dshow(){ |
|
|
|
this.dialog.open(show3D,{width:'1550px',height:'850px',data:{url:this.thirdPartyURL}}); |
|
|
|
this.dialog.open(show3D,{width:'1650px',height:'850px',data:{url:this.thirdPartyURL,twoOrthree:this.twoOrthree}}); |
|
|
|
} |
|
|
|
} |
|
|
|
//变更数据和全部数据切换按钮
|
|
|
|
//变更数据和全部数据切换按钮
|
|
|
|
buttonChange(){ |
|
|
|
buttonChange(){ |
|
|
@ -518,7 +522,7 @@ export class WaitExamineerComponent implements OnInit { |
|
|
|
export class show3D{ |
|
|
|
export class show3D{ |
|
|
|
constructor(private sanitizer: DomSanitizer,public dialogRef: MatDialogRef<show3D>,@Inject(MAT_DIALOG_DATA) public data,public dialog: MatDialog) {} |
|
|
|
constructor(private sanitizer: DomSanitizer,public dialogRef: MatDialogRef<show3D>,@Inject(MAT_DIALOG_DATA) public data,public dialog: MatDialog) {} |
|
|
|
ngOnInit(): void { |
|
|
|
ngOnInit(): void { |
|
|
|
console.log(this.data.url.changingThisBreaksApplicationSecurity) |
|
|
|
console.log(this.data) |
|
|
|
this.threedUrl=this.sanitizer.bypassSecurityTrustResourceUrl(this.data.url.changingThisBreaksApplicationSecurity) |
|
|
|
this.threedUrl=this.sanitizer.bypassSecurityTrustResourceUrl(this.data.url.changingThisBreaksApplicationSecurity) |
|
|
|
} |
|
|
|
} |
|
|
|
threedUrl |
|
|
|
threedUrl |
|
|
|