From fe59ace285d7c0b6076406fac72e1665d60e8781 Mon Sep 17 00:00:00 2001 From: Mihir Kandoi Date: Mon, 19 Jan 2026 19:49:01 +0530 Subject: [PATCH] fix: no attribute error on LCV (cherry picked from commit ad11914fca2c8cb984a0e5b3b02acf142e28b541) --- .../stock/doctype/landed_cost_voucher/landed_cost_voucher.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 ca4cdf5d458..9d23eda3755 100644 --- a/erpnext/stock/doctype/landed_cost_voucher/landed_cost_voucher.py +++ b/erpnext/stock/doctype/landed_cost_voucher/landed_cost_voucher.py @@ -437,7 +437,7 @@ def get_vendor_invoices(doctype, txt, searchfield, start, page_len, filters): query = get_vendor_invoice_query(filters) if txt: - query = query.where(doctype.name.like(f"%{txt}%")) + query = query.where(frappe.qb.DocType(doctype).name.like(f"%{txt}%")) if start: query = query.limit(page_len).offset(start)