From d7330ec7094752055ac7c3d0e026a6bc5e963d17 Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Sat, 18 Apr 2015 17:03:49 +0530 Subject: [PATCH] [minor] add disabled property in fiscal year: --- .../accounts/doctype/fiscal_year/fiscal_year.json | 9 ++++++++- .../doctype/production_order/production_order.js | 14 ++++++-------- 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/erpnext/accounts/doctype/fiscal_year/fiscal_year.json b/erpnext/accounts/doctype/fiscal_year/fiscal_year.json index 4059be4f2b..0057d6d5a2 100644 --- a/erpnext/accounts/doctype/fiscal_year/fiscal_year.json +++ b/erpnext/accounts/doctype/fiscal_year/fiscal_year.json @@ -18,6 +18,13 @@ "permlevel": 0, "reqd": 1 }, + { + "fieldname": "disabled", + "fieldtype": "Check", + "label": "Disabled", + "permlevel": 0, + "precision": "" + }, { "fieldname": "year_start_date", "fieldtype": "Date", @@ -49,7 +56,7 @@ ], "icon": "icon-calendar", "idx": 1, - "modified": "2015-02-05 05:11:38.994147", + "modified": "2015-04-18 07:33:23.922518", "modified_by": "Administrator", "module": "Accounts", "name": "Fiscal Year", diff --git a/erpnext/manufacturing/doctype/production_order/production_order.js b/erpnext/manufacturing/doctype/production_order/production_order.js index 471b46b4bf..60ecd03ee5 100644 --- a/erpnext/manufacturing/doctype/production_order/production_order.js +++ b/erpnext/manufacturing/doctype/production_order/production_order.js @@ -69,14 +69,12 @@ erpnext.production_order = { cur_frm.cscript['Update Finished Goods'], frappe.boot.doctype_icons["Stock Entry"]); } - if(doc.status==="Completed") { - frm.add_custom_button(__("Show Stock Entries"), function() { - frappe.route_options = { - production_order: frm.doc.name - } - frappe.set_route("List", "Stock Entry"); - }); - } + frm.add_custom_button(__("Show Stock Entries"), function() { + frappe.route_options = { + production_order: frm.doc.name + } + frappe.set_route("List", "Stock Entry"); + }); if (doc.status != 'Stopped' && doc.status != 'Completed') { frm.add_custom_button(__('Stop'), cur_frm.cscript['Stop Production Order'],