3 Replies Latest reply on May 4, 2010 11:29 PM by gebuh

    disable s:link based in datatable

    gebuh Newbie

      I'm trying to enable or disable a link in a datatable based on a users status:



      s:link view="/SomeTable.xhtml"
                              value="edit"
                             propagation="none"
                          id="canEdit"
                          rendered="#{validationAction.getIsValidUser}">
                      <f:param name="someSysid"
                              value="#{_aPerson.sysid}"/>
                  </s:link>





      so if validationAction.getIsValidUser returns true, the link is rendered.  The method it's tied to just returns a random true or false:




      public boolean getIsValidUser(ValueChangeEvent uiEvent) {
                    //temporary for testing
                     Random generator = new Random();
                     int r = generator.nextInt();
                     if(r%2 == 0){
                          this.isValidUser = true;
                     } else {
                          this.isValidUser = false;
                     }
                     return this.isValidUser;
                }



      but no matter what I do, or where I put it(as output, value, etc) I keep getting:
      javax.el.PropertyNotFoundException: /startingtable.xhtml @366,46 value="#{validationAction.getIsValidUser}": Property 'getIsValidUser' not found on type package.ValidationAction_$$_javassist_seam_23


      I have other methods in this class that work fine elsewhere.


      I'm running seam 2.2.0, with jsf, hibernate, and not a lot of experience with seam.


      any idea what I'm doing wrong?