[MIG] mass_mailing_event_registration_exclude: Migration to 16.0

pull/1225/head
Carolina Fernandez 2023-10-09 08:10:29 -03:00
parent ebfbbf8f49
commit ca23e2ac26
6 changed files with 10 additions and 7 deletions

View File

@ -1,11 +1,12 @@
# Copyright 2016 Tecnativa - Antonio Espinosa
# Copyright 2017 Tecnativa - David Vidal
# Copyright 2023 Tecnativa - Carolina Fernandez
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
{
"name": "Mass mailing event",
"summary": "Link mass mailing with event for excluding recipients",
"version": "15.0.1.0.0",
"version": "16.0.1.0.0",
"category": "Marketing",
"website": "https://github.com/OCA/social",
"author": "Tecnativa, Odoo Community Association (OCA)",

View File

@ -10,8 +10,8 @@ class EventRegistration(models.Model):
_inherit = "event.registration"
@api.model
def search_count(self, domain):
res = super().search_count(domain)
def search_count(self, domain, limit=None):
res = super().search_count(domain, limit)
mass_mailing_id = self.env.context.get("exclude_mass_mailing", False)
if mass_mailing_id:
res_ids = event_filtered_ids(self, mass_mailing_id, domain, field="email")

View File

@ -11,8 +11,8 @@ class MassMailingContact(models.Model):
_inherit = "mailing.contact"
@api.model
def search_count(self, domain):
res = super().search_count(domain)
def search_count(self, domain, limit=None):
res = super().search_count(domain, limit)
mass_mailing_id = self.env.context.get("exclude_mass_mailing", False)
if mass_mailing_id:
res_ids = event_filtered_ids(self, mass_mailing_id, domain, field="email")

View File

@ -10,8 +10,8 @@ class ResPartner(models.Model):
_inherit = "res.partner"
@api.model
def search_count(self, domain):
res = super().search_count(domain)
def search_count(self, domain, limit=None):
res = super().search_count(domain, limit)
mass_mailing_id = self.env.context.get("exclude_mass_mailing", False)
if mass_mailing_id:
res_ids = event_filtered_ids(self, mass_mailing_id, domain, field="email")

View File

@ -4,3 +4,4 @@
* David Vidal
* Alexandre D. Díaz
* Stefan Ungureanu
* Carolina Fernandez

View File

@ -428,6 +428,7 @@ If you spotted it first, help us to smash it by providing a detailed and welcome
<li>David Vidal</li>
<li>Alexandre D. Díaz</li>
<li>Stefan Ungureanu</li>
<li>Carolina Fernandez</li>
</ul>
</blockquote>
</li>