merge : kms

This commit is contained in:
gandhimathi 2018-12-26 19:41:29 +05:30
parent 4c082b59b8
commit 9fe055d460
11 changed files with 181 additions and 77 deletions

View File

@ -81,13 +81,14 @@
<!-- <mat-error *ngIf="pdMain.fk_subproduct_id.hasError('required')">Sub Product Required.</mat-error> --> <!-- <mat-error *ngIf="pdMain.fk_subproduct_id.hasError('required')">Sub Product Required.</mat-error> -->
</mat-form-field> </mat-form-field>
<!-- {{customerSegmentList | json}} -->
<mat-form-field style="width: 32%"> <mat-form-field style="width: 32%">
<mat-select placeholder="Customer Segment" formControlName="fk_customer_segment"> <mat-select placeholder="Customer Segment" formControlName="fk_customer_segment">
<mat-option> <mat-option>
Select Select
</mat-option> </mat-option>
<mat-option *ngFor="let CSL of customerSegmentList" [value]="CSL.customer_segment_id" > <mat-option *ngFor="let CSL of customerSegmentList" [value]="CSL.customer_segment_id" >
{{CSL.customer_segment}} {{CSL.abbr}}
</mat-option> </mat-option>
</mat-select> </mat-select>
<!-- <mat-error *ngIf="pdMain.fk_customer_segment.hasError('required')">Customer Segment Required.</mat-error> --> <!-- <mat-error *ngIf="pdMain.fk_customer_segment.hasError('required')">Customer Segment Required.</mat-error> -->
@ -106,8 +107,9 @@
<!-- <mat-error *ngIf="pdMain.fk_pd_type.hasError('required')">PD Type Required.</mat-error> --> <!-- <mat-error *ngIf="pdMain.fk_pd_type.hasError('required')">PD Type Required.</mat-error> -->
</mat-form-field> </mat-form-field>
<mat-form-field style="width: 24%"> <mat-form-field style="width: 32%">
<input matInput placeholder="Loan Amount" formControlName="loan_amount" (keypress)="keyPress($event)"> <input matInput placeholder="Loan Amount" formControlName="loan_amount" (keypress)="keyPress($event)" (keyup)="inWords($event,1)" required autocomplete="off">
<mat-hint align="end" *ngIf="pdMain.loan_amount.value">{{"&#8377;"}} {{loanAmtInWords}} Only</mat-hint>
<!-- <mat-error *ngIf="pdMain.loan_amount.hasError('required')">Amount Required.</mat-error> --> <!-- <mat-error *ngIf="pdMain.loan_amount.hasError('required')">Amount Required.</mat-error> -->
<mat-error *ngIf="pdMain.loan_amount.hasError('pattern')">Enter valid amount. </mat-error> <mat-error *ngIf="pdMain.loan_amount.hasError('pattern')">Enter valid amount. </mat-error>
@ -184,8 +186,9 @@
<mat-error *ngIf="pdMain.mobile_no.hasError('maxlength') || pdMain.mobile_no.hasError('minlength')">Enter Valid Mobile Number. </mat-error> <mat-error *ngIf="pdMain.mobile_no.hasError('maxlength') || pdMain.mobile_no.hasError('minlength')">Enter Valid Mobile Number. </mat-error>
</mat-form-field> </mat-form-field>
<mat-form-field style="width: 10%"> <mat-form-field style="width: 15%">
<input matInput placeholder="STD Code" formControlName="stdcode" type="text" (keypress)="keyPress($event)"> <input matInput placeholder="STD Code" formControlName="stdcode" type="text" (keypress)="keyPress($event)">
<span matPrefix>+91</span>
<mat-error *ngIf="pdMain.stdcode.hasError('maxlength') || pdMain.stdcode.hasError('minlength')">Enter Valid STD Code Number. </mat-error> <mat-error *ngIf="pdMain.stdcode.hasError('maxlength') || pdMain.stdcode.hasError('minlength')">Enter Valid STD Code Number. </mat-error>
</mat-form-field> &nbsp; - &nbsp; </mat-form-field> &nbsp; - &nbsp;
<mat-form-field style="width: 20%"> <mat-form-field style="width: 20%">
@ -264,14 +267,15 @@
<div fxFlex="30" align="end"> <div fxFlex="30" align="end">
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" matTooltip="Reset" matTooltipPosition="above" type="button" <button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" matTooltip="Reset" matTooltipPosition="above" type="button"
(click)="onReset()"><mat-icon>settings_backup_restore</mat-icon></button> (click)="onReset()"><mat-icon>settings_backup_restore</mat-icon></button>
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" (click)="saveDraftPD(_PDtriggerForm.value,draftStatus)" matTooltip="PD Draft" matTooltipPosition="above" type="button"><mat-icon>description</mat-icon></button> <button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" (click)="saveDraftPD(_PDtriggerForm.value,draftStatus)" matTooltip="Save as Draft" matTooltipPosition="above" type="button"><mat-icon>description</mat-icon></button>
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="PD Process" matTooltipPosition="above" (click)="triggerPD(_PDtriggerForm.value,PDTriggerStatus)"><mat-icon>save</mat-icon></button> <button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Trigger PD" matTooltipPosition="above" (click)="triggerPD(_PDtriggerForm.value,PDTriggerStatus)"><mat-icon>save</mat-icon></button>
</div> </div>
</mat-card-actions> </mat-card-actions>
</form> </form>
</mat-card-content> </mat-card-content>
</mat-card> </mat-card>
<notifier-container></notifier-container>

View File

@ -33,6 +33,7 @@ export class AddPdComponent implements OnInit, OnDestroy {
billingList: any; billingList: any;
relationShipList: any; relationShipList: any;
errorMessage: any; errorMessage: any;
loanAmtInWords : any;
// Dynamic co applicant // Dynamic co applicant
createWithLongContent = false; createWithLongContent = false;
dynamicCoApplicant = []; dynamicCoApplicant = [];
@ -272,6 +273,7 @@ export class AddPdComponent implements OnInit, OnDestroy {
// save pd in draft // save pd in draft
saveDraftPD(formValue: any, status:string){ saveDraftPD(formValue: any, status:string){
alert('Inside The Draft PD');
this.submitPdDetails(formValue, status); this.submitPdDetails(formValue, status);
} }
//trigger pd //trigger pd
@ -360,8 +362,11 @@ export class AddPdComponent implements OnInit, OnDestroy {
// common function for both draft and process pd // common function for both draft and process pd
submitPdDetails(formValue: any, status:string) { submitPdDetails(formValue: any, status:string) {
alert('Inside Function Submit Function');
if(this._PDtriggerForm.invalid) { if(this._PDtriggerForm.invalid) {
this.validateAllFormFields(this._PDtriggerForm) this.validateAllFormFields(this._PDtriggerForm);
alert('validationError');
console.log(this._PDtriggerForm);
return; return;
} }
else { else {
@ -490,4 +495,16 @@ validateAllFormFields(formGroup: any) {
}); });
} }
/** To Convert Amount into Words */
inWords(e,flag:number){
switch(flag){
case 1 :
this.loanAmtInWords = this._pd.convertNumberToWords(e.target.value);
break;
default:
break;
}
}
} }

View File

@ -31,8 +31,9 @@
<input matInput placeholder="Mobile Number" formControlName="mobile_no" type="text" (keypress)="keyPress($event)" required> <input matInput placeholder="Mobile Number" formControlName="mobile_no" type="text" (keypress)="keyPress($event)" required>
<mat-error *ngIf="pdMainApplicant.mobile_no.hasError('maxlength') || pdMainApplicant.mobile_no.hasError('minlength')">Enter Valid Mobile Number. </mat-error> <mat-error *ngIf="pdMainApplicant.mobile_no.hasError('maxlength') || pdMainApplicant.mobile_no.hasError('minlength')">Enter Valid Mobile Number. </mat-error>
</mat-form-field> </mat-form-field>
<mat-form-field style="width: 10%"> <mat-form-field style="width: 15%">
<input matInput placeholder="STD Code" formControlName="stdcode" type="text" (keypress)="keyPress($event)"> <input matInput placeholder="STD Code" formControlName="stdcode" type="text" (keypress)="keyPress($event)">
<span matPrefix>+91</span>
<mat-error *ngIf="pdMainApplicant.stdcode.hasError('maxlength') || pdMainApplicant.stdcode.hasError('minlength')">Enter Valid STD Code. </mat-error> <mat-error *ngIf="pdMainApplicant.stdcode.hasError('maxlength') || pdMainApplicant.stdcode.hasError('minlength')">Enter Valid STD Code. </mat-error>
</mat-form-field> &nbsp;-&nbsp; </mat-form-field> &nbsp;-&nbsp;
<mat-form-field style="width: 25%"> <mat-form-field style="width: 25%">
@ -64,8 +65,9 @@
<input matInput placeholder="LandLine Number" formControlName="coapplicant_landline" type="text" (keypress)="keyPress($event)"> <input matInput placeholder="LandLine Number" formControlName="coapplicant_landline" type="text" (keypress)="keyPress($event)">
<mat-error *ngIf=" coDetails['controls'].coapplicant_landline.hasError('maxlength') || coDetails['controls'].coapplicant_landline.hasError('minlength')">Enter Valid Phone Number. </mat-error> <mat-error *ngIf=" coDetails['controls'].coapplicant_landline.hasError('maxlength') || coDetails['controls'].coapplicant_landline.hasError('minlength')">Enter Valid Phone Number. </mat-error>
</mat-form-field> --> </mat-form-field> -->
<mat-form-field style="width: 10%"> <mat-form-field style="width: 15%">
<input matInput placeholder="STD Code" formControlName="coapplicant_stdcode" type="text" (keypress)="keyPress($event)"> <input matInput placeholder="STD Code" formControlName="coapplicant_stdcode" type="text" (keypress)="keyPress($event)">
<span matPrefix>+91</span>
<mat-error *ngIf="coDetails['controls'].coapplicant_stdcode.hasError('maxlength') || coDetails['controls'].coapplicant_stdcode.hasError('minlength')">Enter Valid STD Number. </mat-error> <mat-error *ngIf="coDetails['controls'].coapplicant_stdcode.hasError('maxlength') || coDetails['controls'].coapplicant_stdcode.hasError('minlength')">Enter Valid STD Number. </mat-error>
</mat-form-field> &nbsp;-&nbsp; </mat-form-field> &nbsp;-&nbsp;
<mat-form-field style="width: 25%"> <mat-form-field style="width: 25%">

View File

@ -71,7 +71,7 @@
<mat-select placeholder="Customer Segment" formControlName="fk_customer_segment"> <mat-select placeholder="Customer Segment" formControlName="fk_customer_segment">
<mat-option>Select</mat-option> <mat-option>Select</mat-option>
<mat-option *ngFor="let CSL of customerSegmentList" [value]="CSL.customer_segment_id" > <mat-option *ngFor="let CSL of customerSegmentList" [value]="CSL.customer_segment_id" >
{{CSL.customer_segment}} <!-- {{CSL.customer_segment}} -->{{CSL.abbr}}
</mat-option> </mat-option>
</mat-select> </mat-select>
<!-- <mat-error *ngIf="pdMain.fk_customer_segment.hasError('required')">Customer Segment Required.</mat-error> --> <!-- <mat-error *ngIf="pdMain.fk_customer_segment.hasError('required')">Customer Segment Required.</mat-error> -->
@ -88,7 +88,9 @@
</mat-form-field> </mat-form-field>
<mat-form-field style="width: 24%"> <mat-form-field style="width: 24%">
<input matInput placeholder="Loan Amount" formControlName="loan_amount"> <!-- <input matInput placeholder="Loan Amount" formControlName="loan_amount"> -->
<input matInput placeholder="Loan Amount" formControlName="loan_amount" (keypress)="keyPress($event)" (keyup)="inWords($event,1)" (change)="loanCalc()" required autocomplete="off">
<mat-hint align="end" *ngIf="pdMain.loan_amount.value != ''">{{"&#8377;"}} {{loanAmtInWords}} Only</mat-hint>
<!-- <mat-error *ngIf="pdMain.loan_amount.hasError('required')">Amount Required.</mat-error> --> <!-- <mat-error *ngIf="pdMain.loan_amount.hasError('required')">Amount Required.</mat-error> -->
<mat-error *ngIf="pdMain.loan_amount.hasError('pattern')">Enter valid amount. </mat-error> <mat-error *ngIf="pdMain.loan_amount.hasError('pattern')">Enter valid amount. </mat-error>

View File

@ -26,6 +26,7 @@ export class EditPdMasterComponent implements OnInit {
// PDTriggerStatus: string; // PDTriggerStatus: string;
enablePDButton: boolean; enablePDButton: boolean;
currentPDStatus: string; currentPDStatus: string;
loanAmtInWords : any;
public _EditPDtriggerForm:FormGroup; public _EditPDtriggerForm:FormGroup;
public notifier: NotifierService; public notifier: NotifierService;
// create values for status check // create values for status check
@ -43,6 +44,7 @@ export class EditPdMasterComponent implements OnInit {
@Inject(MAT_DIALOG_DATA) public data: any) { @Inject(MAT_DIALOG_DATA) public data: any) {
this.notifier=notifier this.notifier=notifier
this.currentPDStatus = data.records.pd_status; this.currentPDStatus = data.records.pd_status;
if(this.data.records.loan_amount){ this.loanAmtInWords = this._pd.convertNumberToWords(this.data.records.loan_amount); }
} }
ngOnInit() { ngOnInit() {
@ -280,5 +282,16 @@ validateAllFormFields(formGroup: any) {
}); });
} }
/** To Convert Amount into Words */
inWords(e,flag:number){
switch(flag){
case 1 :
this.loanAmtInWords = this._pd.convertNumberToWords(e.target.value);
break;
default:
break;
}
}
} }

View File

@ -6,6 +6,11 @@
</div> </div>
<mat-card style="min-height:540px;"> <mat-card style="min-height:540px;">
<mat-card-content> <mat-card-content>
<div align="end">
<button mat-raised-button color="blue" (click)="reportReview('REMARKS')" style="padding: 0 28px !important;" [disabled]="qcStatus === 'QC_COMPLETED'">QC Remarks</button>
<button mat-raised-button color="red" (click)="reportReview('COMPLETE')" style="padding: 0 28px !important;" [disabled]="qcStatus === 'QC_COMPLETED'">QC Complete</button>
<!--{{ qcStatus }} -->
</div>
<mat-tab-group> <mat-tab-group>
<mat-tab label="PD Data"> <mat-tab label="PD Data">
<div> <div>
@ -45,8 +50,6 @@
<mat-tab label="PD Report"> <mat-tab label="PD Report">
<div *ngIf="reGenerateBtn"> <div *ngIf="reGenerateBtn">
<mat-card> <mat-card>
<mat-card-content> <mat-card-content>
@ -64,13 +67,13 @@
<hr> <hr>
</button> </button>
<mat-card *ngIf="qcStatus === 'QC_COMPLETED'" style="text-align:center;position: absolute; <!--<mat-card *ngIf="qcStatus === 'QC_COMPLETED'" style="text-align:center;position: absolute;
bottom: 10px;"> <button mat-raised-button color="red" *ngIf="reGenerateBtn" (click)="reportReview()" style="padding: 0 58px !important;">QC Review</button> </mat-card> bottom: 10px;"> <button mat-raised-button color="red" *ngIf="reGenerateBtn" (click)="reportReview()" style="padding: 0 58px !important;">QC Review</button> </mat-card>-->
</mat-sidenav> </mat-sidenav>
<div class="main-content" fxFlex.xs="100" fxFlex.sm="100" fxFlex.md="100" fxFlex.lg="100" fxFlex.xl="100"> <div class="main-content" fxFlex.xs="100" fxFlex.sm="100" fxFlex.md="100" fxFlex.lg="100" fxFlex.xl="100">
{{qcStatus}} <!--{{qcStatus}}-->
<figure style="min-height: 240px;"> <figure style="min-height: 240px;">
<div *ngIf="latestPDDetails"> <div *ngIf="latestPDDetails">

View File

@ -179,9 +179,9 @@ export class PdReportComponent implements OnInit {
reportReview(): void { reportReview(status): void {
const dialogRef = this.dialog.open(QcReviewComponent, { const dialogRef = this.dialog.open(QcReviewComponent, {
data: { startId : this.startPD }, data: { startId : this.startPD, data_status: status },
disableClose: true disableClose: true
}); });
dialogRef.afterClosed() dialogRef.afterClosed()

View File

@ -1,6 +1,36 @@
<h2 mat-dialog-title>QC Completed Review</h2> <div *ngIf="showStatus == 'COMPLETE'">
<h2 mat-dialog-title>QC Complete</h2>
<mat-dialog-content class="mat-typography"> <mat-dialog-content class="mat-typography">
<!--<h3>Develop across all platforms</h3>--> <!--<h3>Develop across all platforms</h3>-->
<div *ngIf="conformation === false" style="width: 220px;text-align: center; margin: 12px;">
<p>
Because you've marked the document as QC Complete, you can't edit this document.
</p>
</div>
<div *ngIf="conformation" style="margin: 12px; width: 340px;">
<form role="form" *ngIf="showForm" [formGroup]="ngForm" accept-charset="UTF-8" novalidate>
<div>
<app-rating [rating]="ngForm.get('qc_rating').value" (ratingClick)='ratingComponentClick($event)'></app-rating>
</div>
<div>
<mat-form-field appearance="outline" style="width: 100%">
<mat-label>Remarks</mat-label>
<textarea matInput placeholder="Remarks" formControlName="qc_feedback"></textarea>
</mat-form-field>
</div>
</form>
</div>
</mat-dialog-content>
<mat-dialog-actions align="end">
<button mat-button class="btn btn-primary" *ngIf="conformation === false" (click)="conformation = true">Ok</button>
<button mat-button class="btn btn-primary" *ngIf="conformation" (click)="myClick()">Save</button>
<button mat-button mat-dialog-close>Cancel</button>
</mat-dialog-actions>
</div>
<div *ngIf="showStatus == 'REMARKS'">
<h2 mat-dialog-title>QC Remarks</h2>
<mat-dialog-content class="mat-typography">
<div style="margin: 12px; width: 340px;"> <div style="margin: 12px; width: 340px;">
<form role="form" *ngIf="showForm" [formGroup]="ngForm" accept-charset="UTF-8" novalidate> <form role="form" *ngIf="showForm" [formGroup]="ngForm" accept-charset="UTF-8" novalidate>
<div> <div>
@ -9,9 +39,6 @@
<textarea matInput placeholder="Remarks" formControlName="qc_remarks"></textarea> <textarea matInput placeholder="Remarks" formControlName="qc_remarks"></textarea>
</mat-form-field> </mat-form-field>
</div> </div>
<div>
<app-rating [rating]="ngForm.get('qc_rating').value" (ratingClick)='ratingComponentClick($event)'></app-rating>
</div>
</form> </form>
</div> </div>
</mat-dialog-content> </mat-dialog-content>
@ -19,5 +46,4 @@
<button mat-button class="btn btn-primary" (click)="myClick()">Save</button> <button mat-button class="btn btn-primary" (click)="myClick()">Save</button>
<button mat-button mat-dialog-close>Cancel</button> <button mat-button mat-dialog-close>Cancel</button>
</mat-dialog-actions> </mat-dialog-actions>
</div>

View File

@ -17,10 +17,12 @@ import {
}) })
export class QcReviewComponent implements OnInit { export class QcReviewComponent implements OnInit {
conformation: Boolean = false;
@Input() questionId: number; @Input() questionId: number;
ngForm: FormGroup; ngForm: FormGroup;
recordData: any; recordData: any;
showForm: Boolean; showForm: Boolean;
showStatus : any;
/** /**
* Notifier service * Notifier service
*/ */
@ -31,7 +33,7 @@ export class QcReviewComponent implements OnInit {
private dialogRef: MatDialogRef<QcReviewComponent>, private dialogRef: MatDialogRef<QcReviewComponent>,
@Inject(MAT_DIALOG_DATA) public data: any) { @Inject(MAT_DIALOG_DATA) public data: any) {
this.notifier = notifier; this.notifier = notifier;
this.showStatus = this.data.data_status;
// this.mycontent = `<p>My html content</p>`; // this.mycontent = `<p>My html content</p>`;
} }
@ -40,19 +42,39 @@ export class QcReviewComponent implements OnInit {
} }
getQcCompleteReviewStatus() { getQcCompleteReviewStatus() {
this.pdTrigerService.getQCReportFinalReviewDetails(this.data.startId, "QC").subscribe(data => { let type ; '';
if( this.showStatus === 'REMARKS'){
type = 'QC_REMARKS';
this.pdTrigerService.getQCReportFinalReviewDetails(this.data.startId, type).subscribe(data => {
if(data['dataStatus']){ if(data['dataStatus']){
this.recordData = data.records[0]; this.recordData = data.records[0];
this.ngForm = this._formBuilder.group({ this.ngForm = this._formBuilder.group({
qc_remarks: [this.recordData.qc_remarks], qc_remarks: [this.recordData.qc_remarks],
qc_rating: [Number(this.recordData.qc_rating)], pd_status: [this.recordData.pd_status]
pd_status: [this.recordData.pd_status],
}) })
this.showForm = true; this.showForm = true;
} }
},err => { },err => {
}); });
} else if(this.showStatus === 'COMPLETE') {
type = 'QC';
this.pdTrigerService.getQCReportFinalReviewDetails(this.data.startId, type).subscribe(data => {
if(data['dataStatus']){
this.recordData = data.records[0];
this.ngForm = this._formBuilder.group({
qc_feedback: [this.recordData.qc_feedback],
qc_rating: [Number(this.recordData.qc_rating)],
pd_status: ["QC_COMPLETED"],
})
this.showForm = true;
}
},err => {
});
} else {
}
} }
onChange($event: any): void { onChange($event: any): void {

View File

@ -13,7 +13,7 @@
<button *ngIf="master.pd_type_name && currentPDStatus!=pdStatusCheck.DRAFT && currentPDStatus!=pdStatusCheck.COMPLETED && currentPDStatus!=pdStatusCheck.QC_COMPLETED" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Schedule" matTooltipPosition="above" (click)="scheduleDetails(master)"><mat-icon>schedule</mat-icon></button> <button *ngIf="master.pd_type_name && currentPDStatus!=pdStatusCheck.DRAFT && currentPDStatus!=pdStatusCheck.COMPLETED && currentPDStatus!=pdStatusCheck.QC_COMPLETED" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Schedule" matTooltipPosition="above" (click)="scheduleDetails(master)"><mat-icon>schedule</mat-icon></button>
<button *ngIf="master.pd_type_name && currentPDStatus!=pdStatusCheck.DRAFT && currentPDStatus!=pdStatusCheck.TRIGGERED && currentPDStatus!=pdStatusCheck.DRAFT && enableStartPD" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Discussion" matTooltipPosition="above" (click)="getPDStart(viewID)"><mat-icon>question_answer</mat-icon></button> <button *ngIf="master.pd_type_name && currentPDStatus!=pdStatusCheck.DRAFT && currentPDStatus!=pdStatusCheck.TRIGGERED && currentPDStatus!=pdStatusCheck.DRAFT && enableStartPD" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Discussion" matTooltipPosition="above" (click)="getPDStart(viewID)"><mat-icon>question_answer</mat-icon></button>
<button *ngIf="master.pd_type_name && currentPDStatus===pdStatusCheck.QC_COMPLETED" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="PD Report" matTooltipPosition="above" (click)="getPDIDReport(viewID)"><mat-icon>ballot</mat-icon></button> <button *ngIf="master.pd_type_name && currentPDStatus===pdStatusCheck.QC_COMPLETED || pdStatusCheck.COMPLETED" mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="PD Report" matTooltipPosition="above" (click)="getPDIDReport(viewID)"><mat-icon>ballot</mat-icon></button>
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close" matTooltipPosition="above" (click)="loadPdListCompoent()"><mat-icon>close</mat-icon></button> <button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close" matTooltipPosition="above" (click)="loadPdListCompoent()"><mat-icon>close</mat-icon></button>
<br> <br>
@ -65,8 +65,6 @@
<p *ngIf="master.remarks"><span style="font-size:13px;"> Remarks : </span> <span style="color:red">{{master.remarks}}</span></p> <p *ngIf="master.remarks"><span style="font-size:13px;"> Remarks : </span> <span style="color:red">{{master.remarks}}</span></p>
</mat-card-content> </mat-card-content>
</mat-card> </mat-card>
</div> </div>
<div fxFlex.xs="100" class="m-gap p-gap" fxFlex.sm="100" fxFlex.md="50" fxFlex.lg="50" fxFlex.xl="50"> <div fxFlex.xs="100" class="m-gap p-gap" fxFlex.sm="100" fxFlex.md="50" fxFlex.lg="50" fxFlex.xl="50">
<!-- applicant card --> <!-- applicant card -->
@ -91,7 +89,7 @@
</span> &nbsp;&nbsp;&nbsp; </span> &nbsp;&nbsp;&nbsp;
<span *ngIf="applicant.landline != '' && applicant.landline != 'null-null' && applicant.landline != null " class="mb-2 text-center hover-icon"> <span *ngIf="applicant.landline != '' && applicant.landline != 'null-null' && applicant.landline != null " class="mb-2 text-center hover-icon">
<i class="fa-1x fa fa-phone"></i> <i class="fa-1x fa fa-phone"></i>
&nbsp;{{applicant.landline}} &nbsp;<span matPrefix>+91</span>{{applicant.landline}}
</span> </span>
<br><span *ngIf="applicant.applicant_type=='1';else codetails" style="font-size:12px;">Main Applicant </span> <br><span *ngIf="applicant.applicant_type=='1';else codetails" style="font-size:12px;">Main Applicant </span>
<ng-template #codetails><span>{{applicant.relation_name}}</span></ng-template> <ng-template #codetails><span>{{applicant.relation_name}}</span></ng-template>
@ -121,12 +119,7 @@
</mat-card-content> </mat-card-content>
<ng-template #noRequirement><mat-card-content><p>No Additional Requirements</p></mat-card-content></ng-template> <ng-template #noRequirement><mat-card-content><p>No Additional Requirements</p></mat-card-content></ng-template>
</mat-card> </mat-card>
</div> </div>
<div fxFlex.xs="100" fxFlex.sm="100" fxFlex.md="50" fxFlex.lg="50" fxFlex.xl="50" class="m-gap p-gap"> <div fxFlex.xs="100" fxFlex.sm="100" fxFlex.md="50" fxFlex.lg="50" fxFlex.xl="50" class="m-gap p-gap">
<!-- pd documents card --> <!-- pd documents card -->
<mat-expansion-panel *ngIf="pdDocumentsData.length>0; else nodocument"> <mat-expansion-panel *ngIf="pdDocumentsData.length>0; else nodocument">
@ -175,6 +168,25 @@
</ng-template> </ng-template>
</div> </div>
<div *ngIf="pdMasterData[0]?.pd_status === 'QC_COMPLETED'" class="m-gap p-gap" fxFlex.xs="100" fxFlex.sm="100" fxFlex.md="50" fxFlex.lg="50" fxFlex.xl="50">
<mat-card>
<div style="color:red !important;">
<h6>QC Remarks</h6>
</div>
<p>
{{ pdMasterData[0].qc_remarks}}</p>
<p>
{{ pdMasterData[0]?.qc_feedback}}</p>
<div>
<p>
<app-rating [rating]="pd_QC_Rating"></app-rating>
</p>
</div>
</mat-card>
</div>
</div>
</div>
</div> </div>
</mat-card-content> </mat-card-content>
</div> </div>

View File

@ -64,11 +64,14 @@ export class ViewPdComponent implements OnInit, OnDestroy {
this.viewPdDetails(this.viewID); this.viewPdDetails(this.viewID);
} }
pd_QC_Rating: Number;
viewPdDetails(editID:string){ viewPdDetails(editID:string){
this._pd.editPdDetails(editID).subscribe( this._pd.editPdDetails(editID).subscribe(
data => { data => {
if (data.status == 200) { if (data.status == 200) {
this.pdMasterData=data.records.pd_master_details; this.pdMasterData=data.records.pd_master_details;
this.pd_QC_Rating = Number(this.pdMasterData[0].qc_rating);
this.pdApplicantData= data.records.applicants_details; this.pdApplicantData= data.records.applicants_details;
this.pdDocumentsData=data.records.pd_documnets; this.pdDocumentsData=data.records.pd_documnets;
this.masterPdLogsData=data.records.pd_logs.master; this.masterPdLogsData=data.records.pd_logs.master;