From 3751379f1e9a4c215fb6eb898b4ccc67659b9ace Mon Sep 17 00:00:00 2001 From: stephanchrst Date: Tue, 10 May 2022 21:51:50 +0700 Subject: initial commit 2 --- addons/stock_landed_costs/models/purchase.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 addons/stock_landed_costs/models/purchase.py (limited to 'addons/stock_landed_costs/models/purchase.py') diff --git a/addons/stock_landed_costs/models/purchase.py b/addons/stock_landed_costs/models/purchase.py new file mode 100644 index 00000000..369dea03 --- /dev/null +++ b/addons/stock_landed_costs/models/purchase.py @@ -0,0 +1,9 @@ +from odoo import api,models + +class PurchaseOrderLine(models.Model): + _inherit = 'purchase.order.line' + + def _prepare_account_move_line(self, move=False): + res = super()._prepare_account_move_line(move) + res.update({'is_landed_costs_line': self.product_id.landed_cost_ok}) + return res -- cgit v1.2.3