fix(stock): ignore current voucher in reserved stock validation

This commit is contained in:
Kavin
2025-11-10 14:28:37 +05:30
parent 5bb2e8a8ff
commit 0e7f9711e1

View File

@@ -2235,6 +2235,10 @@ def get_future_sle_with_negative_batch_qty(sle_args):
def validate_reserved_stock(kwargs):
# ignore current voucher when validating the reserved stock
if not kwargs.ignore_voucher_nos and kwargs.voucher_no:
kwargs.ignore_voucher_nos = [kwargs.voucher_no]
if kwargs.serial_no:
validate_reserved_serial_nos(kwargs)