-
1. Re: entity names in dropdowns?
dsailer.d.sailer.comcast.net Mar 25, 2009 8:41 PM (in response to seamn00bz)what does your UI code look like? THere are s:selectItems examples in the seam example/ui project.
-
2. Re: entity names in dropdowns?
swd847 Mar 26, 2009 3:34 AM (in response to seamn00bz)You have to create a custom converter for each entity and use it instead of s:convertEntity. It may also be possible to take the convertEntity code and create your own one based on it, but with encyption on the class name.
-
3. Re: entity names in dropdowns?
seamn00bz Mar 26, 2009 7:43 AM (in response to seamn00bz)I used the example
-
4. Re: entity names in dropdowns?
seamn00bz Mar 26, 2009 7:43 AM (in response to seamn00bz)Thank you.. any idea how to do that? :-)
-
5. Re: entity names in dropdowns?
dsailer.d.sailer.comcast.net Mar 26, 2009 2:19 PM (in response to seamn00bz)I just use <s:convertEntity /> and it works. I'm assuming it uses getId() by default. Otherwise I think seam uses org.jboss.seam.ui.EntityConverter which is a standard faces converter.
(caution: I'm a seam noob) -
6. Re: entity names in dropdowns?
dsailer.d.sailer.comcast.net Mar 26, 2009 6:38 PM (in response to seamn00bz)something else I learned about this. One of my dropdowns wasn't binding correctly and it turned out I had overriden equals and hashCode on the entity which I assume messed with seam/jsf's ability to match things up.
-
7. Re: entity names in dropdowns?
pgmjsd Mar 26, 2009 7:58 PM (in response to seamn00bz)
d sailer wrote on Mar 26, 2009 14:19:
I just use <s:convertEntity /> and it works. I'm assuming it uses getId() by default. Otherwise I think seam uses org.jboss.seam.ui.EntityConverter which is a standard faces converter.
(caution: I'm a seam noob)Yes, <s:convertEntity> will use the ID of the entity. If you're getting the java.lang.Object.toString() output in your HTML, then something is definitely wrong.