|
|
@@ -25,6 +25,7 @@ import { NotificationService } from 'angularlib/notification/notification.servic
|
|
|
import { env } from 'angularlib/environments/environment';
|
|
|
import { TranslatePipe } from 'angularlib/labels/translate.pipe';
|
|
|
import { ChatComponent } from 'angularlib/chat/chat.component';
|
|
|
+import * as confing from '../config/config.json';
|
|
|
|
|
|
@Component({
|
|
|
selector: 'app-root',
|
|
|
@@ -109,6 +110,16 @@ export class AppComponent extends BaseComponent implements OnInit {
|
|
|
}
|
|
|
|
|
|
ngOnInit(): void {
|
|
|
+ // check if site is under maintenance
|
|
|
+ if (config?.maintenance?.active) {
|
|
|
+ this.cs.dialog.showWarningDialog({
|
|
|
+ title: 'Site Under Maintenance',
|
|
|
+ content: `FIS is currently under maintenance.<br/>This maintenance is expected to continue until ${config?.maintenance?.endDatetime}.<br/>Sorry for any inconvenience caused.`,
|
|
|
+ disableClose: true,
|
|
|
+ hideCloseButton: true
|
|
|
+ });
|
|
|
+ }
|
|
|
+
|
|
|
this.router.events.pipe(untilDestroy(this),
|
|
|
filter((event) => event instanceof RoutesRecognized),
|
|
|
map((res:any) => {
|