make time log button in Production order operations fixed
show time logs button made available for compleated operations
This commit is contained in:
parent
8d5d5cc0a7
commit
5ab7d930b6
@ -204,12 +204,13 @@ $.extend(cur_frm.cscript, {
|
|||||||
method:"erpnext.manufacturing.doctype.production_order.production_order.make_time_log",
|
method:"erpnext.manufacturing.doctype.production_order.production_order.make_time_log",
|
||||||
args: {
|
args: {
|
||||||
"name": doc.name,
|
"name": doc.name,
|
||||||
"operation": child.idx + ". " + child.operation,
|
"operation": child.operation,
|
||||||
"from_time": child.planned_start_time,
|
"from_time": child.planned_start_time,
|
||||||
"to_time": child.planned_end_time,
|
"to_time": child.planned_end_time,
|
||||||
"project": doc.project,
|
"project": doc.project,
|
||||||
"workstation": child.workstation,
|
"workstation": child.workstation,
|
||||||
"qty": flt(doc.qty) - flt(child.completed_qty)
|
"qty": flt(doc.qty) - flt(child.completed_qty),
|
||||||
|
"operation_id": child.name
|
||||||
},
|
},
|
||||||
callback: function(r) {
|
callback: function(r) {
|
||||||
var doclist = frappe.model.sync(r.message);
|
var doclist = frappe.model.sync(r.message);
|
||||||
|
|||||||
@ -126,7 +126,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"allow_on_submit": 1,
|
"allow_on_submit": 1,
|
||||||
"depends_on": "eval:(doc.docstatus==1 && doc.status!=\"Completed\")",
|
"depends_on": "eval:(doc.docstatus==1)",
|
||||||
"fieldname": "show_time_logs",
|
"fieldname": "show_time_logs",
|
||||||
"fieldtype": "Button",
|
"fieldtype": "Button",
|
||||||
"label": "Show Time Logs",
|
"label": "Show Time Logs",
|
||||||
@ -277,6 +277,7 @@
|
|||||||
"read_only": 1
|
"read_only": 1
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
"allow_on_submit": 1,
|
||||||
"depends_on": "eval:(doc.docstatus==1 && doc.status!=\"Completed\")",
|
"depends_on": "eval:(doc.docstatus==1 && doc.status!=\"Completed\")",
|
||||||
"fieldname": "make_time_log",
|
"fieldname": "make_time_log",
|
||||||
"fieldtype": "Button",
|
"fieldtype": "Button",
|
||||||
@ -292,7 +293,7 @@
|
|||||||
"is_submittable": 0,
|
"is_submittable": 0,
|
||||||
"issingle": 0,
|
"issingle": 0,
|
||||||
"istable": 1,
|
"istable": 1,
|
||||||
"modified": "2015-03-24 07:02:54.203235",
|
"modified": "2015-04-01 08:23:58.556092",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "Manufacturing",
|
"module": "Manufacturing",
|
||||||
"name": "Production Order Operation",
|
"name": "Production Order Operation",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user