Not getting array of data from ajax to controller.
$.ajax({
type: "POST",
url: "/Home/List",
traditional: true,
contentType: 'application/json',
data: {
"Query": JSON.stringify(Query) //change this
success: function() {}
});,
And array of Query :
0: {label: "abc:", value: "123", type: "Select"} 1: {label: "xyz", value: "Hum", type: "text"}
Can anyone help ?
2
Answers
Try something like this
I think something along this may work for you.
then in the controller
This will send an string with all the data in the array to the controller, then you turn string with json format into an object list