mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
feature/gabinete-search
This commit is contained in:
@@ -119,9 +119,9 @@ export class NotificationsService {
|
||||
|
||||
this.http.post<Tokenn>(`${geturl}`, body, { headers }).subscribe(data => {
|
||||
this.active = true
|
||||
console.log(data)
|
||||
|
||||
}, (error) => {
|
||||
console.log(error)
|
||||
|
||||
})
|
||||
}
|
||||
);
|
||||
@@ -146,13 +146,11 @@ export class NotificationsService {
|
||||
return false
|
||||
}
|
||||
|
||||
console.log('foregrund');
|
||||
|
||||
PushNotifications.addListener('pushNotificationReceived',
|
||||
(notification: PushNotificationSchema) => {
|
||||
this.active = true
|
||||
console.log(notification)
|
||||
//this.DataArray.push(notification)
|
||||
//console.log(this.DataArray)
|
||||
|
||||
|
||||
this.storageService.get("Notifications").then((store) => {
|
||||
store.push(notification)
|
||||
@@ -177,11 +175,9 @@ export class NotificationsService {
|
||||
return false
|
||||
}
|
||||
|
||||
console.log('fbackgrund');
|
||||
PushNotifications.addListener('pushNotificationActionPerformed',
|
||||
(notification: ActionPerformed) => {
|
||||
this.active = true
|
||||
console.log(notification)
|
||||
/* this.DataArray.push(notification.notification)
|
||||
|
||||
this.storageService.store("Notifications", this.DataArray)
|
||||
@@ -203,12 +199,10 @@ export class NotificationsService {
|
||||
"IdObject": roomId
|
||||
}
|
||||
let id = 437
|
||||
console.log(userID, title, bodymsg, roomId)
|
||||
this.http.post<Tokenn>(geturl + `?username=${userID}&title=${title}&body=${bodymsg}`, message, { headers }).subscribe(data => {
|
||||
this.active = true
|
||||
console.log(data)
|
||||
}, (error) => {
|
||||
console.log(error)
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
@@ -223,12 +217,11 @@ export class NotificationsService {
|
||||
"IdObject": roomId
|
||||
}
|
||||
}
|
||||
console.log(usersID, title, bodymsg, roomId)
|
||||
|
||||
this.http.post<Tokenn>(geturl + `?title=${title}&body=${bodymsg}`, message, { headers }).subscribe(data => {
|
||||
this.active = true
|
||||
console.log(data)
|
||||
}, (error) => {
|
||||
console.log(error)
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user