From 74948aabdae8edb7316be9ff8e7604229a963d04 Mon Sep 17 00:00:00 2001 From: Mihir Kandoi Date: Thu, 3 Jul 2025 12:45:35 +0530 Subject: [PATCH] fix: LCV from PR order mismatch --- erpnext/stock/doctype/landed_cost_voucher/landed_cost_voucher.py | 1 + 1 file changed, 1 insertion(+) diff --git a/erpnext/stock/doctype/landed_cost_voucher/landed_cost_voucher.py b/erpnext/stock/doctype/landed_cost_voucher/landed_cost_voucher.py index c80bcc8123b..a70af1fc384 100644 --- a/erpnext/stock/doctype/landed_cost_voucher/landed_cost_voucher.py +++ b/erpnext/stock/doctype/landed_cost_voucher/landed_cost_voucher.py @@ -332,5 +332,6 @@ def get_pr_items(purchase_receipt): (pr_item.parent == purchase_receipt.receipt_document) & ((item.is_stock_item == 1) | (item.is_fixed_asset == 1)) ) + .orderby(pr_item.idx) .run(as_dict=True) )