Browse Source

[完善]完善待审核页面的审批意见功能

zhuzhou
邵佳豪 4 years ago
parent
commit
9adf9c585f
  1. 3
      src/app/plan-audit/wait-examineer/wait-examineer.component.html
  2. 4
      src/app/plan-audit/wait-examineer/wait-examineer.component.scss
  3. 38
      src/app/plan-audit/wait-examineer/wait-examineer.component.ts

3
src/app/plan-audit/wait-examineer/wait-examineer.component.html

@ -276,6 +276,9 @@
<div class="fireForceAudit" *ngIf="showtype == 13"> <div class="fireForceAudit" *ngIf="showtype == 13">
<app-fireforce-audit [FireForceDetailInfo]="fireForceDetailInfo" [level]="postlevel"></app-fireforce-audit> <app-fireforce-audit [FireForceDetailInfo]="fireForceDetailInfo" [level]="postlevel"></app-fireforce-audit>
</div> </div>
<div class="emptyContent" *ngIf="showtype == 666">
<span>该提交内容为空,从未保存过,请驳回该审核</span>
</div>
<!-- 联动力量审核 --> <!-- 联动力量审核 -->
<div class="LinkageForcesAudit" *ngIf="showtype == 14"> <div class="LinkageForcesAudit" *ngIf="showtype == 14">
<app-linkageforces-audit [LinkageForceDetailInfo]="LinkageForceDetailInfo"></app-linkageforces-audit> <app-linkageforces-audit [LinkageForceDetailInfo]="LinkageForceDetailInfo"></app-linkageforces-audit>

4
src/app/plan-audit/wait-examineer/wait-examineer.component.scss

@ -129,6 +129,10 @@
height: 100%; height: 100%;
box-sizing: border-box; box-sizing: border-box;
} }
.emptyContent{
width: 100%;
text-align: center;
}
} }
} }
th,td{ th,td{

38
src/app/plan-audit/wait-examineer/wait-examineer.component.ts

@ -115,7 +115,6 @@ export class WaitExamineerComponent implements OnInit {
//获取表格数据 //获取表格数据
getAlltabledate(){ getAlltabledate(){
let paramsdata:any = { let paramsdata:any = {
Operation:this.level||[], Operation:this.level||[],
ContentType:Number(this.projectlevel)||[], ContentType:Number(this.projectlevel)||[],
@ -123,14 +122,12 @@ export class WaitExamineerComponent implements OnInit {
verifyState:[0,3] verifyState:[0,3]
} }
this.http.get("/api/ContentVerifies",{params:paramsdata}).subscribe((data:any)=>{ this.http.get("/api/ContentVerifies",{params:paramsdata}).subscribe((data:any)=>{
console.log(data)
this.tableDate=data.items this.tableDate=data.items
this.count=data.totalCount this.count=data.totalCount
}) })
} }
//提交查询 //提交查询
onSubmit(value){ onSubmit(value){
//console.log(value)
this.getAlltabledate() this.getAlltabledate()
} }
//刷新 //刷新
@ -183,10 +180,18 @@ export class WaitExamineerComponent implements OnInit {
}else{ }else{
this.postlevel = data.level this.postlevel = data.level
} }
console.log('xxx',data) if(data.fireForceDetailInfo && data.fireForceDetailInfo.location){
data.fireForceDetailInfo.location ? null : data.fireForceDetailInfo.location={x:null,y:null} this.fireForceDetailInfo = data.fireForceDetailInfo
this.fireForceDetailInfo = data.fireForceDetailInfo this.showtype = 13
this.showtype = 13 }else if(!data.fireForceDetailInfo){
//提示 该提交内容为空,从未保存过,请驳回该审核
this.showtype = 666
} else {
data.fireForceDetailInfo.location={x:null,y:null}
this.fireForceDetailInfo = data.fireForceDetailInfo
this.showtype = 13
}
}) })
}else if(item.contentType == 14){ }else if(item.contentType == 14){
//联动力量 //联动力量
@ -297,7 +302,6 @@ export class WaitExamineerComponent implements OnInit {
this.compantData={name:'',buildingTypes:[],address:''} 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(data)
if(data.planType==1){ if(data.planType==1){
this.twoOrthree=2 this.twoOrthree=2
}else if(data.planType==2){ }else if(data.planType==2){
@ -347,14 +351,14 @@ export class WaitExamineerComponent implements OnInit {
const config = new MatSnackBarConfig(); const config = new MatSnackBarConfig();
config.verticalPosition = 'top'; config.verticalPosition = 'top';
config.duration = 3000 config.duration = 3000
console.log(this.shenheTable)
if(this.shenheTable.length==0){ if(this.shenheTable.length==0){
this.snackBar.open('请勾选要审核的条目!','确定',config); this.snackBar.open('请勾选要审核的条目!','确定',config);
} }
else{ else{
const dialogRef =this.dialog.open(remark,{width:'460px',height:'290px',data:{shenhedata:this.shenheTable,type:1,radioid:this.radioid}}); const dialogRef =this.dialog.open(remark,{width:'460px',height:'290px',data:{shenhedata:this.shenheTable,type:1,radioid:this.radioid}});
dialogRef.afterClosed().subscribe(result => { dialogRef.afterClosed().subscribe(result => {
this.shenheTable=[] this.shenheTable = []
this.showtype = -1
this.getAlltabledate() this.getAlltabledate()
}); });
} }
@ -373,12 +377,11 @@ export class WaitExamineerComponent implements OnInit {
else{ else{
const dialogRef =this.dialog.open(remark,{width:'460px',height:'290px',data:{shenhedata:this.shenheTable,type:2,radioid:this.radioid}}); const dialogRef =this.dialog.open(remark,{width:'460px',height:'290px',data:{shenhedata:this.shenheTable,type:2,radioid:this.radioid}});
dialogRef.afterClosed().subscribe(result => { dialogRef.afterClosed().subscribe(result => {
this.shenheTable=[] this.shenheTable = []
this.showtype = -1
this.getAlltabledate() this.getAlltabledate()
}); });
} }
//this.shenheTable=[]
} }
@ -530,7 +533,6 @@ 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)
this.threedUrl=this.sanitizer.bypassSecurityTrustResourceUrl(this.data.url.changingThisBreaksApplicationSecurity) this.threedUrl=this.sanitizer.bypassSecurityTrustResourceUrl(this.data.url.changingThisBreaksApplicationSecurity)
} }
threedUrl threedUrl
@ -545,7 +547,6 @@ export class show3D{
export class remark{ export class remark{
constructor(private http:HttpClient,private sanitizer: DomSanitizer,public dialogRef: MatDialogRef<remark>,@Inject(MAT_DIALOG_DATA) public data,public dialog: MatDialog,public snackBar: MatSnackBar) {} constructor(private http:HttpClient,private sanitizer: DomSanitizer,public dialogRef: MatDialogRef<remark>,@Inject(MAT_DIALOG_DATA) public data,public dialog: MatDialog,public snackBar: MatSnackBar) {}
ngOnInit(): void { ngOnInit(): void {
console.log(this.data)
this.shenheTable=this.data.shenhedata this.shenheTable=this.data.shenhedata
this.radioid=this.data.radioid this.radioid=this.data.radioid
} }
@ -567,7 +568,7 @@ export class remark{
config.duration = 3000 config.duration = 3000
if(this.data.type==1){ if(this.data.type==1){
//同意操作 //同意操作
console.log(this.shenheTable) // console.log(this.shenheTable)
//单个审核 //单个审核
if(this.shenheTable.length == 1){ if(this.shenheTable.length == 1){
//重点单位审核 //重点单位审核
@ -586,7 +587,6 @@ export class remark{
//this.getAlltabledate() //this.getAlltabledate()
}) })
}else if(this.shenheTable[0].contentType == 12 || this.shenheTable[0].contentType == 13 || this.shenheTable[0].contentType == 14){ }else if(this.shenheTable[0].contentType == 12 || this.shenheTable[0].contentType == 13 || this.shenheTable[0].contentType == 14){
console.log(1111,this.shenheTable[0])
let body:any = { let body:any = {
id:this.shenheTable[0].id, id:this.shenheTable[0].id,
itemId:this.shenheTable[0].itemId, itemId:this.shenheTable[0].itemId,
@ -597,9 +597,7 @@ export class remark{
} }
this.http.put(`/api/ContentVerifies`,body).subscribe(data=>{ this.http.put(`/api/ContentVerifies`,body).subscribe(data=>{
this.snackBar.open('操作成功!','确定',config); this.snackBar.open('操作成功!','确定',config);
//this.showtype = -1
this.dialogRef.close() this.dialogRef.close()
//this.getAlltabledate()
}) })
}else{ }else{
//预案审核 //预案审核
@ -644,7 +642,6 @@ export class remark{
this.http.put(`/api/ContentVerifies/Batch`,this.companyAgreeList).subscribe(data=>{ this.http.put(`/api/ContentVerifies/Batch`,this.companyAgreeList).subscribe(data=>{
this.snackBar.open('操作成功!','确定',config); this.snackBar.open('操作成功!','确定',config);
this.dialogRef.close() this.dialogRef.close()
//this.getAlltabledate()
}) })
}else{ //批量审核预案 }else{ //批量审核预案
for(var i=0;i<this.shenheTable.length;i++){ for(var i=0;i<this.shenheTable.length;i++){
@ -658,7 +655,6 @@ export class remark{
this.http.put(`/api/PlanAudits/Batch`,this.agreeList).subscribe(data=>{ this.http.put(`/api/PlanAudits/Batch`,this.agreeList).subscribe(data=>{
this.snackBar.open('操作成功!','确定',config); this.snackBar.open('操作成功!','确定',config);
this.dialogRef.close() this.dialogRef.close()
//this.getAlltabledate()
}) })
} }
this.shenheTable=[] this.shenheTable=[]

Loading…
Cancel
Save