fix: AttributeError while saving Purchase Invoice

This commit is contained in:
s-aga-r 2023-12-01 11:27:54 +05:30
parent 591f4ebdca
commit 60a81a563e

View File

@ -440,7 +440,7 @@ class BuyingController(SubcontractingController):
if allow_to_edit_stock_qty:
d.stock_qty = flt(d.stock_qty, d.precision("stock_qty"))
if d.get("received_stock_qty"):
if d.get("received_stock_qty") and d.meta.get_field("received_stock_qty"):
d.received_stock_qty = flt(d.received_stock_qty, d.precision("received_stock_qty"))
def validate_purchase_return(self):