diff options
| author | Nicolas Martinelli <nim@odoo.com> | 2019-03-12 12:47:18 +0000 |
|---|---|---|
| committer | Nicolas Martinelli <nim@odoo.com> | 2019-03-12 12:52:10 +0000 |
| commit | 4524dcd69158763575124e5867a7e1d295ebe034 (patch) | |
| tree | bad2364976fbc27205138670ea3c5d0bbc88f9f6 | |
| parent | c16d2827bccbc47ee11b208cd428faf99b47a499 (diff) | |
[FIX] sale: fiscal position
- Create a fiscal position FP which maps the deposit product account to
another account
- Create a SO, use the fiscal position FP.
- Create a downpayment
The account is not mapped following the fiscal position.
opw-1947069
closes odoo/odoo#31781
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
| -rw-r--r-- | addons/sale/wizard/sale_make_invoice_advance.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/sale/wizard/sale_make_invoice_advance.py b/addons/sale/wizard/sale_make_invoice_advance.py index 704c568b7f7..c528c25b7d2 100644 --- a/addons/sale/wizard/sale_make_invoice_advance.py +++ b/addons/sale/wizard/sale_make_invoice_advance.py @@ -65,7 +65,7 @@ class SaleAdvancePaymentInv(models.TransientModel): account_id = False if self.product_id.id: - account_id = self.product_id.property_account_income_id.id or self.product_id.categ_id.property_account_income_categ_id.id + account_id = order.fiscal_position_id.map_account(self.product_id.property_account_income_id or self.product_id.categ_id.property_account_income_categ_id).id if not account_id: inc_acc = ir_property_obj.get('property_account_income_categ_id', 'product.category') account_id = order.fiscal_position_id.map_account(inc_acc).id if inc_acc else False |
