From 4d904c0dc4c478e02bddafa25e5c365c5dfae35e Mon Sep 17 00:00:00 2001 From: William Henrotin Date: Mon, 22 May 2023 15:46:21 +0000 Subject: [PATCH] [FIX] stock: hide quants for consumable In the detailled operation view, hide the `quant_id` column for consumable products as they have no quant Task: 3256447 Part-of: odoo/odoo#122445 --- addons/stock/models/stock_move.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/stock/models/stock_move.py b/addons/stock/models/stock_move.py index f99ef69c8cc..e0ac7040f76 100644 --- a/addons/stock/models/stock_move.py +++ b/addons/stock/models/stock_move.py @@ -800,7 +800,7 @@ Please change the quantity done or the rounding precision of your unit of measur if self.product_id.tracking == "serial" and self.state == "assigned": self.next_serial = self.env['stock.lot']._get_next_serial(self.company_id, self.product_id) - quant_mode = self.picking_type_id.code != 'incoming' + quant_mode = self.picking_type_id.code != 'incoming' or self.product_id.detailed_type != 'product' return { 'name': _('Detailed Operations'), 'type': 'ir.actions.act_window',