mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-07 23:22:52 +00:00
fix: qty based check for stock reservation of serial-batch items based on qty
This commit is contained in:
@@ -1833,7 +1833,7 @@ def validate_reserved_stock(kwargs):
|
|||||||
elif batch_nos := [entry.batch_no for entry in sbb_entries if entry.batch_no]:
|
elif batch_nos := [entry.batch_no for entry in sbb_entries if entry.batch_no]:
|
||||||
validate_reserved_batch_nos(kwargs.item_code, kwargs.warehouse, batch_nos)
|
validate_reserved_batch_nos(kwargs.item_code, kwargs.warehouse, batch_nos)
|
||||||
|
|
||||||
else:
|
# Qty based validation for non-serial-batch items OR SRE with Reservation Based On Qty.
|
||||||
precision = cint(frappe.db.get_default("float_precision")) or 2
|
precision = cint(frappe.db.get_default("float_precision")) or 2
|
||||||
balance_qty = get_stock_balance(kwargs.item_code, kwargs.warehouse)
|
balance_qty = get_stock_balance(kwargs.item_code, kwargs.warehouse)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user