|
@@ -10,18 +10,18 @@ import { Acknowledgemeent, AcknowledgementLogSetting } from "../type/acknowledge
|
|
export class AcknowledgementService implements Acknowledgemeent {
|
|
export class AcknowledgementService implements Acknowledgemeent {
|
|
|
|
|
|
private messageUtil: FisCreateMessageUtility = new FisCreateMessageUtility("FisAppID/Name")
|
|
private messageUtil: FisCreateMessageUtility = new FisCreateMessageUtility("FisAppID/Name")
|
|
- private settings1: LogSetting = {
|
|
|
|
- storage: '',
|
|
|
|
- setting: {
|
|
|
|
- appId: '',
|
|
|
|
- appName: '',
|
|
|
|
- logLocName: '',
|
|
|
|
- logLocId: '',
|
|
|
|
- appLogLocId: '',
|
|
|
|
- appLocName: '',
|
|
|
|
- appLogId: ''
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
|
|
+ // private settings1: LogSetting = {
|
|
|
|
+ // storage: '',
|
|
|
|
+ // setting: {
|
|
|
|
+ // appId: '',
|
|
|
|
+ // appName: '',
|
|
|
|
+ // logLocName: '',
|
|
|
|
+ // logLocId: '',
|
|
|
|
+ // appLogLocId: '',
|
|
|
|
+ // appLocName: '',
|
|
|
|
+ // appLogId: ''
|
|
|
|
+ // }
|
|
|
|
+ // }
|
|
private settings2: LogSetting = {
|
|
private settings2: LogSetting = {
|
|
storage: '',
|
|
storage: '',
|
|
setting: {
|
|
setting: {
|
|
@@ -36,20 +36,20 @@ export class AcknowledgementService implements Acknowledgemeent {
|
|
}
|
|
}
|
|
|
|
|
|
constructor(private logService1?: LoggingService, private logService2?: LoggingService) {
|
|
constructor(private logService1?: LoggingService, private logService2?: LoggingService) {
|
|
- this.logService1 = new LoggingService()
|
|
|
|
|
|
+ // this.logService1 = new LoggingService()
|
|
this.logService2 = new LoggingService()
|
|
this.logService2 = new LoggingService()
|
|
}
|
|
}
|
|
|
|
|
|
// set the data. I dont know what to set yet
|
|
// set the data. I dont know what to set yet
|
|
public async init(settings: AcknowledgementLogSetting) {
|
|
public async init(settings: AcknowledgementLogSetting) {
|
|
- let logSetting1: LogSetting = {
|
|
|
|
- ...settings,
|
|
|
|
- setting: {
|
|
|
|
- ...settings.setting,
|
|
|
|
- logLocName: "locationName1",
|
|
|
|
- appLocName: "appLocName1"
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
|
|
+ // let logSetting1: LogSetting = {
|
|
|
|
+ // ...settings,
|
|
|
|
+ // setting: {
|
|
|
|
+ // ...settings.setting,
|
|
|
|
+ // logLocName: "locationName1",
|
|
|
|
+ // appLocName: "appLocName1"
|
|
|
|
+ // }
|
|
|
|
+ // }
|
|
let logSetting2: LogSetting = {
|
|
let logSetting2: LogSetting = {
|
|
...settings,
|
|
...settings,
|
|
setting: {
|
|
setting: {
|
|
@@ -59,15 +59,14 @@ export class AcknowledgementService implements Acknowledgemeent {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
// console.log(settings)
|
|
// console.log(settings)
|
|
- this.settings1 = logSetting1
|
|
|
|
- this.logService1.init(logSetting1)
|
|
|
|
|
|
+ // this.settings1 = logSetting1
|
|
|
|
+ // this.logService1.init(logSetting1)
|
|
this.settings2 = logSetting2
|
|
this.settings2 = logSetting2
|
|
this.logService2.init(logSetting2)
|
|
this.logService2.init(logSetting2)
|
|
}
|
|
}
|
|
|
|
|
|
// suppose to call logging service to give an observable type report for every message streamed
|
|
// suppose to call logging service to give an observable type report for every message streamed
|
|
public subscribe(obs: Observable<any>): Observable<ResponseMessage> {
|
|
public subscribe(obs: Observable<any>): Observable<ResponseMessage> {
|
|
- this.logService1.subscribe(obs)
|
|
|
|
let acknowledgementToken: Observable<ResponseMessage> = obs.pipe(
|
|
let acknowledgementToken: Observable<ResponseMessage> = obs.pipe(
|
|
map(
|
|
map(
|
|
incoming_msg => {
|
|
incoming_msg => {
|