fix: add client notes (#2331)
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
/** Angular Imports */
|
/** Angular Imports */
|
||||||
import { Component } from '@angular/core';
|
import { Component, OnInit } from '@angular/core';
|
||||||
import { ActivatedRoute } from '@angular/router';
|
import { ActivatedRoute } from '@angular/router';
|
||||||
|
|
||||||
/** Custom Components */
|
/** Custom Components */
|
||||||
@@ -16,7 +16,7 @@ import { AuthenticationService } from 'app/core/authentication/authentication.se
|
|||||||
templateUrl: './notes-tab.component.html',
|
templateUrl: './notes-tab.component.html',
|
||||||
styleUrls: ['./notes-tab.component.scss']
|
styleUrls: ['./notes-tab.component.scss']
|
||||||
})
|
})
|
||||||
export class NotesTabComponent {
|
export class NotesTabComponent implements OnInit {
|
||||||
/** Client ID */
|
/** Client ID */
|
||||||
entityId: string;
|
entityId: string;
|
||||||
/** Username */
|
/** Username */
|
||||||
@@ -34,9 +34,13 @@ export class NotesTabComponent {
|
|||||||
private clientsService: ClientsService,
|
private clientsService: ClientsService,
|
||||||
private authenticationService: AuthenticationService
|
private authenticationService: AuthenticationService
|
||||||
) {
|
) {
|
||||||
|
this.entityId = this.route.parent.snapshot.params['clientId'];
|
||||||
|
this.addNote = this.addNote.bind(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
ngOnInit(): void {
|
||||||
const credentials = this.authenticationService.getCredentials();
|
const credentials = this.authenticationService.getCredentials();
|
||||||
this.username = credentials.username;
|
this.username = credentials.username;
|
||||||
this.entityId = this.route.parent.snapshot.params['clientId'];
|
|
||||||
this.route.data.subscribe((data: { clientNotes: any }) => {
|
this.route.data.subscribe((data: { clientNotes: any }) => {
|
||||||
this.entityNotes = data.clientNotes;
|
this.entityNotes = data.clientNotes;
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user