Hi all,
My code looks like this:-
User.java
@Entity @Name("userBean") @Scope(SESSION) @Table(name = "abcd") public class User implements Serializable { private static final long serialVersionUID = -7928759431732764467L; private String StrUserName; private String StrPassword; @Id @NotNull public String getStrUserName() { return StrUserName; } public void setStrUserName(String strUserName) { StrUserName = strUserName; } @NotNull public String getStrPassword() { return StrPassword; } public void setStrPassword(String strPassword) { StrPassword = strPassword; } }
<div class="dialog"> <h:panelGrid columns="2" rowClasses="prop" columnClasses="name,value"> <h:outputLabel for="StrUserName">Username</h:outputLabel> <h:inputText id="StrUserName" value="#{userBean.StrUserName}"/> <h:outputLabel for="StrPassword">Password</h:outputLabel> <h:inputSecret id="StrPassword" value="#{userBean.StrPassword}"/> </h:panelGrid> </div>
Try using #{userBean.strUserName} - EL uses camelcasing.