mirror of
https://github.com/frappe/erpnext.git
synced 2026-08-14 15:11:52 +00:00
fix(stock): narrow legacy serial ledger lookup by item (#57499)
Filter legacy Stock Ledger Entry lookups by item code so the existing item and warehouse index can reduce rows scanned during serial valuation.
This commit is contained in:
committed by
GitHub
parent
05a15dff71
commit
425191e57e
@@ -75,6 +75,7 @@ class DeprecatedSerialNoValuation:
|
||||
| (table.serial_no.like("%\n" + serial_no))
|
||||
| (table.serial_no.like("%\n" + serial_no + "\n%"))
|
||||
)
|
||||
& (table.item_code == self.sle.item_code)
|
||||
& (table.company == self.sle.company)
|
||||
& (table.warehouse == self.sle.warehouse)
|
||||
& (table.serial_and_batch_bundle.isnull())
|
||||
|
||||
Reference in New Issue
Block a user