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

[Solved] Subgrid for Master Details View

5 Answers 184 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Arun Prasath
Top achievements
Rank 1
Arun Prasath asked on 09 Aug 2010, 09:08 PM
I have a grid in which each row has some additional details in a one to man relationship. I want to put a plus sign in the first column of the row, and upon clicking it, a new subgrid opens up beneath that row, which shows its details grid.

To be able to do this, I am thinking of doing the following:

a) A plus sign button in the first column of each row.
a) A hidden row beneath each row. This row would have only one column and its colspan would span the entire table.
b) Upon clicking the plus sign, it would do two things: i) Show the hidden row ii) Use ajax to populate a new grid inside that row

Can anyone suggest how to implement this, or some better ways of achieving the same effect?

Thanks
Arun

5 Answers, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 10 Aug 2010, 09:40 AM
Hello Arun Prasath,

I think we have already implemented what you need:

Client hierarchy

Regards,
Atanas Korchev
the Telerik team
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 Public Issue Tracking system and vote to affect the priority of the items
0
Arun Prasath
Top achievements
Rank 1
answered on 17 Aug 2010, 06:56 AM
I have installed the latest sample files for this, but it is giving a javascript error on line 58 when the HierarchyAjax example is run.
0
Atanas Korchev
Telerik team
answered on 17 Aug 2010, 07:46 AM
Hello Arun Prasath,

 We are not aware of any JavaScript errors with the online example. Can you reproduce that error in our online demos?

Having said that there are known issues with having client-side templates in the nested grid when using ajax binding. We have fixed them and the hotfix will appear in the official release which is due at the end of this month.

Kind regards,
Atanas Korchev
the Telerik team
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 Public Issue Tracking system and vote to affect the priority of the items
0
Arun Prasath
Top achievements
Rank 1
answered on 19 Aug 2010, 01:21 PM
Hi,

Sorry for the javascript message. The issue was at my end after all, as it was not happening in your online demo.

However, another thing I noticed in online demo on this page http://demos.telerik.com/aspnet-mvc-beta/grid/hierarchyajax is that the sub-grid does not close once its opened.

By default, the top rows were expanded, which I could eliminate in the sample code by commenting out expandFirstRow() method call in script. However, in both the samples and online demo, a row once expanded, does not close back.

If I click the blue triangle next to "Nancy Davalio", which is first row in online demo, I see the whole main grid scroll back up, but the subgrid remains over layed on top of it. So the second row "Andrew Fuller" escapes from view, and comes behind the subgrid of orders by Nancy.

Clicking the rounded blue refresh button in left bottom does restore the grid properly back to its form, so this is not a show stopper. I'm using IE8 version 8.0.7600.

Thanks,
Arun
0
Atanas Korchev
Telerik team
answered on 19 Aug 2010, 01:24 PM
Hi Arun Prasath,

This is a known issue with IE8. We have already fixed that.

All the best,
Atanas Korchev
the Telerik team
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 Public Issue Tracking system and vote to affect the priority of the items
Tags
Grid
Asked by
Arun Prasath
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Arun Prasath
Top achievements
Rank 1
Share this question
or