This is a migrated thread and some comments may be shown as answers.

Multiple grouping on specifying data source

1 Answer 2654 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Bill
Top achievements
Rank 1
Bill asked on 17 Nov 2011, 05:01 PM
var myDataSource = [{ firstname: 'me', lastname: 'you', Age: 5 }];
  
$('#grid')..kendoGrid({
 data: { 
             dataSource: myDataSource , 
              pageSize: 500 , 
              group: { field: ' firstname ' , dir: "asc" },
groupable: false,
columns:  [  {  field: 'firstname' , title: ''/* and so on */
});
I want to have groping on two columns for example on  firstname and then sub grouping on lastname when creating the grid. I know it is possible when the grouping is enabled and user can drag and drop multiple columns for nested groping, but I want to restrict the user from selecting himself and do the grouping on showing.
Maybe something like 
group: [{ field: ' firstname ' , dir: "asc" },{ field: ' lastname ' , dir: "asc" }]

1 Answer, 1 is accepted

Sort by
0
Bastian
Top achievements
Rank 1
answered on 04 Dec 2011, 11:02 PM
Bill,

It seems to be possible, see the example here http://jsfiddle.net/basmaat/SugMK/

Would be nice not to have the fieldname show up in the Hierarchy.

Cheers
Bas
Tags
Grid
Asked by
Bill
Top achievements
Rank 1
Answers by
Bastian
Top achievements
Rank 1
Share this question
or