diff --git a/ng6-seed/src/app/pd-triger/add-pd/add-pd.component.ts b/ng6-seed/src/app/pd-triger/add-pd/add-pd.component.ts index 2880b9299..1613e5c92 100644 --- a/ng6-seed/src/app/pd-triger/add-pd/add-pd.component.ts +++ b/ng6-seed/src/app/pd-triger/add-pd/add-pd.component.ts @@ -12,7 +12,7 @@ import { AwsService } from '../../AwsService/aws.service'; }) export class AddPdComponent implements OnInit { @Output() loadParent = new EventEmitter(); - public notifier: NotifierService; + private notifier: NotifierService; public _PDtriggerForm: FormGroup; items: FormArray; productList:any; @@ -31,8 +31,8 @@ export class AddPdComponent implements OnInit { subAllocationTypeCheck: boolean; allocationLabel: string; subAllocationLabel: string; - constructor(private _fb: FormBuilder, - private _pd: PdTrigerService, private _aws:AwsService, notifier: NotifierService) { + constructor(notifier: NotifierService,private _fb: FormBuilder, + private _pd: PdTrigerService, private _aws:AwsService) { this.notifier = notifier; } public totalfiles: Array =[]; @@ -290,7 +290,7 @@ export class AddPdComponent implements OnInit { this._pd.addPdDetails(pd_form).subscribe(result => { if (result.status == 200) { - this.notifier.notify('success', 'PD Saved Successfully.!'); + this.notifier.notify('success', 'PD Saved.'); this.loadPdListCompoent(); } else { diff --git a/ng6-seed/src/app/pd-triger/edit-pd-applicant/edit-pd-applicant.component.html b/ng6-seed/src/app/pd-triger/edit-pd-applicant/edit-pd-applicant.component.html index 125b81296..198e3fb58 100644 --- a/ng6-seed/src/app/pd-triger/edit-pd-applicant/edit-pd-applicant.component.html +++ b/ng6-seed/src/app/pd-triger/edit-pd-applicant/edit-pd-applicant.component.html @@ -70,4 +70,6 @@ + + \ No newline at end of file diff --git a/ng6-seed/src/app/pd-triger/edit-pd-applicant/edit-pd-applicant.component.ts b/ng6-seed/src/app/pd-triger/edit-pd-applicant/edit-pd-applicant.component.ts index b0c20d303..7d42232cf 100644 --- a/ng6-seed/src/app/pd-triger/edit-pd-applicant/edit-pd-applicant.component.ts +++ b/ng6-seed/src/app/pd-triger/edit-pd-applicant/edit-pd-applicant.component.ts @@ -105,7 +105,7 @@ export class EditPdApplicantComponent implements OnInit { this._pd.updatePdApplicant(pd_applicant_details).subscribe(result => { if (result.status == 200) { - this.notifier.notify('success', 'PD Saved Successfully.!'); + this.notifier.notify('success', 'Applicants updated..'); this.loadPdMasterCompoent(); } else { diff --git a/ng6-seed/src/app/pd-triger/edit-pd-master/edit-pd-master.component.ts b/ng6-seed/src/app/pd-triger/edit-pd-master/edit-pd-master.component.ts index fc7405eac..9ed6604ac 100644 --- a/ng6-seed/src/app/pd-triger/edit-pd-master/edit-pd-master.component.ts +++ b/ng6-seed/src/app/pd-triger/edit-pd-master/edit-pd-master.component.ts @@ -121,7 +121,7 @@ export class EditPdMasterComponent implements OnInit { } } loadPdMasterCompoent() { - this.notifier.notify('success', 'Your Changes Updated.!'); + // this.notifier.notify('success', 'Your Changes Updated.!'); this.loadPdView.emit('1') } diff --git a/ng6-seed/src/app/pd-triger/list-pd/list-pd.component.html b/ng6-seed/src/app/pd-triger/list-pd/list-pd.component.html index 814237603..60888e66e 100644 --- a/ng6-seed/src/app/pd-triger/list-pd/list-pd.component.html +++ b/ng6-seed/src/app/pd-triger/list-pd/list-pd.component.html @@ -128,3 +128,4 @@ + diff --git a/ng6-seed/src/app/pd-triger/pd-allocation/pd-allocation.component.ts b/ng6-seed/src/app/pd-triger/pd-allocation/pd-allocation.component.ts index 5bde0ee3e..ac56fdf9e 100644 --- a/ng6-seed/src/app/pd-triger/pd-allocation/pd-allocation.component.ts +++ b/ng6-seed/src/app/pd-triger/pd-allocation/pd-allocation.component.ts @@ -59,7 +59,7 @@ export class PdAllocationComponent implements OnInit { /** To update pd officer*/ updatePdOfficer(allocateDate:any) { if(this.isDisabled){ - this.notifier.notify('warning', 'Please Choose Minimum One PD Officer.!'); + this.notifier.notify('warning', 'Please Choose PD Officer.!'); } else { let updateData = { @@ -69,7 +69,7 @@ export class PdAllocationComponent implements OnInit { this._pd.updatePdOfficer(updateData).subscribe( result => { if (result.status == 200) { - // this.notifier.notify('success', 'Your Changes Updated.!'); + this.notifier.notify('success', 'PD Allocated.!'); this.dialogRef.close(); } else { diff --git a/ng6-seed/src/app/pd-triger/pd-service/pd-triger.service.ts b/ng6-seed/src/app/pd-triger/pd-service/pd-triger.service.ts index c49f7aabd..62f166ac7 100644 --- a/ng6-seed/src/app/pd-triger/pd-service/pd-triger.service.ts +++ b/ng6-seed/src/app/pd-triger/pd-service/pd-triger.service.ts @@ -20,16 +20,10 @@ export interface Master { export class PdTrigerService { -<<<<<<< HEAD - //private apiUrl = "http://ssa.sineedge.com/sparqapi/api/"; - private apiUrl = "http://192.168.0.5:9999/AWSEC2/sparqapi/api/"; -======= private apiUrl = "http://ssa.sineedge.com/sparqapi/api/"; - //private apiUrl = "http://192.168.0.17:9999/AWSEC2/sparqapi/api/"; ->>>>>>> 4133406fb5c648cd6dc4e0fd326d6301cf87939f + //private apiUrl = "http://192.168.0.5:9999/AWSEC2/sparqapi/api/"; + //private apiUrl = "http://ssa.sineedge.com/sparqtest/api/"; - - constructor(private _http: HttpClient, private _aws:AwsService) { } // get add pd master details @@ -126,7 +120,6 @@ export class PdTrigerService { ) } -<<<<<<< HEAD // get pd allocation to details getPdOfficerList(pdID:string): Observable { return this._http.post(this.apiUrl+"getListPDOfficers",{"pdid":pdID}) @@ -143,18 +136,10 @@ export class PdTrigerService { catchError(this.handleError('operation', [])) ) } - - private handleError(operation = 'operation', result?: T) { - return (error: any): Observable => { - return of(result as T); - }; - } -======= private handleError(operation = 'operation', result?: T) { return (error: any): Observable => { return of(result as T); }; } ->>>>>>> 4133406fb5c648cd6dc4e0fd326d6301cf87939f } diff --git a/ng6-seed/src/app/pd-triger/pd-triger.module.ts b/ng6-seed/src/app/pd-triger/pd-triger.module.ts index c947c0495..ce716f451 100644 --- a/ng6-seed/src/app/pd-triger/pd-triger.module.ts +++ b/ng6-seed/src/app/pd-triger/pd-triger.module.ts @@ -29,6 +29,7 @@ import { EditPdComponent } from './edit-pd/edit-pd.component'; import { ViewPdComponent } from './view-pd/view-pd.component'; import { EditPdMasterComponent } from './edit-pd-master/edit-pd-master.component'; import { EditPdApplicantComponent } from './edit-pd-applicant/edit-pd-applicant.component'; +import { PdAllocationComponent } from './pd-allocation/pd-allocation.component'; /** * Custom angular notifier options */ @@ -96,7 +97,8 @@ const pdCustomNotifierOptions: NotifierOptions = { MatDialogModule,MatSortModule, NgxMatSelectSearchModule,MatTooltipModule, ], - declarations: [AddPdComponent, ListPdComponent, EditPdComponent, ViewPdComponent, EditPdMasterComponent, EditPdApplicantComponent], + declarations: [AddPdComponent, ListPdComponent, EditPdComponent, ViewPdComponent, EditPdMasterComponent, EditPdApplicantComponent, PdAllocationComponent], + entryComponents:[PdAllocationComponent], providers: [PdTrigerService] }) export class PdTrigerModule { } diff --git a/ng6-seed/src/app/pd-triger/view-pd/view-pd.component.html b/ng6-seed/src/app/pd-triger/view-pd/view-pd.component.html index 6e01a9e6c..f5d233149 100644 --- a/ng6-seed/src/app/pd-triger/view-pd/view-pd.component.html +++ b/ng6-seed/src/app/pd-triger/view-pd/view-pd.component.html @@ -1,14 +1,11 @@ - - -
+
+ +
@@ -62,21 +59,24 @@ -
- -
+ Documents - +

+ {{documents.pd_document_title}}     + +  {{documents.pd_document_name}} +

-
@@ -87,3 +87,5 @@ + + diff --git a/ng6-seed/src/app/pd-triger/view-pd/view-pd.component.ts b/ng6-seed/src/app/pd-triger/view-pd/view-pd.component.ts index 1e348b334..f0324f37e 100644 --- a/ng6-seed/src/app/pd-triger/view-pd/view-pd.component.ts +++ b/ng6-seed/src/app/pd-triger/view-pd/view-pd.component.ts @@ -1,8 +1,9 @@ import { Component, OnInit,ViewEncapsulation, EventEmitter, Input, Output } from '@angular/core'; import { FormBuilder, FormGroup, Validators, FormControl, FormArray } from '@angular/forms'; -import { CustomValidators } from 'ng2-validation'; +import { MatDialog } from '@angular/material'; import { NotifierService } from 'angular-notifier'; import { PdTrigerService } from '../pd-service/pd-triger.service'; +import { PdAllocationComponent } from '../pd-allocation/pd-allocation.component'; @Component({ selector: 'app-view-pd', templateUrl: './view-pd.component.html', @@ -24,8 +25,8 @@ export class ViewPdComponent implements OnInit { @Input() childData: string; @Output() loadParent = new EventEmitter(); public _EditPDtriggerForm:FormGroup; - constructor(private _fb: FormBuilder, - private _pd: PdTrigerService, notifier:NotifierService) { + constructor(notifier:NotifierService,private dialog: MatDialog,private _fb: FormBuilder, + private _pd: PdTrigerService) { this.notifier=notifier } @@ -42,6 +43,7 @@ export class ViewPdComponent implements OnInit { if (data.status == 200) { this.pdMasterData=data.records.pd_master_details; this.pdApplicantData= data.records.applicants_details; + this.pdDocumentsData=data.records.pd_documnets; this.pdLogsData=data.records.pd_logs; } }, error => this.errorMessage = error); @@ -59,7 +61,6 @@ export class ViewPdComponent implements OnInit { this.editApplicantData=applicantData; this.showEditApplicantComponent=!this.showEditApplicantComponent; } -<<<<<<< HEAD // pd allocation to // edit questions master details popup model pdAllocationTo(pdID:any) { @@ -69,13 +70,11 @@ export class ViewPdComponent implements OnInit { }); dialogRef.afterClosed() .subscribe(dataresult => { - this.notifier.notify('warning', 'Something Wents Wrong Try Again.!'); - + // this.notifier.notify('success', 'Successfully allocated.!'); this.viewPdDetails(this.childData) }); } -======= ->>>>>>> 4133406fb5c648cd6dc4e0fd326d6301cf87939f + updateViewComponent(editBack:string) { if(editBack=='1'){