Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[17.0][MIG]mail_partner_opt_out:Migration to 17.0 #1351

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
91 changes: 91 additions & 0 deletions mail_partner_opt_out/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
====================
Mail Partner Opt Out
====================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:79af277b139efcd304ae37ac88461c10ca9c59a25cd16b67ec7d05826f5d2e8e
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |badge2| image:: https://img.shields.io/badge/licence-LGPL--3-blue.png
:target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html
:alt: License: LGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fsocial-lightgray.png?logo=github
:target: https://github.com/OCA/social/tree/17.0/mail_partner_opt_out
:alt: OCA/social
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/social-17-0/social-17-0-mail_partner_opt_out
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
:target: https://runboat.odoo-community.org/builds?repo=OCA/social&target_branch=17.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

This module adds the capability for a user to add a partner's email
address to the blackmail list so that she will not receive any emails
from mass mailing campaigns

**Table of contents**

.. contents::
:local:

Usage
=====

Go to a partner. Next to the partner's email address you will see a plus
symbol. Once you press it the partner's email address will be
blacklisted and then a ban will appear. If you click that ban the email
address will be removed from the blacklist.

You can also filter for the Blacklist attribute, to see all the
partner's that their email has been added to the blacklist.

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/social/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback <https://github.com/OCA/social/issues/new?body=module:%20mail_partner_opt_out%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Do not contact contributors directly about support or help with technical issues.

Credits
=======

Authors
-------

* ForgeFlow

Contributors
------------

- ForgeFlow, S.L. (contact@forgeflow.com)

- Jordi Ballester Alomar (jordi.ballester@forgeflow.com)

Maintainers
-----------

This module is maintained by the OCA.

.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org

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/social <https://github.com/OCA/social/tree/17.0/mail_partner_opt_out>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
1 change: 1 addition & 0 deletions mail_partner_opt_out/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
15 changes: 15 additions & 0 deletions mail_partner_opt_out/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Copyright 2021 ForgeFlow S.L.
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html).
{
"name": "Mail Partner Opt Out",
"summary": "Add the partner's email to the blackmailed list",
"version": "17.0.1.0.0",
"development_status": "Beta",
"category": "Social Network",
"website": "https://github.com/OCA/social",
"author": "ForgeFlow, Odoo Community Association (OCA)",
"license": "LGPL-3",
"installable": True,
"data": ["views/res_partner_views.xml"],
"depends": ["mail"],
}
27 changes: 27 additions & 0 deletions mail_partner_opt_out/i18n/es.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * mail_partner_opt_out
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: 2024-01-10 19:33+0000\n"
"Last-Translator: Ivorra78 <informatica@totmaterial.es>\n"
"Language-Team: none\n"
"Language: es\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 4.17\n"

#. module: mail_partner_opt_out
#: model_terms:ir.ui.view,arch_db:mail_partner_opt_out.res_partner_view_form_inherit_mail
msgid "Click to add this email to the blacklist."
msgstr "Haga clic para añadir este correo electrónico a la lista negra."

#. module: mail_partner_opt_out
#: model:ir.model,name:mail_partner_opt_out.model_mail_thread_blacklist
msgid "Mail Blacklist mixin"
msgstr "Mezcla de Lista Negra de Correo"
27 changes: 27 additions & 0 deletions mail_partner_opt_out/i18n/it.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * mail_partner_opt_out
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: 2023-12-01 10:12+0000\n"
"Last-Translator: mymage <stefano.consolaro@mymage.it>\n"
"Language-Team: none\n"
"Language: it\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 4.17\n"

#. module: mail_partner_opt_out
#: model_terms:ir.ui.view,arch_db:mail_partner_opt_out.res_partner_view_form_inherit_mail
msgid "Click to add this email to the blacklist."
msgstr "Fare clic per aggiungere questa e-mail alla blacklist."

#. module: mail_partner_opt_out
#: model:ir.model,name:mail_partner_opt_out.model_mail_thread_blacklist
msgid "Mail Blacklist mixin"
msgstr "Mixin blacklist e-mail"
24 changes: 24 additions & 0 deletions mail_partner_opt_out/i18n/mail_partner_opt_out.pot
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * mail_partner_opt_out
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"

#. module: mail_partner_opt_out
#: model_terms:ir.ui.view,arch_db:mail_partner_opt_out.res_partner_view_form_inherit_mail
msgid "Click to add this email to the blacklist."
msgstr ""

#. module: mail_partner_opt_out
#: model:ir.model,name:mail_partner_opt_out.model_mail_thread_blacklist
msgid "Mail Blacklist mixin"
msgstr ""
1 change: 1 addition & 0 deletions mail_partner_opt_out/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import mail_thread_blacklist
10 changes: 10 additions & 0 deletions mail_partner_opt_out/models/mail_thread_blacklist.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
from odoo import models


class MailBlackListMixin(models.AbstractModel):
_inherit = "mail.thread.blacklist"

def mail_blacklist_add(self):
for mail_thread_blacklist in self:
if not mail_thread_blacklist.is_blacklisted and mail_thread_blacklist.email:
self.env["mail.blacklist"].sudo()._add(mail_thread_blacklist.email)
3 changes: 3 additions & 0 deletions mail_partner_opt_out/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[build-system]
requires = ["whool"]
build-backend = "whool.buildapi"
3 changes: 3 additions & 0 deletions mail_partner_opt_out/readme/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
- ForgeFlow, S.L. (<contact@forgeflow.com>)

> - Jordi Ballester Alomar (<jordi.ballester@forgeflow.com>)
3 changes: 3 additions & 0 deletions mail_partner_opt_out/readme/DESCRIPTION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
This module adds the capability for a user to add a partner's email
address to the blackmail list so that she will not receive any emails
from mass mailing campaigns
7 changes: 7 additions & 0 deletions mail_partner_opt_out/readme/USAGE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Go to a partner. Next to the partner's email address you will see a plus
symbol. Once you press it the partner's email address will be
blacklisted and then a ban will appear. If you click that ban the email
address will be removed from the blacklist.

You can also filter for the Blacklist attribute, to see all the
partner's that their email has been added to the blacklist.
Binary file added mail_partner_opt_out/static/description/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading