I want to open a kendo window with the data from a grid on the same page. I've done this with single selected items, but not with the list of items in the grid.
What's the proper method to serialize the data?
Here is some code
controller
public
PartialViewResult WindowPartialView(IEnumerable<MyGridModel> models)
return
PartialView(models);
}
in window
.LoadContentFrom(
"WindowPartialView"
,
"MyController"
)
function
openPlacardWindow() {
debugger;
var
grid = $(
"#MyGrid"
).data(
"kendoGrid"
);
var
gridData = grid.dataSource.data();
var
win = $(
'#myWindow'
).data(
"kendoWindow"
);
win.refresh({ data: gridData }); //not correct
win.center();
win.open();
}