Doh!  Didn't even think about that.  Thanks.

On 6/28/06, Julian Ray <[EMAIL PROTECTED]> wrote:
Couldn't you use a <h:outputText value="#{myBackingBean.....}}  /> and either (a) write out the whole _javascript_ or (b) just write out the array part?
 
 


From: Gregg Bolinger [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, June 28, 2006 1:38 PM

To: MyFaces Discussion
Subject: Re: Design Type Question

Thanks Julian.  *Unfortunately* I'm well adapt at _javascript_ so I already know how to do that.  What I don't know is how to populate _javascript_ arrays with data from my backing bean.

Aside from a custom component, I'd assume I need to do something like that.

Thanks.

On 6/28/06, Julian Ray <[EMAIL PROTECTED]> wrote:
Here is an example, I have not tested it but have used similar approaches
 
 
 


From: Gregg Bolinger [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, June 28, 2006 11:45 AM
To: MyFaces Discussion
Subject: Re: Design Type Question

Julian,

Thanks for the suggestions.  How would I go about populating _javascript_ values with data from the backing bean if I were to go with [1]?  Any links with this info?

Thanks.

On 6/28/06, Julian Ray <[EMAIL PROTECTED]> wrote:
Some suggestions
 
[1] Use client-side population of teh drop downs
[2] Use 2 backing beans, 1 for the drop down and 1 for the articles. Lazily load all getters. Use t:saveState to store the filter bean.
[3] Use Ajax


From: Gregg Bolinger [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, June 28, 2006 10:20 AM
To: MyFaces Discussion
Subject: Design Type Question

This isn't about MyFaces specifically so I apologize but this list is the best JSF resource I know of. ;)

I have a page that contains a list of Articles.  There are also filter criteria to filter the list of Articles.  The article list is a dataTable who's value is a method in the backing bean that returns a list of articles.  Simple enough.  So when the page first loads, I get all the articles.

The problem I am facing is part of the filter is 3 levels of categories.  Category, Sub Category, and a Sub Sub Category.  Each of these is a selectOneMenu and the child catagories depends on the parent category.  So I have valueChangeListeners registered so that when one drop down changes, the child dropdown gets new values.

The problem with this is that when this happens, my method to get the list of articles is called.  But I don't want this to happen until I click the Search button.  So I am just looking for solutions to solve this.

Thanks.



Reply via email to