[Fix] PO status not changed as material return created against them (#6869)

This commit is contained in:
rohitwaghchaure
2016-11-16 11:10:10 +05:30
committed by Rushabh Mehta
parent e0ab64d6cc
commit b3ba7f01ef
3 changed files with 39 additions and 1 deletions

View File

@@ -207,6 +207,7 @@ def make_return_doc(doctype, source_name, target_doc=None):
target_doc.rejected_qty = -1* source_doc.rejected_qty
target_doc.qty = -1* source_doc.qty
target_doc.purchase_order = source_doc.purchase_order
target_doc.purchase_order_item = source_doc.purchase_order_item
target_doc.rejected_warehouse = source_doc.rejected_warehouse
elif doctype == "Purchase Invoice":
target_doc.received_qty = -1* source_doc.received_qty