Skip to content

Commit

Permalink
[MIG] l10n_ar_stock: Migration to 17.0
Browse files Browse the repository at this point in the history
  • Loading branch information
mem-adhoc committed Feb 16, 2024
1 parent b250820 commit 211ada2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 10 deletions.
4 changes: 2 additions & 2 deletions l10n_ar_stock/__manifest__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
'name': 'Remitos, COT y demas ajustes de stock para Argentina',
'version': "16.0.1.5.0",
'version': "17.0.1.0.0",
'category': 'Localization/Argentina',
'sequence': 14,
'author': 'ADHOC SA',
Expand Down Expand Up @@ -31,7 +31,7 @@
'demo/stock_book_demo.xml',
'demo/stock_picking_demo.xml',
],
'installable': False,
'installable': True,
'auto_install': False,
'application': False,
}
11 changes: 3 additions & 8 deletions l10n_ar_stock/models/account_chart_template.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,13 @@
from odoo import models, api


class AccountChartTemplate(models.Model):
class AccountChartTemplate(models.AbstractModel):
_inherit = 'account.chart.template'

def _load_template(
self, company, code_digits=None,
account_ref=None, taxes_ref=None):
self.ensure_one()
@api.model(mode='stock.book')
def _get_stock_book(self, company=False):
if company.country_id == self.env.ref('base.ar'):
self.generate_stock_book(company)
return super(AccountChartTemplate, self)._load_template(
company, code_digits,
account_ref, taxes_ref)

@api.model
def generate_stock_book(self, company):
Expand Down

0 comments on commit 211ada2

Please sign in to comment.