From 3b3d55cda2427efa5b3ef671b09b4e3b23488c16 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Sat, 26 Apr 2014 12:22:30 +0530 Subject: [PATCH] Usability: Set For Warehouse and Work-in-Progress Warehouse as mandatory, when the user clicks Submit --- .../doctype/production_order/production_order.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/erpnext/manufacturing/doctype/production_order/production_order.js b/erpnext/manufacturing/doctype/production_order/production_order.js index 07e6e11f43..d5fb1c997b 100644 --- a/erpnext/manufacturing/doctype/production_order/production_order.js +++ b/erpnext/manufacturing/doctype/production_order/production_order.js @@ -10,6 +10,10 @@ $.extend(cur_frm.cscript, { this.frm.add_fetch("sales_order", "delivery_date", "expected_delivery_date"); }, + before_submit: function() { + cur_frm.toggle_reqd(["fg_warehouse", "wip_warehouse"], true); + }, + refresh: function(doc, dt, dn) { this.frm.dashboard.reset(); erpnext.toggle_naming_series();