Fairoj: PD Report issues resolved
This commit is contained in:
parent
82ad8dbfe7
commit
807107bad5
@ -126,7 +126,7 @@ export class PdReportComponent implements OnInit {
|
|||||||
this.pdTrigerService.getPDReportFinalDocument(data).subscribe(data => {
|
this.pdTrigerService.getPDReportFinalDocument(data).subscribe(data => {
|
||||||
if (data.dataStatus) {
|
if (data.dataStatus) {
|
||||||
this.notifier.notify('success', 'Your Changes Updated.!');
|
this.notifier.notify('success', 'Your Changes Updated.!');
|
||||||
this.getPdReportVersionList();
|
// this.getPdReportVersionList();
|
||||||
} else {
|
} else {
|
||||||
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
|
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
|
||||||
}
|
}
|
||||||
@ -173,15 +173,37 @@ export class PdReportComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
getPdReportDetails() {
|
getPdReportDetails() {
|
||||||
|
//OLD FUN
|
||||||
|
// this.pdTrigerService.getPdFinalReportDetails(this.startPD).subscribe(data => {
|
||||||
|
// if (data.status == 200) {
|
||||||
|
// // this.pdReportRecords = data.records.question_answers;
|
||||||
|
// this.pdReportRecords = data.records;
|
||||||
|
// this.getPdReportVersionList()
|
||||||
|
// // this.pdReportRecords = data.records.qu;
|
||||||
|
// }
|
||||||
|
// }, err => {
|
||||||
|
|
||||||
|
// })
|
||||||
this.pdTrigerService.getPdFinalReportDetails(this.startPD).subscribe(data => {
|
this.pdTrigerService.getPdFinalReportDetails(this.startPD).subscribe(data => {
|
||||||
if (data.status == 200) {
|
if (data.status == 200) {
|
||||||
// this.pdReportRecords = data.records.question_answers;
|
// console.log('getPdReportDetails',data);
|
||||||
this.pdReportRecords = data.records;
|
this.pdReportRecords = data.records;
|
||||||
this.getPdReportVersionList()
|
this.qcStatus = data.records.pd_status;
|
||||||
// this.pdReportRecords = data.records.qu;
|
// console.log(this.qcStatus);
|
||||||
|
this.generateBtn = data.records.is_original_report_created == 1 ? false : true;
|
||||||
|
// console.log(this.generateBtn);
|
||||||
|
this.reGenerateBtn = data.records.is_original_report_created == 1 ? true : false;
|
||||||
|
// console.log(this.reGenerateBtn);
|
||||||
}
|
}
|
||||||
|
else{
|
||||||
|
this.generateBtn = true;
|
||||||
|
// console.log('else',this.generateBtn);
|
||||||
|
this.notifier.notify('warning', 'Something Went Wrong Try Again.!');
|
||||||
|
}
|
||||||
|
this.getHTMLPDReport()
|
||||||
}, err => {
|
}, err => {
|
||||||
|
this.notifier.notify('error', 'Something Went Wrong Try Again.! \t\"' + (err.error_type == 2 ? err.error_status + ' ( ' + err.error_text + ' ) ' : ' ( ' + err.error_text + ' ) ') +'\" Error Occur.!');
|
||||||
|
// alert(err.html_format);
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user