diff --git a/.docker_files/main/__manifest__.py b/.docker_files/main/__manifest__.py index 50260879..cd924511 100644 --- a/.docker_files/main/__manifest__.py +++ b/.docker_files/main/__manifest__.py @@ -17,6 +17,7 @@ "ir_attachment_access_token_portal", "lang_fr_activated", "mail_notification_no_action_button", + "mail_bot_no_pong", "mail_template_default", ], "installable": True, diff --git a/Dockerfile b/Dockerfile index 700c836a..d5979bd9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -18,6 +18,7 @@ COPY base_external_report_layout /mnt/extra-addons/base_external_report_layout COPY ir_attachment_access_token_portal /mnt/extra-addons/ir_attachment_access_token_portal COPY lang_fr_activated /mnt/extra-addons/lang_fr_activated COPY mail_notification_no_action_button /mnt/extra-addons/mail_notification_no_action_button +COPY mail_bot_no_pong /mnt/extra-addons/mail_bot_no_pong COPY mail_template_default /mnt/extra-addons/mail_template_default COPY .docker_files/main /mnt/extra-addons/main diff --git a/mail_notification_no_action_button/README.rst b/mail_notification_no_action_button/README.rst deleted file mode 100644 index 5410206a..00000000 --- a/mail_notification_no_action_button/README.rst +++ /dev/null @@ -1,19 +0,0 @@ -Mail Notification No Action Button -================================== -This module removes action buttons from internal notifications. - -Before ------- -.. image:: static/description/before.png - -After ------ -.. image:: static/description/after.png - -Contributors ------------- -* Numigi (tm) and all its contributors (https://bit.ly/numigiens) - -More information ----------------- -* Meet us at https://bit.ly/numigi-com diff --git a/mail_notification_no_action_button/__init__.py b/mail_notification_no_action_button/__init__.py deleted file mode 100644 index 63bd6ae3..00000000 --- a/mail_notification_no_action_button/__init__.py +++ /dev/null @@ -1,4 +0,0 @@ -# Copyright 2024-today Numigi and all its contributors (https://bit.ly/numigiens) -# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). - -from . import models diff --git a/mail_notification_no_action_button/__manifest__.py b/mail_notification_no_action_button/__manifest__.py deleted file mode 100644 index ed0121b9..00000000 --- a/mail_notification_no_action_button/__manifest__.py +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright 2024-today Numigi and all its contributors (https://bit.ly/numigiens) -# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). - -{ - 'name': 'Mail Notification No Action Button', - 'version': '16.0.1.0.0', - 'author': 'Numigi', - 'maintainer': 'Numigi', - 'license': 'LGPL-3', - 'category': 'Discuss', - 'summary': 'Remove action buttons from notifications', - 'depends': [ - 'mail', - 'crm' - ], - 'installable': True, -} diff --git a/mail_notification_no_action_button/models/__init__.py b/mail_notification_no_action_button/models/__init__.py deleted file mode 100644 index 6ddcf0b5..00000000 --- a/mail_notification_no_action_button/models/__init__.py +++ /dev/null @@ -1,4 +0,0 @@ -# Copyright 2024-today Numigi and all its contributors (https://bit.ly/numigiens) -# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). - -from . import mail_thread diff --git a/mail_notification_no_action_button/models/mail_thread.py b/mail_notification_no_action_button/models/mail_thread.py deleted file mode 100644 index 1a7b84ff..00000000 --- a/mail_notification_no_action_button/models/mail_thread.py +++ /dev/null @@ -1,15 +0,0 @@ -# Copyright 2024-today Numigi and all its contributors (https://bit.ly/numigiens) -# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). - -from odoo import models - - -class MailThread(models.AbstractModel): - - _inherit = 'mail.thread' - - def _notify_get_recipients_classify(self, *args, **kwargs): - res = super()._notify_get_recipients_classify(*args, **kwargs) - for data in res: - data['actions'] = [] - return res diff --git a/mail_notification_no_action_button/static/description/after.png b/mail_notification_no_action_button/static/description/after.png deleted file mode 100644 index d714cf28..00000000 Binary files a/mail_notification_no_action_button/static/description/after.png and /dev/null differ diff --git a/mail_notification_no_action_button/static/description/before.png b/mail_notification_no_action_button/static/description/before.png deleted file mode 100644 index 3092682c..00000000 Binary files a/mail_notification_no_action_button/static/description/before.png and /dev/null differ diff --git a/mail_notification_no_action_button/static/description/icon.png b/mail_notification_no_action_button/static/description/icon.png deleted file mode 100644 index 92a86b10..00000000 Binary files a/mail_notification_no_action_button/static/description/icon.png and /dev/null differ diff --git a/mail_notification_no_action_button/tests/__init__.py b/mail_notification_no_action_button/tests/__init__.py deleted file mode 100644 index 9d0ad107..00000000 --- a/mail_notification_no_action_button/tests/__init__.py +++ /dev/null @@ -1,4 +0,0 @@ -# Copyright 2024-today Numigi and all its contributors (https://bit.ly/numigiens) -# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). - -from . import test_crm_lead diff --git a/mail_notification_no_action_button/tests/test_crm_lead.py b/mail_notification_no_action_button/tests/test_crm_lead.py deleted file mode 100644 index 4395ce4e..00000000 --- a/mail_notification_no_action_button/tests/test_crm_lead.py +++ /dev/null @@ -1,40 +0,0 @@ -# Copyright 2024-today Numigi and all its contributors (https://bit.ly/numigiens) -# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). - -from ddt import ddt, data -from odoo.tests import SavepointCase - - -@ddt -class TestCRMLead(SavepointCase): - @classmethod - def setUpClass(cls): - super().setUpClass() - cls.user = cls.env["res.users"].create( - { - "name": "test@example.com", - "email": "test@example.com", - "login": "test@example.com", - } - ) - cls.partner = cls.user.partner_id - cls.lead = cls.env["crm.lead"].create({"name": "M Lead"}) - cls.subtype = cls.env.ref("mail.mt_comment") - cls.lead.message_subscribe([cls.partner.id], subtype_ids=[cls.subtype.id]) - - def send_notification_email(self): - message = self.lead.message_post( - body="Test", - mail_auto_delete=False, - send_after_commit=False, - force_send=True, - subtype_id=self.subtype.id - ) - return self.env["mail.mail"].search( - [("mail_message_id", "=", message.id)], limit=1 - ) - - @data("Won", "Lost", "Sales Team Settings") - def test_action_buttons_removed(self, button_label): - email = self.send_notification_email() - assert button_label not in email.body_html