Declined
Last Updated: 03 Dec 2021 10:06 by ADMIN
Russell
Created on: 18 Dec 2015 15:32
Category: MVVM
Type: Feature Request
5
Add Kendo grid MVVM binding for selected items
When the Kendo Grid is bound using MVVM, add a 2-way 'value' binding which tracks the data items for selected rows.

The new binding should have the following features:
•	Support a 'value' binding on the observable model: 
<div data-role="grid" data-bind="source: someDatasource, value: selectedItems" ...>
•	Support multiple select mode using an array binding, or single select mode using a single dataItem.
•	2-way binding (update grid selection when the bound value is changed; update bound value when grid selection is changed) 
This new feature will make it easier to handle two use cases (which are both super common) when using MVVM:
•	Implement a checkbox column to control selected rows
•	Implement another MVVM component which wants to take some action based on the currently-selected grid item(s)

Here is an example of a partial solution that somebody else implemented:
http://www.telerik.com/forums/mvvm-binding-for-grid-selected-row

The custom binding that Atanas posted only supports single-row selection mode. It is also model-dependent and (I think) uni-drectional.
1 comment
ADMIN
Ianko
Posted on: 03 Dec 2021 10:06

Hello,

The Grid does not natively support value binding. This is why this can be accomplished only by using a custom binder dedicated for the specific application needs. Similar to the one shown in the forum thread linked.

Regards,
Ianko
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.