0
When I try to open the page, I get:
javax.el.PropertyNotFoundException: pagina.xhtml @3,54 value="#{meuManagedBean.valores}": Target Unreachable, identifier 'meuManagedBean' resolved to null
Considering:
<h:form>
<p:outputLabel id="formulario" value="#{meuManagedBean.label}"/>
<p:selectOneRadio id="grupo" layout="custom" value="#{meuManagedBean.valores}">
<f:selectItem itemLabel="Verdadeiro" itemValue="true"/>
<f:selectItem itemLabel="Falso" itemvalue="false"/>
<p:ajax event="keyup" update="formulario"/>
</p:selectOneRadio>
<p:panelGrid columns="4">
<p:radioButton for="grupo" itemIndex="0"/>
<p:outputLabel value="Verdadeiro"/>
<p:radioButton for="grupo" itemIndex="1"/>
<p:outputLabel value="Falso"/>
</p:panelGrid>
</h:form>
Why the mistake is only in the EL of p:selectOneRadio
and not of p:outputLabel
? How to solve?
I am using Mojarra. I left only the outputLabel EL and it worked. The
meuManagedBean
is with the appropriate annotations and the name is also correct. There is some special implication as it is a selectOneMenu?– ptkato
@Patrick Is the list void? She has to be instantiated.
– Renato Dinhani
I’m afraid not, because he’s a boolean (
Boolean valores;
).– ptkato
@Patrick I believe the right kind of dice to be used with a
selectOneRadio
no value is a String, not a Boolean, as the Primefaces example in the showcase shows: http://www.primefaces.org/showcase/ui/input/oneRadio.xhtml– Renato Dinhani
Does this influence something? Because I want when "true" is selected to be true, when "false" is false.
– ptkato