fix: Item qty cannot be zero in Purchase Receipt (#19781)

This commit is contained in:
Marica
2019-12-03 12:45:28 +05:30
committed by Nabin Hait
parent b78128a7fe
commit 6067ef3c49

View File

@@ -375,6 +375,7 @@ class AccountsController(TransactionBase):
return gl_dict return gl_dict
def validate_qty_is_not_zero(self): def validate_qty_is_not_zero(self):
if self.doctype != "Purchase Receipt":
for item in self.items: for item in self.items:
if not item.qty: if not item.qty:
frappe.throw(_("Item quantity can not be zero")) frappe.throw(_("Item quantity can not be zero"))