This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes JSF and the fly likes Search data in datatable and access right page. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Search data in datatable and access right page." Watch "Search data in datatable and access right page." New topic
Author

Search data in datatable and access right page.

Adrien Gracia
Greenhorn

Joined: Apr 05, 2006
Posts: 1
Hi
I am developping a small app and I have a requirement that I do not know how to do.
BTW, I am really new with JSF

So, let's talk business and market data.
I have a query that returns me a message and I display that message in a table.
I am recreating the book for the actual contract that I am searching for.
One bean contains one message and each page that I will display represents a message.
So now lets say that I have 10 messages returned from the query, this means taht I will have 10 pages available.
I used datatable to represent my data and datascroller for pagination.

Here is what I am trying to do.
Since all these pages represent the market state, a lot of prices are available.
On the same page I have a search button that returns on the same page the pages where a price entered as input is found.
So far I was able to do that.
Now that I have all the pages available on screen, I want to be able to click on one of the page and jump to the right page. That is the piece that I do not knwo how to do.

Here is what I have so far in my JSP

Any suggestion is welcome.
Thanks

(I use tomahawk for extended funcionality)



My table is contructed using a dataTable and having a dataModel on the backend.

So imagine that the table is contructed and have a datascroller for pagination.

At the bottom of the page you a search option that would allow you to find an information taht could be repeated in multiple pages.
The result would tell you the page(s) number where to find that information, and by clicking on the page number it would jump straight to that page.

I have a solution but it is a TERRIBLE HACK.
I looked how the datascroller was contructed in the html page. It is using a couple java scripts

In my code I reuse the syntax by just adding the page number.
It works but it is terribly ugly. I am using the newspapertable
here is the code

Same thread in JAVA FORUM with the code that I have that I could not insert here

JSF java Forum
 
Consider Paul's rocket mass heater.
 
subject: Search data in datatable and access right page.
 
Similar Threads
Pagination
Pagination
commandLink with <rich:dataTable>, problem in pagination
PAGINATION
pagination with tomahawks dataScroller