[grid] [bom] fixes erpnext #514, #515, wnframework #187
diff --git a/manufacturing/doctype/bom/bom.js b/manufacturing/doctype/bom/bom.js
index b1f43f7..d14590c 100644
--- a/manufacturing/doctype/bom/bom.js
+++ b/manufacturing/doctype/bom/bom.js
@@ -44,9 +44,9 @@
var op = op_table[i].operation_no;
if (op && !inList(operations, op)) operations.push(op);
}
-
- cur_frm.fields_dict["bom_materials"].grid.get_field("operation_no")
- .df.options = operations.join("\n");
+
+ wn.meta.get_docfield("BOM Item", "operation_no",
+ cur_frm.docname).options = operations.join("\n");
$.each(getchildren("BOM Item", doc.name, "bom_materials"), function(i, v) {
if(!inList(operations, cstr(v.operation_no))) v.operation_no = null;
diff --git a/manufacturing/doctype/bom/bom.txt b/manufacturing/doctype/bom/bom.txt
index 922fd80..d539ad0 100644
--- a/manufacturing/doctype/bom/bom.txt
+++ b/manufacturing/doctype/bom/bom.txt
@@ -2,7 +2,7 @@
{
"creation": "2013-01-22 15:11:38",
"docstatus": 0,
- "modified": "2013-01-29 17:32:53",
+ "modified": "2013-06-27 11:08:28",
"modified_by": "Administrator",
"owner": "Administrator"
},
@@ -112,6 +112,7 @@
"options": "Specify the operations, operating cost and give a unique Operation no to your operations."
},
{
+ "depends_on": "with_operations",
"doctype": "DocField",
"fieldname": "bom_operations",
"fieldtype": "Table",
diff --git a/manufacturing/doctype/bom_item/bom_item.txt b/manufacturing/doctype/bom_item/bom_item.txt
index 14be95a..2554adf 100644
--- a/manufacturing/doctype/bom_item/bom_item.txt
+++ b/manufacturing/doctype/bom_item/bom_item.txt
@@ -2,7 +2,7 @@
{
"creation": "2013-02-22 01:27:49",
"docstatus": 0,
- "modified": "2013-03-07 07:03:18",
+ "modified": "2013-06-27 11:30:07",
"modified_by": "Administrator",
"owner": "Administrator"
},
@@ -92,6 +92,7 @@
"reqd": 1
},
{
+ "description": "See \"Rate Of Materials Based On\" in Costing Section",
"doctype": "DocField",
"fieldname": "rate",
"fieldtype": "Float",