Push v2
Push geht jetzt auch wenn das Tab von SmartShopper nicht im Vordergrund ist
This commit is contained in:
parent
f9f7e656a7
commit
faf16fb1c3
@ -17,9 +17,11 @@ const messaging = firebase.messaging();
|
|||||||
|
|
||||||
|
|
||||||
messaging.setBackgroundMessageHandler(payload => {
|
messaging.setBackgroundMessageHandler(payload => {
|
||||||
|
// const title = payload.data.title
|
||||||
|
// const options = {
|
||||||
|
// body: payload.data.text
|
||||||
|
// }
|
||||||
|
// return self.registration.showNotification(title, options)
|
||||||
const title = payload.data.title
|
const title = payload.data.title
|
||||||
const options = {
|
new Notification(title, { body: payload.data.text});
|
||||||
body: payload.data.text
|
|
||||||
}
|
|
||||||
return self.registration.showNotification(title, options)
|
|
||||||
})
|
})
|
Loading…
x
Reference in New Issue
Block a user