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

How to use cascading dropdown in kendo grid batch editing

5 Answers 458 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Senthilkumar
Top achievements
Rank 1
Senthilkumar asked on 22 Jun 2015, 02:17 PM

Hi Team,

Please provide the sample code for kendo grid  cascading drop down using model. 

And also please share, how to get the entire source(all rows of existing grid) of grid.

 

Thanks

Senthilkumar N

5 Answers, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 25 Jun 2015, 05:57 AM
Hello Senthilkumar,

One cannot use cascading dropdowns during in cell editing mode because only one cell can be in edit mode at a time. This means that only one dropdown will be visible.

We have a demo which shows how to use cascading dropdowns in inline and popup editing mode.

One can get the entire data source of the grid by using its dataSource field. Have in mind though that it contains only the current page of data unless the ServerOperation option of the data source is set to false.

Here is how to do that:

@(Html.Kendo().Grid<MyModel>()
             .Name("grid")
            /* other configuration */          
)

<script>
var grid  = $("#grid").data("kendoGrid");
var dataItems = grid.dataSource.data();
</script>

Regards,
Atanas Korchev
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Senthilkumar
Top achievements
Rank 1
answered on 25 Jun 2015, 07:57 AM

Thank you for response.

 But when we try to use inline edit grid, grid excepting us to save in database or session to maintain every row after update in grid row. 

 otherwise we facing below this issue "0x800a138f - JavaScript runtime error: Unable to get property 'uid' of undefined or null reference". but in batch editing this is possible. 

So please provide some custom code to fix cascading drop down issue in batch editing. 

 

Thanks 

Senthilkumar N

0
Atanas Korchev
Telerik team
answered on 25 Jun 2015, 08:06 AM
Hi,

As I said in my previous response using cascading dropdownlists in batch editing mode isn't possible because only one cell is in edit mode at a time.

Regards,
Atanas Korchev
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Senthilkumar
Top achievements
Rank 1
answered on 25 Jun 2015, 08:10 AM

Hi 

Here i found one sample for cascading drop down in In cell editing. Please confirm this is valid one.

https://github.com/telerik/ui-for-aspnet-mvc-examples/blob/master/grid/grid-incell-editing-with-cascading-dropdownlist/KendoUIMVC5/Views/Home/Index.cshtml

 

0
Atanas Korchev
Telerik team
answered on 25 Jun 2015, 08:53 AM
Hello,

This project implements manual cascading. Again only one dropdownlist is visible at a time. It shows how to use the values of the other columns to filter the current dropdownlist. If this is what you need then yes this project is a valid one.

Regards,
Atanas Korchev
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Grid
Asked by
Senthilkumar
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Senthilkumar
Top achievements
Rank 1
Share this question
or