mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 21:06:06 +00:00
merge
This commit is contained in:
@@ -10,6 +10,7 @@ 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: {
|
||||
@@ -46,6 +47,25 @@ export class AppComponent {
|
||||
ChatController.ChatSystemService = this.ChatSystemService
|
||||
}
|
||||
|
||||
/* requestPermission() {
|
||||
this.afMessaging.requestToken.subscribe(
|
||||
(token) => {
|
||||
// Save the token to your server for sending notifications
|
||||
console.log('Permission granted! Token:', token);
|
||||
},
|
||||
(error) => {
|
||||
console.error('Permission denied:', error);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
receiveMessages() {
|
||||
this.afMessaging.messages.subscribe((message) => {
|
||||
console.log('Received message:', message);
|
||||
// Handle the received message, e.g., show a notification
|
||||
});
|
||||
} */
|
||||
|
||||
initializeApp() {
|
||||
this.platform.ready().then(() => {
|
||||
this.statusBar.styleDefault();
|
||||
|
||||
Reference in New Issue
Block a user