CRUD Kendo、批量更新网格 return 数据空
CRUD Kendo, Batch Update Grid return data null
我有这个架构,
schema: {
data: "d.Data", // web methods return JSON in the following format { "d": <result> }. Specify how to get the result.
total: "d.Total",
model: {
在运输中:
update: {
url: "VisorEuroProv.aspx/Update", //specify the URL which should create new records. This is the Create method of the Products.asmx service.
contentType: "application/json; charset=utf-8", // tells the web method to serialize JSON
type: "POST" //use HTTP POST request as the default GET is not allowed for web methods
//complete: function(e) { $("#grid").data("kendoGrid").dataSource.read()}
},
和 WebMethod
[WebMethod]
public static void Update(IEnumerable<dtoVisorEuroProveedores> dtoVisorEuroProveedores)
{...}
更新工作正常,但未关闭 BatchEdit,显示 javascript 错误:未捕获类型错误:无法读取 属性 'Data' of null
最后我 return 一个 IEnumerable< myObject >
变量的 List() 。
我有这个架构,
schema: {
data: "d.Data", // web methods return JSON in the following format { "d": <result> }. Specify how to get the result.
total: "d.Total",
model: {
在运输中:
update: {
url: "VisorEuroProv.aspx/Update", //specify the URL which should create new records. This is the Create method of the Products.asmx service.
contentType: "application/json; charset=utf-8", // tells the web method to serialize JSON
type: "POST" //use HTTP POST request as the default GET is not allowed for web methods
//complete: function(e) { $("#grid").data("kendoGrid").dataSource.read()}
},
和 WebMethod
[WebMethod]
public static void Update(IEnumerable<dtoVisorEuroProveedores> dtoVisorEuroProveedores)
{...}
更新工作正常,但未关闭 BatchEdit,显示 javascript 错误:未捕获类型错误:无法读取 属性 'Data' of null
最后我 return 一个 IEnumerable< myObject >
变量的 List() 。