This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes JSF and the fly likes Configuring and using seam's convertEntity Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Configuring and using seam Watch "Configuring and using seam New topic
Author

Configuring and using seam's convertEntity

Felipe Reis
Greenhorn

Joined: Oct 31, 2007
Posts: 20
Hello everyone.

I'm trying to use the convertEntity tag from Jboss Seam in a <rich:comboBox> but I'm cannot manage to make it work.

I've read at the documentation that:
You must use Seam managed transactions (see Section 9.2, “Seam managed transactions”) with <s:convertEntity />.


So firstly I've worked on that... As I'm not using EJB and JTA transactions I've added this:

to my components.xml.

Then, I've inserted this

to my components.xml. I don't really understand why, but it was in the docs.

My .xhtml looks like this:


What I got as a result is a combobox that displays correctly, however, when I submit the form, I get the following error:

I assume that the value from the id is not being passed to the entity converter...

Has anyone had this problem before?



Felipe Reis
Greenhorn

Joined: Oct 31, 2007
Posts: 20
Actually, there is yet another problem. The displaying of the combobox is faulty too, it shows the id values instead of what is written in the label attribute...

Disappointing.
Dean Hiller
Greenhorn

Joined: Apr 07, 2003
Posts: 1
If you want that feature to work, go here and vote for this

https://jira.jboss.org/jira/browse/RF-5046

they are considering making a component that works like selectOneMenu. rich:comboBox does NOT work like selectOneMenu!!!
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Configuring and using seam's convertEntity