I have a custom auth table which contains a field 'account'. Once a
user is logged in, would it be possible to decorate a function the
following way:

@auth.requires(auth.user.account=='3')
def update_xxx():
    ....
    return(form=form)


In the web2py manual I read that it is possible combine requirements.
If the above decorator works, would it be possible to combine a
requirement the following way:

@auth.requires(auth.user.account=='3' or auth.user.account=='2')
def update_xxx():
    ....
    return(form=form)


Kind regards,

Annet.

Reply via email to