fix: remove unused format from query

doctype is not used in query and parent alone is enough to identify
packed items.
This commit is contained in:
Ankush Menat 2021-09-01 15:24:49 +05:30
parent 7d9819f352
commit 55b24345a0
No known key found for this signature in database
GPG Key ID: 8EA82E09BBD13AAF

View File

@ -63,7 +63,7 @@ def validate_returned_items(doc):
if doc.doctype in ("Delivery Note", "Sales Invoice"):
for d in frappe.db.sql("""select item_code, qty, serial_no, batch_no from `tabPacked Item`
where parent = %s""".format(doc.doctype), doc.return_against, as_dict=1):
where parent = %s""", doc.return_against, as_dict=1):
valid_items = get_ref_item_dict(valid_items, d)
already_returned_items = get_already_returned_items(doc)