Gurmeet Singh

Gurmeet Singh

  • NA
  • 176
  • 40k

save angularjs table data in database in mvc

Nov 26 2016 5:57 AM
 
I want to save the angularjs table list in database table in mvc...
the data is coming in angularjs table from database, i want to save that data into sql table in mvc. please anyone help me
i collect all json data, but in ajax call data in not coming.
$scope.genbil = function () {
//alert(angular.toJson($scope.itemslst));
var jdata = JSON.stringify($scope.itemslst);
alert(jdata);
$.ajax({
type: 'POST',
contentType: 'application/json; charset=utf-8',
data: JSON.stringify($scope.itemslst),
url: '/CustomerItem/GetBill',
success: function (data, status) {
alert("success");
},
error: function (status) { }
});
}
public ActionResult GetBill(string data)
{
return View();
}

Answers (1)