From 8d87673201e7339cb946c36e8f91579e135d5c5b Mon Sep 17 00:00:00 2001 From: Azka Nathan Date: Wed, 5 Jun 2024 11:03:10 +0700 Subject: api promotion program line get program line by promotion_type --- indoteknik_custom/models/product_template.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indoteknik_custom/models') diff --git a/indoteknik_custom/models/product_template.py b/indoteknik_custom/models/product_template.py index 6086a2ca..d490eb05 100755 --- a/indoteknik_custom/models/product_template.py +++ b/indoteknik_custom/models/product_template.py @@ -403,7 +403,7 @@ class ProductProduct(models.Model): for product in self: qty_incoming = self.env['stock.move'].search([ ('product_id', '=', product.id), - ('location_dest_id', '=', 57), + ('location_dest_id', 'in', [57, 83]), ('state', 'not in', ['done', 'cancel']) ]) qty = sum(qty_incoming.mapped('product_uom_qty')) @@ -414,7 +414,7 @@ class ProductProduct(models.Model): qty_incoming = self.env['stock.move'].search([ ('product_id', '=', product.id), ('location_dest_id', '=', 5), - ('location_id', '=', 57), + ('location_id', 'in', [57, 83]), ('state', 'not in', ['done', 'cancel']) ]) qty = sum(qty_incoming.mapped('product_uom_qty')) -- cgit v1.2.3