Ignore:
Timestamp:
Nov 29, 2010, 4:56:48 PM (12 years ago)
Author:
robert@…
Message:

Improved the study overview page such that the different tabs are loaded when needed. Also rewritten parts of the code. See ticket #155

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/domain/dbnp/authentication/SecUser.groovy

    r1144 r1213  
    2929        }
    3030
    31         public boolean equals(Object y)
    32         {
    33             if( !( y instanceof SecUser ) ) {
    34                 return false;
    35             }
     31        public boolean equals(Object y)
     32        {
     33                if( !( y instanceof SecUser ) ) {
     34                        return false;
     35                }
    3636
    37             if (y == null) return false;
     37                if (y == null) return false;
    3838
    39             return this.id == y.id
    40         }
     39                return this.id == y.id
     40        }
     41
     42        public boolean hasAdminRights() {
     43                return getAuthorities().contains( SecRole.findByAuthority( 'ROLE_ADMIN' ) );
     44        }
     45
    4146}
Note: See TracChangeset for help on using the changeset viewer.