displaytag - Nothing found to display.

View: New views
7 Messages — Rating Filter:   Alert me  

displaytag - Nothing found to display.

by Kris Reid :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi

I am using Struts2 with Display tag to display a List
Most of the time it works perfect but sometimes it displays the error "Nothing found to display"

This is not correct as I have the action class print out the List and it always is able to print the List.
I can usually hit refresh and it works fine. Sometimes it takes several refreshes.

Has anyone run into this?
Any ideas?

Cheers

Kris

Re: displaytag - Nothing found to display.

by Kris Reid :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

To add a little more information the the JSP looks like this

<display:table name="leads" class="table" id="leads" pagesize="100">
        <display:column property="id" sortable="true"/>
</display:table>

Cheers

Kris


Kris Reid wrote:
Hi

I am using Struts2 with Display tag to display a List
Most of the time it works perfect but sometimes it displays the error "Nothing found to display"

This is not correct as I have the action class print out the List and it always is able to print the List.
I can usually hit refresh and it works fine. Sometimes it takes several refreshes.

Has anyone run into this?
Any ideas?

Cheers

Kris

Re: displaytag - Nothing found to display.

by Kris Reid :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

The problem has something to do with the get method in the action class not being called.
Any ideas why this would happen?

If I hit refresh a time or two it works fine.



Re: displaytag - Nothing found to display.

by Oscar Calderón-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Kris Reid escribió:

> The problem has something to do with the get method in the action class not
> being called.
> Any ideas why this would happen?
>
> If I hit refresh a time or two it works fine.
>
>
>
>
> -----
> http://www.kremsoft.com Kremsoft - Software Development
>  
Are you using ajax tags (like dojo ) or something like that with displaytag?

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@...
For additional commands, e-mail: user-help@...


Re: displaytag - Nothing found to display.

by Kris Reid :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Oscar Calderón-2 wrote:
Are you using ajax tags (like dojo ) or something like that with displaytag?
No - haven't got any ajax or anything fancy

I seem to have found a work around
In the action class I stick the List into the request object
request.setAttribute("list", list);

And in the JSP
<display:table name="leads" class="table" id="request.list" pagesize="100">

Is their any reason why this should not be done?

Re: displaytag - Nothing found to display.

by Paul Benedict-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

You're attributes are wrong. Should be:

<display:table name="list" class="table" id="bean" pagesize="100">
</display:table>

@name is the name of your request attribute.
@id is the request attribute created at each the iteration.

Paul

On Fri, Nov 13, 2009 at 10:21 AM, Kris Reid <krisreid80@...> wrote:

>
>
>
> Oscar Calderón-2 wrote:
>>
>>
>> Are you using ajax tags (like dojo ) or something like that with
>> displaytag?
>>
>>
>>
>
> No - haven't got any ajax or anything fancy
>
> I seem to have found a work around
> In the action class I stick the List into the request object
> request.setAttribute("list", list);
>
> And in the JSP
> <display:table name="leads" class="table" id="request.list" pagesize="100">
>
> Is their any reason why this should not be done?
>
>
> -----
> http://www.kremsoft.com Kremsoft - Software Development
> --
> View this message in context: http://old.nabble.com/displaytag---Nothing-found-to-display.-tp26301323p26339226.html
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@...
> For additional commands, e-mail: user-help@...
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@...
For additional commands, e-mail: user-help@...


Re: displaytag - Nothing found to display.

by Kris Reid :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Whoops - made I typo whilst I was mucking around.
That's not the problem though


Paul Benedict-2 wrote:
You're attributes are wrong. Should be:

<display:table name="list" class="table" id="bean" pagesize="100">
</display:table>

@name is the name of your request attribute.
@id is the request attribute created at each the iteration.

Paul