예제 #1
0
def they_can_delete_standardtekster(user, they):
    if is_administrator(user):
        they.can(DELETE, 'StandardTekst')
예제 #2
0
def they_can_put_standardtekster(user, they):
    if is_administrator(user):
        they.can(PUT, 'StandardTekst')
예제 #3
0
def they_can_put_tilskuddsordninger(user, they):
    if is_administrator(user):
        they.can(PUT, 'Tilskuddsordning')
예제 #4
0
def they_can_get_standardtekster(user, they):
    if is_saksbehandler(user) or is_administrator(user):
        they.can(GET, 'StandardTekst')
예제 #5
0
def they_can_get_tilskuddsordninger(user, they):
    if is_administrator(user) or is_saksbehandler(user) or is_godkjenner(user):
        they.can(GET, 'Tilskuddsordning')
    elif is_soker(user):
        they.can(GET, 'Tilskuddsordning', if_tilskuddsordning_is_published)