This content has been marked as final.
Show 2 replies
-
1. Re: ComboBox Richfaces 3.2.0.GA
rbcdexia Apr 3, 2008 12:03 PM (in response to rbcdexia)"rbcdexia" wrote:
I am using the new ComboBox component.
I have problems to do a combo using a list of entities beacause of the special characters.
I have used CDATA and & to replace '&' character but it doesn't doesn't work.
Can you help me, please??
My code:
Xhtml page:
<rich:comboBox selectFirstOnUpdate="false" escape="false" id="entidad" defaultLabel="Enter some value" > <f:selectItems value="#{listaNombresEntidades}" /> </rich:comboBox>
Java code:@Factory(value="listaNombresEntidades",scope=ScopeType.SESSION) public List<SelectItem> getNombresEntidadesItem() { List<SelectItem> items = new ArrayList<SelectItem>(); //items.add(new SelectItem(null,"--- Contrapartidas ---")); List<String> entidades =getEntityManager() .createQuery("select iic.nombre from Iic iic order by iic.nombre").getResultList(); for (String entidad :entidades) { SelectItem aux = new SelectItem(); aux.setValue("<![CDATA[".concat(entidad.trim()).concat("]]>")); if(entidad != null) aux.setLabel("<![CDATA[".concat(entidad.trim()).concat("]]>")); else continue; items.add(aux); } return items; }
Thanks, -
2. Re: ComboBox Richfaces 3.2.0.GA
nbelaevski Apr 3, 2008 6:05 PM (in response to rbcdexia)Hello,
That seems to be a bug. I've filed that as: http://jira.jboss.com/jira/browse/RF-2966