I am having trouble getting the grid save function to work with a WebMethod. The short version of the code:
transport: {
:
:
update: {
url: crudServiceBaseUrl + "/Update",
contentType: 'application/json; charset=utf-8',
dataType: "json",
type: 'POST'
},
parameterMap: function (data, operation)
{
if (operation !== "read" && data.models)
{
return JSON.stringify({ JSONparam: data.models });
}
}
My server side code:
[WebMethod()]
static List<bool> Update(string JSONparam)
{
List<bool> boolList = new List<bool>();
:
:
return boolList;
}
The server side code is never called. What should the "update" section of the transport look like? I probably have it wrong.
transport: {
:
:
update: {
url: crudServiceBaseUrl + "/Update",
contentType: 'application/json; charset=utf-8',
dataType: "json",
type: 'POST'
},
parameterMap: function (data, operation)
{
if (operation !== "read" && data.models)
{
return JSON.stringify({ JSONparam: data.models });
}
}
My server side code:
[WebMethod()]
static List<bool> Update(string JSONparam)
{
List<bool> boolList = new List<bool>();
:
:
return boolList;
}
The server side code is never called. What should the "update" section of the transport look like? I probably have it wrong.