[fix] Purchase Return warehouse validation
This commit is contained in:
parent
cc6ce5beac
commit
82cef59fb3
@ -97,7 +97,7 @@ def validate_returned_items(doc):
|
||||
frappe.throw(_("Row # {0}: Serial No {1} does not match with {2} {3}")
|
||||
.format(d.idx, s, doc.doctype, doc.return_against))
|
||||
|
||||
if not d.warehouse:
|
||||
if doc.doctype != "Purchase Invoice" and not d.get("warehouse"):
|
||||
frappe.throw(_("Warehouse is mandatory"))
|
||||
|
||||
items_returned = True
|
||||
|
Loading…
x
Reference in New Issue
Block a user