Skip to content

Commit

Permalink
[MIG] account_invoice_product_code_remove: Migration to 17.0
Browse files Browse the repository at this point in the history
  • Loading branch information
alan196 committed Nov 1, 2024
1 parent 71fd98c commit 37bdbf5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion account_invoice_product_code_remove/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"author": "Jarsa, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/account-invoicing",
"category": "Accounting & Finance",
"version": "15.0.1.0.0",
"version": "17.0.1.0.0",
"license": "LGPL-3",
"depends": ["account"],
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
class AccountMoveLine(models.Model):
_inherit = "account.move.line"

def _get_computed_name(self):
name = super()._get_computed_name()
def _compute_name(self):
res = super()._compute_name()
if self.product_id.default_code:
name = name.replace(f"[{self.product_id.default_code}] ", "").strip()
return name
self.name = self.name.replace(f"[{self.product_id.default_code}] ", "").strip()
return res

0 comments on commit 37bdbf5

Please sign in to comment.