diff options
author | 2020-07-07 19:24:27 +0530 | |
---|---|---|
committer | 2020-07-07 14:22:26 +0000 | |
commit | 0964afff41ff186eb0bb2bd679a34513e90d1015 (patch) | |
tree | 0d7cc194bac01540da23a5983e87a99a9162b4aa /portal-FE-common/src/app/shared | |
parent | dc35cacae0c16b16985effa1459cf96d646811ff (diff) |
Audit log,resolved merge conflict
Audit log code merge conflict resolved
Issue-ID: PORTAL-941
Change-Id: I1dbe87cee9b471aa0b7319bd8a568826de927c8b
Signed-off-by: jz385p <jegadeesh.babu@att.com>
Diffstat (limited to 'portal-FE-common/src/app/shared')
-rw-r--r-- | portal-FE-common/src/app/shared/services/auditLog/audit-log.service.spec.ts | 13 | ||||
-rw-r--r-- | portal-FE-common/src/app/shared/services/auditLog/audit-log.service.ts | 23 |
2 files changed, 36 insertions, 0 deletions
diff --git a/portal-FE-common/src/app/shared/services/auditLog/audit-log.service.spec.ts b/portal-FE-common/src/app/shared/services/auditLog/audit-log.service.spec.ts new file mode 100644 index 00000000..1295915d --- /dev/null +++ b/portal-FE-common/src/app/shared/services/auditLog/audit-log.service.spec.ts @@ -0,0 +1,13 @@ +import { TestBed } from '@angular/core/testing'; + +import { AuditLogService } from './audit-log.service'; +import { HttpClientTestingModule} from '@angular/common/http/testing'; + +describe('AuditLogService', () => { + beforeEach(() => TestBed.configureTestingModule({imports: [HttpClientTestingModule]})); + + it('should be created', () => { + const service: AuditLogService = TestBed.get(AuditLogService); + expect(service).toBeTruthy(); + }); +}); diff --git a/portal-FE-common/src/app/shared/services/auditLog/audit-log.service.ts b/portal-FE-common/src/app/shared/services/auditLog/audit-log.service.ts new file mode 100644 index 00000000..0504fb9f --- /dev/null +++ b/portal-FE-common/src/app/shared/services/auditLog/audit-log.service.ts @@ -0,0 +1,23 @@ +import { Injectable } from '@angular/core'; +import { Observable } from 'rxjs'; +import { environment } from 'src/environments/environment'; +import { HttpClient, HttpHeaders, HttpParams } from '@angular/common/http'; + +@Injectable({ + providedIn: 'root' +}) +export class AuditLogService { + + constructor(private api: HttpClient) { } + + storeAudit(affectedAppId:any,type:any,comment:any): Observable<any> { + var url = environment.api.storeAuditLog+'?affectedAppId=' + affectedAppId; + if(type!=''){ + url= url+'&type='+type; + } + if(comment!=''){ + url= url+'&comment='+comment; + } + return this.api.get(url); + } +} |