From dafcd04a43c4e181609191b56919d294131aa951 Mon Sep 17 00:00:00 2001 From: Camila Vives Date: Mon, 15 Dec 2025 17:07:34 +0000 Subject: [PATCH] [FIX] account_interests: remove job_id in cron as is not used --- account_interests/models/res_company_interest.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/account_interests/models/res_company_interest.py b/account_interests/models/res_company_interest.py index 63ab8d981..862685d04 100644 --- a/account_interests/models/res_company_interest.py +++ b/account_interests/models/res_company_interest.py @@ -2,11 +2,14 @@ # For copyright and license notices, see __manifest__.py file in module root # directory ############################################################################## -from odoo import models, fields, api, _ -from odoo.tools.safe_eval import safe_eval +import logging + from dateutil.relativedelta import relativedelta from odoo.exceptions import UserError -import logging +from odoo.tools.safe_eval import safe_eval + +from odoo import _, api, fields, models + _logger = logging.getLogger(__name__) @@ -130,7 +133,7 @@ def _cron_recurring_interests_invoices(self, batch_size=1): self.env.cr.commit() if last_updated_id: - cron = self.env['ir.cron'].browse(self.env.context.get('job_id')) or self.env.ref('account_interests.cron_recurring_interests_invoices') + cron = self.env.ref('account_interests.cron_recurring_interests_invoices') cron._trigger() def create_interest_invoices(self):