diff --git a/custom_addons/dashboard/models/stock_dashboard.py b/custom_addons/dashboard/models/stock_dashboard.py index 1286e7098..92498c36e 100644 --- a/custom_addons/dashboard/models/stock_dashboard.py +++ b/custom_addons/dashboard/models/stock_dashboard.py @@ -270,7 +270,7 @@ class SamashtiDashboard(models.AbstractModel): move_ids = mo_ids.move_raw_ids + mo_ids.move_finished_ids + mo_ids.scrap_ids.move_ids stock_layer_ids = move_ids.filtered(lambda x:x.location_id.usage == 'production' or x.location_dest_id.usage == 'production' ).stock_valuation_layer_ids data = [] - for l in stock_layer_ids.filtered(lambda x:x.quantity > 0): + for l in stock_layer_ids.filtered(lambda x:x.quantity != 0): mo = self.env['mrp.production'].search([('name', 'ilike', l.reference),('state','=','done')]) product_tags = ', '.join( tag.name for tag in l.mapped('product_id.product_tag_ids')