mirror of
https://github.com/frappe/erpnext.git
synced 2026-02-19 09:35:03 +00:00
fix: allow target warehouses to be changed for work order stock entries
This commit is contained in:
@@ -294,13 +294,8 @@ class StockEntry(StockController):
|
||||
if validate_for_manufacture:
|
||||
if d.bom_no:
|
||||
d.s_warehouse = None
|
||||
|
||||
if not d.t_warehouse:
|
||||
frappe.throw(_("Target warehouse is mandatory for row {0}").format(d.idx))
|
||||
|
||||
elif self.pro_doc and (cstr(d.t_warehouse) != self.pro_doc.fg_warehouse and cstr(d.t_warehouse) != self.pro_doc.scrap_warehouse):
|
||||
frappe.throw(_("Target warehouse in row {0} must be same as Work Order").format(d.idx))
|
||||
|
||||
else:
|
||||
d.t_warehouse = None
|
||||
if not d.s_warehouse:
|
||||
|
||||
Reference in New Issue
Block a user