Hello,

I have posted 4 times previously to this list and only once got a response
and that was a friend I was working on a project with. So I must be doing
something completely off the wall to get no help from the people on the list
who 'know'.

After spending hours trying different methods of saving a User with a Role
and Group I achieved that (my last post). Now I wish to update the Role in
the same screen. I use a pull tool for all entitylist population on screen.
One of the methods is

        /**
         * Get all role from the turbine table
     */
        public List getAllRoles() throws Exception
        {
        Role[] roles=TurbineSecurity.getAllRoles().getRolesArray();
                return Arrays.asList(roles);
        }

I also tried

        /**
         * Get all role from the turbine table
     */
        public List getAllRoles() throws Exception
        {
          Criteria crit = new Criteria();
        Role[] roles=TurbineSecurity.getRoles(crit).getRolesArray();
                return Arrays.asList(roles);
        }

In the template I have:

## Set up entries in the roleType drop-down
#set ( $userRoles = $entitylist.getAllRoles() )
#if (!$selectedRole && ($userRoles.size()>0))
        #set ( $selectedRole=$userRoles.get(0) )
#end

I note that I get this exception when ever I access this template.

     [java] ASTMethod.execute() : exception invoking method 'size' in class
java
.util.Arrays$ArrayList : java.lang.IllegalAccessException

If I put $selectedRole.getName() in the BODY of the HTML it never has a
value displayed. I also tried
putting $userRoles.size() in the BODY of the HTML and it never displays
either. These are the roles I expect to see

+---------+---------------+------------+
| ROLE_ID | ROLE_NAME     | OBJECTDATA |
+---------+---------------+------------+
|       1 | turbine_root  | NULL       |
|     100 | Administrator | NULL       |
|     101 | Message User  | NULL       |
+---------+---------------+------------+

I have no problems with non TurbineSecurity related entities. Any idea about
what is going on here?

Thanks

David Wynter


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to