mirror of
https://github.com/frappe/erpnext.git
synced 2026-02-13 09:43:49 +00:00
Merge pull request #45617 from rtdany10/expired-batch-pick
fix: ignore expired batch for pick list
This commit is contained in:
@@ -2453,6 +2453,9 @@ def get_stock_ledgers_batches(kwargs):
|
||||
else:
|
||||
query = query.where(stock_ledger_entry[field] == kwargs.get(field))
|
||||
|
||||
if not kwargs.get("for_stock_levels"):
|
||||
query = query.where((batch_table.expiry_date >= today()) | (batch_table.expiry_date.isnull()))
|
||||
|
||||
if kwargs.get("posting_date"):
|
||||
if kwargs.get("posting_time") is None:
|
||||
kwargs.posting_time = nowtime()
|
||||
|
||||
Reference in New Issue
Block a user