This commit is contained in:
Peter Maquiran
2023-07-12 10:53:32 +01:00
7 changed files with 114 additions and 37 deletions
+3 -14
View File
@@ -10,7 +10,6 @@ import { ThemeService } from 'src/app/services/theme.service';
import { environment } from 'src/environments/environment';
import { Storage } from '@ionic/storage';
import { ChatController } from './controller/chat';
import { AngularFireMessaging } from '@angular/fire/messaging';
const CUSTOM_DATE_FORMATS: NgxMatDateFormats = {
parse: {
@@ -41,10 +40,11 @@ export class AppComponent {
private storage: Storage,
private ChatSystemService: ChatSystemService
) {
this.initializeApp();
this.storage.set('version', environment.version).then(() => {})
ChatController.ChatSystemService = this.ChatSystemService
}
/* requestPermission() {
@@ -69,24 +69,13 @@ export class AppComponent {
initializeApp() {
this.platform.ready().then(() => {
this.statusBar.styleDefault();
/* this.splashScreen.hide(); */
if (this.platform.is("tablet")) {
window.screen.orientation.unlock();
} else if( this.platform.is("mobile")) {
window.screen.orientation.lock('portrait');
}
if (this.platform.is('desktop') || this.platform.is('mobileweb')) {
} else {
try {
// this.sqliteservice.databaseConn();
} catch (error) {
}
}
});
}
}