Vgo Software

« NEOS on the news! | Main | ADF Release 2 - Problem Clearing Cache Resolved »
Monday
Jun182012

A Better ADF Search Page - A Couple Tips and Tricks

In a recent ADF project we have been working on, another Forms Modernization, the client wanted to change our normal search page to improve the amount of real-estate dedicated to the returned results.  We determined that it would help if the search component collapsed upon a successful search and originally that the header and footers on our pages collapsed also.

Using the ADF Search Component, a pageFlowScope bean, and some partial page triggers, this was very easy to accomplish.

First, create a PageFlowScope bean to hold the value and to adjust it when a search was made.  This is a simple POJO with a boolean attribute, the default value for the boolean, we called "showSearch" should be set to true.

Add the bean to the taskflow as a PageFlowScope bean.

Next change the disclosed attribute of the page's query component to be based on that showSearch attribute.  Update the partialTriggers on the query component to be itself.

There are probably many ways to accomplish determining if there are search results after a search and updating the bean's value; our solution was to create a processQuery method in the bean, have the bean call the default processQuery operation, then check to see if the View has a first row or not.  If it does have a first row, change the value of showSearch to be "false".

PrintView Printer Friendly Version

EmailEmail Article to Friend

References (2)

References allow you to track sources for this article, as well as articles that were written in response to this article.
  • Response
    Response: essays in time
    These tips are so much helpful for as I was searching for it since long. I am really thankful to you for giving such informative guidelines and I would appreciate you to do works such like that.
  • Response
    Java-Hair - Articles - A Better ADF Search Page - A Couple Tips and

Reader Comments

There are no comments for this journal entry. To create a new comment, use the form below.

PostPost a New Comment

Enter your information below to add a new comment.

My response is on my own website »
Author Email (optional):
Author URL (optional):
Post:
 
Some HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>