2 Replies Latest reply on Nov 5, 2007 9:33 AM by fphilip

    error en property/getter

    fphilip

      LoginForm.java
      ....
      public String login(){
      identity.login();
      }
      ....

      login.xhtml
      ...
      <ui:include src="/incl/command-panel.xhtml">
      <ui:param name="actionId" value="loginButton"/>
      <ui:param name="actionMessage" value="Login"/>
      <ui:param name="actionCommand" value="#{login.login}"/>
      </ui:include>
      ...
      command-panel.xhtml
      ....
      <h:commandButton id="#{actionId}" action="#{actionCommand}" value="#{actionMessage}"/>
      ....


      and the error is :
      Property 'login' not found on type package....LoginForm_$$_javassist_??

        • 1. Re: error en property/getter
          pmuir

          Use [ code ] tags, post the whole of LoginForm

          • 2. Re: error en property/getter
            fphilip

             

            @Name("login")
            public class LoginForm implements Serializable {
             public static final String ERROR = "error";
             public static final String LOGGED = "logged";
             private String username;
             private String contextId;
             private String password;
             private User user;
             private Context context;
            
             @In
             private Identity identity;
             @org.jboss.seam.annotations.Logger
             private Log log;
            
             @Length(max=10, min=5)
             public String getUsername() {
             return username;
             }
            
             public void setUsername(String username) {
             this.username = username;
             }
            
             public String getContextId() {
             return contextId;
             }
            
            
             public Context getContext() {
             return context;
             }
            
             public void setContext(Context context) {
             this.context = context;
             }
            
             public void setContextId(String contextId) {
             this.contextId = contextId;
             }
            
             public String getPassword() {
             return password;
             }
            
             public void setPassword(String password) {
             this.password = password;
             }
            
             public String login(){
             identity.login();
             return identity.isLoggedIn() ? LOGGED : ERROR;
             }
            
            
             public User getUser() {
             return user;
             }
            
             public void setUser(User user) {
             this.user = user;
             }
            
            
             public String cancel(){
             return Action.CANCEL;
             }
            
             @Begin(pageflow="login")
             public String beginPageFlow(){
             return "";
             }