I have just run into a problem that I think is probably a bug, but may
be something that I am doing wrong. It's definitely a showstopper in my
app, though.
I have a component that allows users to rate something via the normal
kind of "stars" rating. After a user clicks a star the overall rating
of the object is calculated and displayed as a graphic. I use a
component that employs an asynchronous DirectLink to do this, with each
star having a different value on submit, and it works quite nicely. I
have this custom component on two different pages and I can submit
ratings on both.
However, I just added pagination, and as soon as you move off of the
home page via the "next" pagination link, the DirectLink for ratings no
longer returns anything. The pagination works using the standard kind of
"start from" parameter, which calls a listener that simply does
setStartFrom(int startFrom) and then lets the pageBeginRender() method
calculate the objects to display.
I do know the reason that the ratings no longer show the updated
graphic--the AjaxResponse just returns empty tags, with no errors
reported at all (had a look at this with firebug):
<ajax-response></ajax-response>
The actual link is firing just fine, and all of the server side
processing happens as my logs show. It's just that the ajax response is
empty when it should include new HTML for the <div>s to be updated. It
seems like there is some kind of setup that happens when you go directly
to Home.html and click the rating link, but not when I've gone to the
home page via a DirectLink. I cannot see what would be different, since
my pageBeginRender() method is called, and everything else happens just
like it should in the component and in the page.
If anyone has run into this before or has an idea regarding what this
might cause an async DirectLink to return nothing in some cases, please
let me know. The pagination is a major part of my app, and users need
to be able to submit ratings no matter which page they are on, so I am
kind of dead in the water until I get this fixed. Next step is to spend
quality time with the source code, but if anyone has a better idea
before I take that time...
Cheers,
Matt
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]