diff --git a/erpnext/controllers/buying_controller.py b/erpnext/controllers/buying_controller.py index ffd021773c9..56ecb45fdff 100644 --- a/erpnext/controllers/buying_controller.py +++ b/erpnext/controllers/buying_controller.py @@ -755,6 +755,8 @@ class BuyingController(StockController, Subcontracting): asset.purchase_date = self.posting_date asset.supplier = self.supplier elif self.docstatus == 2: + if asset.docstatus == 2: + continue if asset.docstatus == 0: asset.set(field, None) asset.supplier = None