fixes in get_serial_number function
diff --git a/erpnext/public/js/utils.js b/erpnext/public/js/utils.js
index 08d61ce..111ad6d 100644
--- a/erpnext/public/js/utils.js
+++ b/erpnext/public/js/utils.js
@@ -59,7 +59,6 @@
 
 	setup_serial_no: function() {
 		var grid_row = cur_frm.open_grid_row();
-
 		if(!grid_row.fields_dict.serial_no ||
 			grid_row.fields_dict.serial_no.get_status()!=="Write") return;
 
@@ -76,9 +75,13 @@
 						"fieldtype": "Link",
 						"options": "Serial No",
 						"label": __("Serial No"),
-						"get_query": {
-							item_code: grid_row.doc.item_code,
-							warehouse: grid_row.doc.warehouse
+						"get_query": function () {
+							return { 
+								filters: { 
+									item_code:grid_row.doc.item_code ,
+									warehouse:grid_row.doc.warehouse
+								}
+							}
 						}
 					},
 					{