[MOV] account,sale --> (account,sale)_intrastat: intrastat code.

closes odoo/odoo#44858

Related: odoo/enterprise#8277
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
This commit is contained in:
Victor Feyens
2020-02-11 09:25:20 +00:00
parent a8ecefcd94
commit a247d64377
2 changed files with 0 additions and 16 deletions
-7
View File
@@ -1838,13 +1838,6 @@ class AccountMove(models.Model):
self.ensure_one()
return self.partner_id.address_get(['delivery'])['delivery']
def _get_invoice_intrastat_country_id(self):
''' Hook allowing to retrieve the intrastat country depending of installed modules.
:return: A res.country record's id.
'''
self.ensure_one()
return self.partner_id.country_id.id
def _get_cash_basis_matched_percentage(self):
"""Compute the percentage to apply for cash basis method. This value is relevant only for moves that
involve journal items on receivable or payable accounts.
-9
View File
@@ -103,12 +103,3 @@ class AccountMove(models.Model):
# OVERRIDE
self.ensure_one()
return self.partner_shipping_id.id or super(AccountMove, self)._get_invoice_delivery_partner_id()
def _get_invoice_intrastat_country_id(self):
# OVERRIDE
self.ensure_one()
if self.is_sale_document():
intrastat_country_id = self.partner_shipping_id.country_id.id
else:
intrastat_country_id = super(AccountMove, self)._get_invoice_intrastat_country_id()
return intrastat_country_id