From 6f9702f3db401ff0e659113deb1672b9a17b172f Mon Sep 17 00:00:00 2001 From: Richard Park Date: Mon, 23 Dec 2019 16:37:44 +0900 Subject: [PATCH] message notification is modified --- .../src/app/services/native.service.ts | 7 +++++-- .../src/app/services/notification.service.ts | 5 +++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/projects/ucap-webmessenger-app/src/app/services/native.service.ts b/projects/ucap-webmessenger-app/src/app/services/native.service.ts index 41eb4c89..f10c25e1 100644 --- a/projects/ucap-webmessenger-app/src/app/services/native.service.ts +++ b/projects/ucap-webmessenger-app/src/app/services/native.service.ts @@ -1,4 +1,4 @@ -import { Injectable, Inject } from '@angular/core'; +import { Injectable, Inject, NgZone } from '@angular/core'; import { DOCUMENT } from '@angular/common'; import { UCAP_NATIVE_SERVICE, @@ -30,6 +30,7 @@ export class AppNativeService { private publicApiService: PublicApiService, private sessionStorageService: SessionStorageService, @Inject(DOCUMENT) private document: Document, + private ngZone: NgZone, private store: Store, private logger: NGXLogger ) {} @@ -40,7 +41,9 @@ export class AppNativeService { }); this.nativeService.changeStatus().subscribe(statusCode => {}); this.nativeService.showSetting().subscribe(() => { - this.store.dispatch(SettingsStore.showDialog()); + this.ngZone.run(() => { + this.store.dispatch(SettingsStore.showDialog()); + }); }); } diff --git a/projects/ucap-webmessenger-app/src/app/services/notification.service.ts b/projects/ucap-webmessenger-app/src/app/services/notification.service.ts index 7553bc51..a92251d3 100644 --- a/projects/ucap-webmessenger-app/src/app/services/notification.service.ts +++ b/projects/ucap-webmessenger-app/src/app/services/notification.service.ts @@ -190,7 +190,8 @@ export class AppNotificationService { ? true : false, displayTime: - appUserInfo.settings.notification.alertExposureTime + appUserInfo.settings.notification.alertExposureTime * + 1000 }; this.nativeService.notify(notiReq); } @@ -540,7 +541,7 @@ export class AppNotificationService { ? true : false, displayTime: - appUserInfo.settings.notification.alertExposureTime + appUserInfo.settings.notification.alertExposureTime * 1000 }; this.nativeService.notify(notiReq); }