You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Harish Krishnaswamy <hk...@comcast.net> on 2004/03/15 22:04:00 UTC

Table newbie!

My problem is the table data is not showing up, I see no exceptions 
either, simply a blank table with headers. Now to the details ...

I am using SimpleTableModel built from SimpleListTableDataModel and 
SimpleTableColumnModel. The SimpleTableColumnModel is built from a bunch 
of ExpressionTableColumns and one SimpleTableColumn that builds the 
column manually from the row value. There is exactly one row in the list 
passed to SimpleListTableDataModel and it doesn't show up. Any gotchas I 
need to know?

Thanks,
Harish



---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Table newbie!

Posted by Harish Krishnaswamy <hk...@comcast.net>.
Yes, that was strange, perhaps MindBridge can shed some light?

-Harish

Erik Hatcher wrote:

> I don't know exactly why things didn't show up without an error, but 
> the default state manager records page and sorting information into 
> the session.
>
>     Erik
>
>
> On Mar 15, 2004, at 4:38 PM, Harish Krishnaswamy wrote:
>
>> Ok, it had to do with the session state manager, although I have no 
>> idea why, yet. I set the session state manager to 
>> NullTableSessionStateManager and I see the data now. I am running 
>> stateless, is that why, I'll have to find out.
>>
>> -Harish
>>
>> Harish Krishnaswamy wrote:
>>
>>> My problem is the table data is not showing up, I see no exceptions 
>>> either, simply a blank table with headers. Now to the details ...
>>>
>>> I am using SimpleTableModel built from SimpleListTableDataModel and 
>>> SimpleTableColumnModel. The SimpleTableColumnModel is built from a 
>>> bunch of ExpressionTableColumns and one SimpleTableColumn that 
>>> builds the column manually from the row value. There is exactly one 
>>> row in the list passed to SimpleListTableDataModel and it doesn't 
>>> show up. Any gotchas I need to know?
>>>
>>> Thanks,
>>> Harish
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Table newbie!

Posted by Erik Hatcher <er...@ehatchersolutions.com>.
I don't know exactly why things didn't show up without an error, but 
the default state manager records page and sorting information into the 
session.

	Erik


On Mar 15, 2004, at 4:38 PM, Harish Krishnaswamy wrote:

> Ok, it had to do with the session state manager, although I have no 
> idea why, yet. I set the session state manager to 
> NullTableSessionStateManager and I see the data now. I am running 
> stateless, is that why, I'll have to find out.
>
> -Harish
>
> Harish Krishnaswamy wrote:
>
>> My problem is the table data is not showing up, I see no exceptions 
>> either, simply a blank table with headers. Now to the details ...
>>
>> I am using SimpleTableModel built from SimpleListTableDataModel and 
>> SimpleTableColumnModel. The SimpleTableColumnModel is built from a 
>> bunch of ExpressionTableColumns and one SimpleTableColumn that builds 
>> the column manually from the row value. There is exactly one row in 
>> the list passed to SimpleListTableDataModel and it doesn't show up. 
>> Any gotchas I need to know?
>>
>> Thanks,
>> Harish
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Table newbie!

Posted by Harish Krishnaswamy <hk...@comcast.net>.
Ok, it had to do with the session state manager, although I have no idea 
why, yet. I set the session state manager to 
NullTableSessionStateManager and I see the data now. I am running 
stateless, is that why, I'll have to find out.

-Harish

Harish Krishnaswamy wrote:

> My problem is the table data is not showing up, I see no exceptions 
> either, simply a blank table with headers. Now to the details ...
>
> I am using SimpleTableModel built from SimpleListTableDataModel and 
> SimpleTableColumnModel. The SimpleTableColumnModel is built from a 
> bunch of ExpressionTableColumns and one SimpleTableColumn that builds 
> the column manually from the row value. There is exactly one row in 
> the list passed to SimpleListTableDataModel and it doesn't show up. 
> Any gotchas I need to know?
>
> Thanks,
> Harish
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Table newbie!

Posted by Harish Krishnaswamy <hk...@comcast.net>.
Thanks Mindbridge! Yes I see how, now! The Table component has so many 
possibilities that some of these easily go unnoticed. Oh BTW did I 
mention this component rocks!

-Harish

Mindbridge wrote:

>Hi Harish,
>
>I think it should be okay to use source/columns in your case. You can do it
>in two ways even:
>
>1) 'columns' can accept (besides a string) a column model or a list of
>ITableColumn objects. You can pass the SimpleTableColumnModel you have
>there, no problem. I believe that should do exactly what you are doing now.
>
>2) You can define the columns also by using a string (as in most current
>examples). For the special column you can create a xxxxColumnValue block
>that defines how that column should look. In there you can have a Foreach
>that goes through the list, etc.
>You can access the row object either by using the 'row' binding or by the
>ognl expression 'components.table.tableRow' (assuming you use Table. you can
>do the same if you use TableRows)
>Also, if you want this column not to be associated with an OGNL expression
>and thus make it non-sortable, just prepend its name with '!' in the
>description string you pass to 'columns'
>
>  
>
>>On a related topic, is it possible to build a grouped-report with
>>breaks?
>>    
>>
>
>The easiest way to do that, I guess, is to render Col3 using a Block and a
>Foreach, so that items in the list are separated by <br> or sth like that,
>and set valign for the table to be 'top' so that the other columns align in
>the way you want them. That should achieve it, I think.
>
>-mb
>
>----- Original Message ----- 
>From: "Harish Krishnaswamy" <hk...@comcast.net>
>To: "Tapestry users" <ta...@jakarta.apache.org>
>Sent: Tuesday, March 16, 2004 12:20 AM
>Subject: Re: Table newbie!
>
>
>  
>
>>The problem is, I have to build one of the columns from a nested list of
>>data. So each row value has a list attribute that will have to read and
>>build a string. I didn't seem to find a way to make this work with the
>>simpler approach.
>>
>>On a related topic, is it possible to build a grouped-report with
>>breaks? So in the above case, suppose I wanted to display the nested
>>list data as a group. Something like ...
>>
>>Col1 Col2 Col3
>>          Col3
>>          Col3
>>          Col3
>>Col1 Col2 Col3
>>          Col3
>>          Col3
>>          Col3
>>
>>-Harish
>>
>>Mindbridge wrote:
>>
>>    
>>
>>>Hi Harish,
>>>
>>>Just to ask: have you considered using the 'source' and 'columns'
>>>      
>>>
>bindings
>  
>
>>>to provide the data and columns instead of the 'tableModel' binding? This
>>>combination tends to be much simpler to use and diagnose if something
>>>      
>>>
>goes
>  
>
>>>wrong, and yet covers about 90% of the cases people have.
>>>
>>>
>>>----- Original Message ----- 
>>>From: "Harish Krishnaswamy" <hk...@comcast.net>
>>>To: "Tapestry users" <ta...@jakarta.apache.org>
>>>Sent: Monday, March 15, 2004 11:04 PM
>>>Subject: Table newbie!
>>>
>>>
>>>
>>>
>>>      
>>>
>>>>My problem is the table data is not showing up, I see no exceptions
>>>>either, simply a blank table with headers. Now to the details ...
>>>>
>>>>I am using SimpleTableModel built from SimpleListTableDataModel and
>>>>SimpleTableColumnModel. The SimpleTableColumnModel is built from a bunch
>>>>of ExpressionTableColumns and one SimpleTableColumn that builds the
>>>>column manually from the row value. There is exactly one row in the list
>>>>passed to SimpleListTableDataModel and it doesn't show up. Any gotchas I
>>>>need to know?
>>>>
>>>>Thanks,
>>>>Harish
>>>>
>>>>
>>>>
>>>>---------------------------------------------------------------------
>>>>To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>>>For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>>>
>>>>
>>>>        
>>>>
>>>---------------------------------------------------------------------
>>>To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>>For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>>
>>>
>>>
>>>
>>>      
>>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>    
>>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
>  
>

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Table newbie!

Posted by Mindbridge <mi...@yahoo.com>.
Hi Harish,

I think it should be okay to use source/columns in your case. You can do it
in two ways even:

1) 'columns' can accept (besides a string) a column model or a list of
ITableColumn objects. You can pass the SimpleTableColumnModel you have
there, no problem. I believe that should do exactly what you are doing now.

2) You can define the columns also by using a string (as in most current
examples). For the special column you can create a xxxxColumnValue block
that defines how that column should look. In there you can have a Foreach
that goes through the list, etc.
You can access the row object either by using the 'row' binding or by the
ognl expression 'components.table.tableRow' (assuming you use Table. you can
do the same if you use TableRows)
Also, if you want this column not to be associated with an OGNL expression
and thus make it non-sortable, just prepend its name with '!' in the
description string you pass to 'columns'

> On a related topic, is it possible to build a grouped-report with
> breaks?

The easiest way to do that, I guess, is to render Col3 using a Block and a
Foreach, so that items in the list are separated by <br> or sth like that,
and set valign for the table to be 'top' so that the other columns align in
the way you want them. That should achieve it, I think.

-mb

----- Original Message ----- 
From: "Harish Krishnaswamy" <hk...@comcast.net>
To: "Tapestry users" <ta...@jakarta.apache.org>
Sent: Tuesday, March 16, 2004 12:20 AM
Subject: Re: Table newbie!


> The problem is, I have to build one of the columns from a nested list of
> data. So each row value has a list attribute that will have to read and
> build a string. I didn't seem to find a way to make this work with the
> simpler approach.
>
> On a related topic, is it possible to build a grouped-report with
> breaks? So in the above case, suppose I wanted to display the nested
> list data as a group. Something like ...
>
> Col1 Col2 Col3
>           Col3
>           Col3
>           Col3
> Col1 Col2 Col3
>           Col3
>           Col3
>           Col3
>
> -Harish
>
> Mindbridge wrote:
>
> >Hi Harish,
> >
> >Just to ask: have you considered using the 'source' and 'columns'
bindings
> >to provide the data and columns instead of the 'tableModel' binding? This
> >combination tends to be much simpler to use and diagnose if something
goes
> >wrong, and yet covers about 90% of the cases people have.
> >
> >
> >----- Original Message ----- 
> >From: "Harish Krishnaswamy" <hk...@comcast.net>
> >To: "Tapestry users" <ta...@jakarta.apache.org>
> >Sent: Monday, March 15, 2004 11:04 PM
> >Subject: Table newbie!
> >
> >
> >
> >
> >>My problem is the table data is not showing up, I see no exceptions
> >>either, simply a blank table with headers. Now to the details ...
> >>
> >>I am using SimpleTableModel built from SimpleListTableDataModel and
> >>SimpleTableColumnModel. The SimpleTableColumnModel is built from a bunch
> >>of ExpressionTableColumns and one SimpleTableColumn that builds the
> >>column manually from the row value. There is exactly one row in the list
> >>passed to SimpleListTableDataModel and it doesn't show up. Any gotchas I
> >>need to know?
> >>
> >>Thanks,
> >>Harish
> >>
> >>
> >>
> >>---------------------------------------------------------------------
> >>To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> >>For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
> >>
> >>
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> >For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
> >
> >
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Table newbie!

Posted by Harish Krishnaswamy <hk...@comcast.net>.
The problem is, I have to build one of the columns from a nested list of 
data. So each row value has a list attribute that will have to read and 
build a string. I didn't seem to find a way to make this work with the 
simpler approach.

On a related topic, is it possible to build a grouped-report with 
breaks? So in the above case, suppose I wanted to display the nested 
list data as a group. Something like ...

Col1 Col2 Col3
          Col3
          Col3
          Col3
Col1 Col2 Col3
          Col3
          Col3
          Col3

-Harish

Mindbridge wrote:

>Hi Harish,
>
>Just to ask: have you considered using the 'source' and 'columns' bindings
>to provide the data and columns instead of the 'tableModel' binding? This
>combination tends to be much simpler to use and diagnose if something goes
>wrong, and yet covers about 90% of the cases people have.
>
>
>----- Original Message ----- 
>From: "Harish Krishnaswamy" <hk...@comcast.net>
>To: "Tapestry users" <ta...@jakarta.apache.org>
>Sent: Monday, March 15, 2004 11:04 PM
>Subject: Table newbie!
>
>
>  
>
>>My problem is the table data is not showing up, I see no exceptions
>>either, simply a blank table with headers. Now to the details ...
>>
>>I am using SimpleTableModel built from SimpleListTableDataModel and
>>SimpleTableColumnModel. The SimpleTableColumnModel is built from a bunch
>>of ExpressionTableColumns and one SimpleTableColumn that builds the
>>column manually from the row value. There is exactly one row in the list
>>passed to SimpleListTableDataModel and it doesn't show up. Any gotchas I
>>need to know?
>>
>>Thanks,
>>Harish
>>
>>
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>    
>>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
>  
>

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Table newbie!

Posted by Mindbridge <mi...@yahoo.com>.
Hi Harish,

Just to ask: have you considered using the 'source' and 'columns' bindings
to provide the data and columns instead of the 'tableModel' binding? This
combination tends to be much simpler to use and diagnose if something goes
wrong, and yet covers about 90% of the cases people have.


----- Original Message ----- 
From: "Harish Krishnaswamy" <hk...@comcast.net>
To: "Tapestry users" <ta...@jakarta.apache.org>
Sent: Monday, March 15, 2004 11:04 PM
Subject: Table newbie!


> My problem is the table data is not showing up, I see no exceptions
> either, simply a blank table with headers. Now to the details ...
>
> I am using SimpleTableModel built from SimpleListTableDataModel and
> SimpleTableColumnModel. The SimpleTableColumnModel is built from a bunch
> of ExpressionTableColumns and one SimpleTableColumn that builds the
> column manually from the row value. There is exactly one row in the list
> passed to SimpleListTableDataModel and it doesn't show up. Any gotchas I
> need to know?
>
> Thanks,
> Harish
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org