From 3751379f1e9a4c215fb6eb898b4ccc67659b9ace Mon Sep 17 00:00:00 2001 From: stephanchrst Date: Tue, 10 May 2022 21:51:50 +0700 Subject: initial commit 2 --- .../notification_group/notification_group.js | 27 ++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 addons/sms/static/src/components/notification_group/notification_group.js (limited to 'addons/sms/static/src/components/notification_group/notification_group.js') diff --git a/addons/sms/static/src/components/notification_group/notification_group.js b/addons/sms/static/src/components/notification_group/notification_group.js new file mode 100644 index 00000000..053fedc5 --- /dev/null +++ b/addons/sms/static/src/components/notification_group/notification_group.js @@ -0,0 +1,27 @@ +odoo.define('sms/static/src/components/notification_group/notification_group.js', function (require) { +'use strict'; + +const components = { + NotificationGroup: require('mail/static/src/components/notification_group/notification_group.js'), +}; + +const { patch } = require('web.utils'); + +patch(components.NotificationGroup, 'sms/static/src/components/notification_group/notification_group.js', { + + //-------------------------------------------------------------------------- + // Public + //-------------------------------------------------------------------------- + + /** + * @override + */ + image() { + if (this.group.notification_type === 'sms') { + return '/sms/static/img/sms_failure.svg'; + } + return this._super(...arguments); + }, +}); + +}); -- cgit v1.2.3