9 results for technology, jsf...

Loop Index in ui:repeat

posted by Jake on

Sometimes it's useful to know what the invariant value is for your loop within a facelets loop. I use ui:repeat a lot, but have seen some problems with it in the past. If you want to get the loop index for your ui:repeat, you may be disappointed. Basically, it requires that you use a different looping mechanism. A nice alternative is the a4j:repeat, which offers the same functionality, plus more awesomeness...

Create Custom Facelets Component

posted by Jake on

Facelets is a great addition to jsf. It is very extensible, and it makes creating custom components even easier. It's fantastic. This is almost TOO easy. If you have a pile of view markup and/or client-side logic, then this is a good option. And by good, I mean awesome.

JSF ValidationError with Custom Converters

posted by Jake on

Here's an important tidbit... JSF does not give any default validators for your data if you use a custom converter. If you're getting a ValidationError exception, overriding equals and hashcode methods might be a good idea. For more, read on...

JSF Modal Goodness

posted by Jake on

Meet the new web. The simpler the better. The cleaner the better. The more pleasing the colors the better. The fuzzier feelings the better. The latest fuzzies have been brought on by a slew of modals. Previously, we haven't used many modals in our layouts and designs, so here's the first working pattern on how to get this kind of stuff working.

This solution allows:


  • Content to appear in a modal

  • Validation errors post back to the modal

  • Edits made in a modal persist back to the database

  • Success messages appear on parent page

Null SelectItem Option

posted by Jake on

Sometimes it's desirable to be able to have a null or "none of these" option for a dropdown. I've gotten tripped up on the syntax a couple times and have found enough variance in "solutions" listed on forums that I'll just add to the mix and record what works well for me here.

Id's from JSF, used in jQuery

posted by Jake on

For our view layer on our current project at work, we use JSF/Facelets + some jQuery goodness. I have found that at some times these two tech's have a hard time working with each other. I ocassionally have problems with the id's. Here's a nice little way to guarantee you id's are awesome.