diff --git a/erpnext/stock/doctype/stock_ledger_entry/stock_ledger_entry.json b/erpnext/stock/doctype/stock_ledger_entry/stock_ledger_entry.json index f5aced3b7b..8275c84416 100644 --- a/erpnext/stock/doctype/stock_ledger_entry/stock_ledger_entry.json +++ b/erpnext/stock/doctype/stock_ledger_entry/stock_ledger_entry.json @@ -694,7 +694,7 @@ "issingle": 0, "istable": 0, "max_attachments": 0, - "modified": "2016-12-15 14:45:07.733480", + "modified": "2017-06-09 14:45:07.888888", "modified_by": "Administrator", "module": "Stock", "name": "Stock Ledger Entry", diff --git a/erpnext/stock/doctype/stock_ledger_entry/stock_ledger_entry.py b/erpnext/stock/doctype/stock_ledger_entry/stock_ledger_entry.py index 55a307cd3e..b5d2e3f790 100644 --- a/erpnext/stock/doctype/stock_ledger_entry/stock_ledger_entry.py +++ b/erpnext/stock/doctype/stock_ledger_entry/stock_ledger_entry.py @@ -129,3 +129,5 @@ def on_doctype_update(): frappe.db.commit() frappe.db.sql("""alter table `tabStock Ledger Entry` add index posting_sort_index(posting_date, posting_time, name)""") + + frappe.db.add_index("Stock Ledger Entry", ["voucher_no", "voucher_type"])