I am new in javascript and want to store column value from database table into a variable for the purpose of editing. can some one guide me how should i perform this? I have done this so far.
var itemName =$("product_id").find("product_id").text();
var qty = $("qty").find("qty").text();
var unit =$(this).find("UnitPrice").text();
var total =$("rate").find("rate").text();
var row = "<tr><td>" + itemName + "</td>" + "<td>" + qty + "</td>"+"<td>"+unit+"</td>" + "<td>" + total + "</td>" +
"<td>" + "<a href='javascript:deleteLead(\"" + $(this).find("SalesLeadCode").text() + "\");' class=\"btn btn-danger\"><i class=\"glyphicon glyphicon-remove\"></i> Remove</a>" + "</td>";
$('#item_grid').append(row);