Exemplo n.º 1
0
 public static bool HasRights <T>(this IFieldAccessService fieldAccessService, T model, Expression <Func <T, object> > expression, AccessRight requiredRights)
 {
     return(fieldAccessService.RightsFor(model, expression.ToAccessor().InnerProperty) >= requiredRights);
 }
Exemplo n.º 2
0
 public static AccessRight Most(this IEnumerable <AccessRight> rights)
 {
     return(AccessRight.Most(rights.ToArray()));
 }