diff --git a/src/app/app.component.ts b/src/app/app.component.ts index 84666d8eec3f9233828b2e219f3330a35f6a754d..de541dcec4af5e0fabd97d5fa0dc96a33baef170 100644 --- a/src/app/app.component.ts +++ b/src/app/app.component.ts @@ -35,6 +35,7 @@ import * as XLSX from "xlsx"; import * as pako from "pako"; import { DialogConfirmComponent } from "./components/dialog-confirm/dialog-confirm.component"; import { UserConfirmationService } from "./services/user-confirmation.service"; +import { ServiceWorkerUpdateService } from "./services/service-worker-update.service"; @Component({ selector: "nghyd-app", @@ -87,6 +88,7 @@ export class AppComponent implements OnInit, OnDestroy, Observer { private hotkeysService: HotkeysService, private matomoTracker: MatomoTracker, private confirmDialog: MatDialog, + private serviceWorkerUpdateService: ServiceWorkerUpdateService, private userConfirmationService: UserConfirmationService ) { ServiceFactory.httpService = httpService; @@ -94,6 +96,7 @@ export class AppComponent implements OnInit, OnDestroy, Observer { ServiceFactory.i18nService = intlService; ServiceFactory.formulaireService = formulaireService; ServiceFactory.notificationsService = notificationsService; + ServiceFactory.serviceWorkerUpdateService = serviceWorkerUpdateService; if (!isDevMode()) { // évite de mettre en place un bandeau RGPD diff --git a/src/app/services/service-factory.ts b/src/app/services/service-factory.ts index e3ea55cae3c7ce504924688dac8ae1517f3268ba..668d5aea18b12ed1295f44b2885fdec97a1eeb56 100644 --- a/src/app/services/service-factory.ts +++ b/src/app/services/service-factory.ts @@ -4,6 +4,7 @@ import { I18nService } from "./internationalisation.service"; import { HttpService } from "./http.service"; import { NotificationsService } from "./notifications.service"; import { PrebarrageService } from "./prebarrage.service"; +import { ServiceWorkerUpdateService } from "./service-worker-update.service"; /** * A "Singleton" the TS way, that holds pointers to all services, to be accessed @@ -17,11 +18,13 @@ export const ServiceFactory: { httpService: HttpService; notificationsService: NotificationsService; prebarrageService: PrebarrageService; + serviceWorkerUpdateService: ServiceWorkerUpdateService; } = { applicationSetupService: undefined, formulaireService: undefined, i18nService: undefined, httpService: undefined, notificationsService: undefined, - prebarrageService: undefined + prebarrageService: undefined, + serviceWorkerUpdateService: undefined };