Hi
I'am trying to doevelop a desktop notification JS in odoo10 . My code work on firefox but not on Chrome
I changing the notification permission on allow but still not working.
this is my code :
notifyMe: function () {
if (!("Notification" in window)) {
alert("Ce navigateur ne supporte pas les notifications desktop");
}
else if (Notification.permission !== 'denied') {
Notification.requestPermission(function (permission) {
if(!('permission' in Notification)) {
Notification.permission = permission;
}
if (permission === "granted") {
var notification = new Notification("Notify ")
}
});
}
Can somebody help me ? Thanks