diff --git a/web_notify/README.rst b/web_notify/README.rst index 3e9441b0c..e0e875fb3 100644 --- a/web_notify/README.rst +++ b/web_notify/README.rst @@ -14,13 +14,13 @@ Web Notify :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fweb-lightgray.png?logo=github - :target: https://github.com/OCA/web/tree/14.0/web_notify + :target: https://github.com/OCA/web/tree/15.0/web_notify :alt: OCA/web .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/web-14-0/web-14-0-web_notify + :target: https://translation.odoo-community.org/projects/web-15-0/web-15-0-web_notify :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/162/14.0 + :target: https://runbot.odoo-community.org/runbot/162/15.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -50,7 +50,7 @@ Usage ===== -To send a notification to the logged in user or target audience you just need to call one of the new methods defined on res.users: +To send a notification to the user you just need to call one of the new methods defined on res.users: .. code-block:: python @@ -80,14 +80,14 @@ or self.env.user.notify_default(message='My default message') -.. figure:: https://raw.githubusercontent.com/OCA/web/14.0/web_notify/static/description/notifications_screenshot.png +.. figure:: https://raw.githubusercontent.com/OCA/web/15.0/web_notify/static/description/notifications_screenshot.gif :scale: 80 % :alt: Sample notifications You can test the behaviour of the notifications by installing this module in a demo database. -Access the users form through Settings -> Users & Companies. You'll see a tab called "Test web notify", here you'll find five buttons that'll allow you test the module. +Access the users form through Settings -> Users & Companies. You'll see a tab called "Test web notify", here you'll find two buttons that'll allow you test the module. -.. figure:: https://raw.githubusercontent.com/OCA/web/14.0/web_notify/static/description/test_notifications_demo.png +.. figure:: https://raw.githubusercontent.com/OCA/web/15.0/web_notify/static/description/test_notifications_demo.png :scale: 80 % :alt: Sample notifications @@ -97,7 +97,7 @@ Bug Tracker Bugs are tracked on `GitHub Issues `_. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us smashing it by providing a detailed and welcomed -`feedback `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -118,6 +118,9 @@ Contributors * Aitor Bouzas * Shepilov Vladislav * Kevin Khao +* `Tecnativa `_: + + * David Vidal Maintainers ~~~~~~~~~~~ @@ -132,6 +135,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use. -This module is part of the `OCA/web `_ project on GitHub. +This module is part of the `OCA/web `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/web_notify/__manifest__.py b/web_notify/__manifest__.py index 1cdd47143..87b21d879 100644 --- a/web_notify/__manifest__.py +++ b/web_notify/__manifest__.py @@ -14,8 +14,7 @@ "depends": ["web", "bus", "base", "mail"], "assets": { "web.assets_backend": [ - "web_notify/static/src/js/services/notification.js", - "web_notify/static/src/js/services/notification_services.js", + "web_notify/static/src/js/services/*.js", ] }, "demo": ["views/res_users_demo.xml"], diff --git a/web_notify/models/__init__.py b/web_notify/models/__init__.py index 15deefdab..883516533 100644 --- a/web_notify/models/__init__.py +++ b/web_notify/models/__init__.py @@ -1,4 +1 @@ -# pylint: disable=missing-docstring -# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). - from . import res_users diff --git a/web_notify/models/res_users.py b/web_notify/models/res_users.py index 9b1bbddec..1cb7b5d66 100644 --- a/web_notify/models/res_users.py +++ b/web_notify/models/res_users.py @@ -1,8 +1,5 @@ -# pylint: disable=missing-docstring # Copyright 2016 ACSONE SA/NV # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). - - from odoo import _, api, exceptions, fields, models from odoo.addons.bus.models.bus import channel_with_db, json_dump @@ -82,7 +79,6 @@ class ResUsers(models.Model): sticky=False, target=None, ): - # pylint: disable=protected-access if not self.env.user._is_admin() and any( user.id != self.env.uid for user in self ): diff --git a/web_notify/readme/CONTRIBUTORS.rst b/web_notify/readme/CONTRIBUTORS.rst index 7a21d193f..77bb03c5e 100644 --- a/web_notify/readme/CONTRIBUTORS.rst +++ b/web_notify/readme/CONTRIBUTORS.rst @@ -3,3 +3,6 @@ * Aitor Bouzas * Shepilov Vladislav * Kevin Khao +* `Tecnativa `_: + + * David Vidal diff --git a/web_notify/readme/USAGE.rst b/web_notify/readme/USAGE.rst index e25ef76ec..f31a5341f 100644 --- a/web_notify/readme/USAGE.rst +++ b/web_notify/readme/USAGE.rst @@ -29,7 +29,7 @@ or self.env.user.notify_default(message='My default message') -.. figure:: static/description/notifications_screenshot.png +.. figure:: static/description/notifications_screenshot.gif :scale: 80 % :alt: Sample notifications diff --git a/web_notify/static/description/icon.png b/web_notify/static/description/icon.png index 3a0328b51..3e7d0bd7e 100644 Binary files a/web_notify/static/description/icon.png and b/web_notify/static/description/icon.png differ diff --git a/web_notify/static/description/index.html b/web_notify/static/description/index.html index d80b3c550..2add67c8a 100644 --- a/web_notify/static/description/index.html +++ b/web_notify/static/description/index.html @@ -3,7 +3,7 @@ - + Web Notify