• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Cell Widget Table in GWT 2.1.0 with expanded/collapsed rows

 
ivan stefko
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I would like to create table in GWT 2.1.0 with expand/collapse rows (more than one column... ). Something like http://code.google.com/p/plechacik/updates/list but with more columns. Could you give me some advice how to?

thanks,
 
Maneesh Godbole
Saloon Keeper
Posts: 11021
12
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can add widgets to table cells.
Tree is a widget. So is a disclosure panel.

 
ivan stefko
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maneesh Godbole wrote:You can add widgets to table cells.
Tree is a widget. So is a disclosure panel.


tree is a widget but represents only one column. i need table with 5 columns ... . I can use disclosurePanel and add this widget to table cells but there is another question: how can I assecurate that column width will be dynamical (according to context width) for each row??
 
Maneesh Godbole
Saloon Keeper
Posts: 11021
12
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Im a bit confused in understanding what exactly you are trying to do here.
In the link you provided, I already see multiple columns.Date, ID, Some stuff, commiter, some other stuff.
 
ivan stefko
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maneesh Godbole wrote:Im a bit confused in understanding what exactly you are trying to do here.
In the link you provided, I already see multiple columns.Date, ID, Some stuff, commiter, some other stuff.

yeah.. may be bad example - this example should demonstrated collapse/expand rows. Is hard to say in this example if there are multiple columns or there are only one column because there isn't table header.
 
Maneesh Godbole
Saloon Keeper
Posts: 11021
12
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Looks like your requirement is like this:
1) You got data which has multiple attributes
2) These attributes need to be displayed as columns
3) Some of the attribute values can translate to heavy data.
4) You want to optimize the user experience so its fast.
5) One way of optimizing is fetching and displaying data only when required

Is this correct? If yes, my initial suggestion still holds true. You can display data in a tabular format with headers and all. To load and display heavy data at runtime, use a tree or a disclosure panel or even a lazy loading panel.

If this is not what you had in mind, please tell us what exactly you are trying to do.

PS. In the link you provided, incorporating headers is not that difficult. Just make them the first row of your table.
 
Nilesh Pat
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi ivan,
try PagingScrollTable

use the link below
http://collectionofdemos.appspot.com/demo/com.google.gwt.gen2.demo.scrolltable.PagingScrollTableDemo/PagingScrollTableDemo.html


http://collectionofdemos.appspot.com/javadoc/index.html?com/google/gwt/gen2/table/client/PagingScrollTable.html

this table gives you a lot of functionality you might wanted to.

may be you have to use external library. com.google.gwt.gen2.table

It's little bit tricky library. But you can make your custom PagingScrollTable using it as you required.
 
ivan stefko
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maneesh Godbole wrote:Looks like your requirement is like this:
1) You got data which has multiple attributes
2) These attributes need to be displayed as columns
3) Some of the attribute values can translate to heavy data.
4) You want to optimize the user experience so its fast.
5) One way of optimizing is fetching and displaying data only when required

Is this correct? If yes, my initial suggestion still holds true. You can display data in a tabular format with headers and all. To load and display heavy data at runtime, use a tree or a disclosure panel or even a lazy loading panel.

If this is not what you had in mind, please tell us what exactly you are trying to do.

PS. In the link you provided, incorporating headers is not that difficult. Just make them the first row of your table.


yeah.. requirements are OK. what i'm looking for is solution for fllowing... .

i have this simple example:


this is only table with data without expanded/colpased rows. So i need to add this functionality to this table and i don't know how.
I would like to use DisclosurePanel (if it is possible in this case) for it. So it means that i need define another column - which one/which kind of type?

Smth like this:



and next question is how can i achieve will be expanded throught all columns in table = colspan in HTML.

thanks

 
ivan stefko
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
or is there any possibility how can i use CellTree for it? CellTree is OK - because there is expand/collapse functionality, but there is only one 'column'...

for better demonstration this is what i exactly want:

http://dev.sencha.com/playpen/gxt/gridplugins/ - first table ... . In this case there is some external jar ... . I need to do it in GWT 2.1.0 (celltable, cellTree ... )

i.
 
ivan stefko
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
anybody?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic