简体   繁体   English

如何将选定的剑道网格行绑定到MVC中的另一个剑道网格

[英]How to bind selected kendo grid rows to another kendo grid in mvc

我在弹出窗口中有一个带有复选框选项的剑道网格,在主视图中还有一个空的剑道网格。我需要的是将网格1中的选定复选框行绑定到mvc中的空剑道网格

Check the following post, which discusses a similar scenario: 检查以下文章,其中讨论了类似的情况:

https://stackoverflow.com/a/38707214/3086237 https://stackoverflow.com/a/38707214/3086237

Even if you are not using the built-in selection feature, the core step is to retrieve a collection of the checked/selected rows in the first Grid via the dataItem method and push them to an array. 即使您没有使用内置的选择功能,核心步骤也是通过dataItem方法在第一个Grid中检索已选中/选中的行的集合,并将其推到数组中。 Then, assign the array to the second Grid's dataSource instance. 然后,将该数组分配给第二个Grid的dataSource实例。

An important note - the first Grid should use Ajax binding , otherwise there are no client-side data item instances. 重要说明-第一个Grid应该使用Ajax绑定 ,否则没有客户端数据项实例。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM