From d87bcdfe5e6e49e31dce5c423bcdaa4dfba9623e Mon Sep 17 00:00:00 2001 From: Azka Nathan Date: Tue, 23 Jan 2024 14:00:37 +0700 Subject: change request sale_order_sync --- indoteknik_custom/models/purchase_order.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/indoteknik_custom/models/purchase_order.py b/indoteknik_custom/models/purchase_order.py index 5303f2c3..ebadff06 100755 --- a/indoteknik_custom/models/purchase_order.py +++ b/indoteknik_custom/models/purchase_order.py @@ -249,6 +249,8 @@ class PurchaseOrder(models.Model): self.order_line.unlink() for order_line in self.sale_order_id.order_line: + if order_line.vendor_id != self.partner_id: + continue if order_line.product_id.id and order_line.product_id.id not in products_exception: qty_available = order_line.product_id.qty_onhand_bandengan + order_line.product_id.qty_incoming_bandengan - order_line.product_id.outgoing_qty -- cgit v1.2.3