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

Multi level Radgrid with aggregates expansion issues

3 Answers 50 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
David
Top achievements
Rank 1
Iron
Veteran
Iron
David asked on 12 May 2014, 05:47 PM

I have a fairly complex page which consists of a RadGrid along with several levels of nested views along with various nested tabs, grids, and such.  While things are currently functional, they are not what is desired and I am looking for some pointers on where to go from where I am.

Currently my situation consists of the following "levels":

Level 0 - Grand Totals By Business Entity
Level 1 - Expenses Summary
Level 1 - Revenue Summary
Level 1 - HTML PIE Chart showing breakdown of overall
Level 2 - Detail Summary grouped into fixed categories
Level 3 - Per Item Detailing items represented by level 2 summary. (User insert/update/delete allowed)
Level 3 - Supporting file attachments via AsyncUpload control. (User insert/delete allowed)

Each represents a level of nesting of data.  Level zero being the topmost summary level.  Each level has a header/footer with aggregation used to produce totals.  Level 1 consists of a RadTabStrip with two RadGrids and one RadHtmlChart Pie Chart.  Level 2 has a summary grid.  Level 3 is where actual user entry occurs.

From my end users perspective, they want to keep the expanded details expanded, and their totals get updated when they insert/update/delete new items.  I seem to be able to either keep things expanded OR update the totals.  When I attempt to do both, I end up with collapsed summaries. 

Everything is server side and business object based.  All databinding is down via NeedsDataSource type binding or explicit binding on the "expanded" action command.

As I now have things my detail levels stay open and my filters are preserved.  The totals are not updated until the users select a "refresh" button and a given detail level.  This results in all child levels collapsing but they get their totals updated while preserving their filters.

I have tried all kinds of ideas from adding logic to track grouping/expanded items, to using the RadPersistanceManager process.  I suspect that I am over thinking my problem.  Does anyone have any pointers on arriving at a solution which keeps the detail/group levels in their current state while also updating the summary totals on the parent levels???

Your suggestions would be appreciated.

3 Answers, 1 is accepted

Sort by
0
Viktor Tachev
Telerik team
answered on 15 May 2014, 11:09 AM
Hello David,

Please note that the Update command for RadGrid calls Rebind() implicitly. Also the items in the grid are collapsed when it is rebound.

In order to change this behavior you could use the RetainExpandStateOnRebind property. Try setting it to true and the expanded state of the RadGrid items should be persisted.


Regards,
Viktor Tachev
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
David
Top achievements
Rank 1
Iron
Veteran
Iron
answered on 15 May 2014, 03:16 PM
I love it.  A property that I did not know exists. 

After testing I still do not get the results desired.  While this is definitely a step forward.  The problem I now have is that the grids on levels 1 (and higher) are unrelated grids.  That is to say no relationships exist in markup (I could not figure out how to relate independent data sources).  Yes the two are related but not in markup.

With your new property I now get expanded grids with no content.  I will work toward keeping them populated.
0
Viktor Tachev
Telerik team
answered on 20 May 2014, 09:36 AM
Hello David,

If you would like to define hierarchy relations in the RadGrid markup you would find this demo interesting. Try using the approach there and you should be able to achieve the behavior you are looking for.

Alternatively you could use programmatic hierarchy binding as illustrated in the Programmatic Hierarchy Binding demo.

Regards,
Viktor Tachev
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
General Discussions
Asked by
David
Top achievements
Rank 1
Iron
Veteran
Iron
Answers by
Viktor Tachev
Telerik team
David
Top achievements
Rank 1
Iron
Veteran
Iron
Share this question
or