mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-21 22:19:18 +00:00
Don't validate serial nos while cancelling the transaction
This commit is contained in:
@@ -187,7 +187,7 @@ def process_serial_no(sle):
|
|||||||
update_serial_nos(sle, item_det)
|
update_serial_nos(sle, item_det)
|
||||||
|
|
||||||
def validate_serial_no(sle, item_det):
|
def validate_serial_no(sle, item_det):
|
||||||
if item_det.has_serial_no==0:
|
if item_det.has_serial_no==0 and sle.is_cancelled == "No":
|
||||||
if sle.serial_no:
|
if sle.serial_no:
|
||||||
frappe.throw(_("Item {0} is not setup for Serial Nos. Column must be blank").format(sle.item_code),
|
frappe.throw(_("Item {0} is not setup for Serial Nos. Column must be blank").format(sle.item_code),
|
||||||
SerialNoNotRequiredError)
|
SerialNoNotRequiredError)
|
||||||
|
|||||||
Reference in New Issue
Block a user