fix: SABB validation for packed items
(cherry picked from commit 3756bf231b)
This commit is contained in:
committed by
Mergify
parent
a07eb556cf
commit
2d6626e906
@@ -145,6 +145,11 @@ class SerialandBatchBundle(Document):
|
||||
)
|
||||
|
||||
elif not frappe.db.exists("Stock Ledger Entry", {"voucher_detail_no": self.voucher_detail_no}):
|
||||
if self.voucher_type == "Delivery Note" and frappe.db.exists(
|
||||
"Packed Item", self.voucher_detail_no
|
||||
):
|
||||
return
|
||||
|
||||
frappe.throw(
|
||||
_("The serial and batch bundle {0} not linked to {1} {2}").format(
|
||||
bold(self.name), self.voucher_type, bold(self.voucher_no)
|
||||
|
||||
Reference in New Issue
Block a user