From 8692996a09b8c53256622a677ca1eeaa97f368c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20L=C3=B3pez?= Date: Tue, 27 Aug 2024 11:56:48 -0400 Subject: [PATCH] [FIX] l10n_do_accounting: TypeError: AccountMove._name_search() got an unexpected keyword argument 'order' --- l10n_do_accounting/__manifest__.py | 2 +- l10n_do_accounting/models/account_move.py | 14 ++++---------- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/l10n_do_accounting/__manifest__.py b/l10n_do_accounting/__manifest__.py index 3aab77d33..539b25590 100644 --- a/l10n_do_accounting/__manifest__.py +++ b/l10n_do_accounting/__manifest__.py @@ -8,7 +8,7 @@ "category": "Localization", "license": "LGPL-3", "website": "https://github.com/odoo-dominicana", - "version": "17.0.1.0.2", + "version": "17.0.1.0.3", "countries": ["do"], # any module necessary for this one to work correctly "depends": ["l10n_latam_invoice_document", "l10n_do"], diff --git a/l10n_do_accounting/models/account_move.py b/l10n_do_accounting/models/account_move.py index b8700acf6..baf4383d8 100644 --- a/l10n_do_accounting/models/account_move.py +++ b/l10n_do_accounting/models/account_move.py @@ -190,20 +190,14 @@ def _auto_init(self): return super()._auto_init() @api.model - def _name_search( - self, name="", args=None, operator="ilike", limit=100, name_get_uid=None - ): - args = args or [] - domain = [] + def _name_search(self, name, domain=None, operator='ilike', limit=None, order=None): if name: - domain = [ + domain = expression.AND([[ "|", ("name", operator, name), ("l10n_do_fiscal_number", operator, name), - ] - return self._search( - expression.AND([domain, args]), limit=limit, access_rights_uid=name_get_uid - ) + ], domain]) + return super()._name_search(name, domain, operator, limit, order) def _l10n_do_is_new_expiration_date(self): self.ensure_one()