[FIX] mail: adapt mail notification

Before this commit, some notifications in mail were not following the
changes made in odoo/odoo#52826 .

task-2278579

closes odoo/odoo#63741

X-original-commit: eabab5f20fe3ba79b3117b83af5c62453edc84a4
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit is contained in:
Thanh Dodeur
2020-12-23 13:03:40 +00:00
committed by Alexandre Kühn
parent 86df36aefa
commit 418934c476
2 changed files with 0 additions and 5 deletions
@@ -418,12 +418,10 @@ function factory(dependencies) {
} else if (type === 'moderator') {
return this._handleNotificationPartnerModerator(data);
} else if (type === 'simple_notification') {
const escapedTitle = owl.utils.escape(data.title);
const escapedMessage = owl.utils.escape(data.message);
this.env.services['notification'].notify({
message: escapedMessage,
sticky: data.sticky,
title: escapedTitle,
type: data.warning ? 'warning' : 'danger',
});
} else if (type === 'toggle_star') {
@@ -491,7 +489,6 @@ function factory(dependencies) {
this.env._t("You have been invited to: %s"),
owl.utils.escape(channel.name)
),
title: this.env._t("Invitation"),
type: 'info',
});
}
@@ -690,7 +687,6 @@ function factory(dependencies) {
channel.update({ isServerPinned: false });
this.env.services['notification'].notify({
message,
title: this.env._t("Unsubscribed"),
type: 'info',
});
}
@@ -114,7 +114,6 @@ const PartnerInviteDialog = Dialog.extend({
);
this.env.services['notification'].notify({
message: notification,
title: this.env._t("New people"),
type: 'info',
});
},