[FIX] mail: consider more than last 1000 activities
Because activities_to_check was assigned in each loop, the result was only containing the last chunk of 1000 records, instead of the whole result. This commit fixes the issue by concatenating into the list instead of just assigning it. X-original-commit: c06c96655b88cc4df59b8cdd5f05a2f600255c49 Part-of: odoo/odoo#79969
This commit is contained in:
@@ -357,7 +357,7 @@ class MailActivity(models.Model):
|
||||
SELECT DISTINCT activity.id, activity.res_model, activity.res_id
|
||||
FROM "%s" activity
|
||||
WHERE activity.id = ANY (%%(ids)s)""" % self._table, dict(ids=list(sub_ids)))
|
||||
activities_to_check = self._cr.dictfetchall()
|
||||
activities_to_check += self._cr.dictfetchall()
|
||||
|
||||
activity_to_documents = {}
|
||||
for activity in activities_to_check:
|
||||
|
||||
Reference in New Issue
Block a user