Thanks, Anthony. That works nicely.
On Fri, Oct 7, 2016 at 10:32 AM Anthony wrote:
> Have you tried adding:
>
> auth.user.update(userlevel=newlevel)
>
> Anthony
>
>
> On Thursday, October 6, 2016 at 6:15:02 PM UTC-4, Michael Ellis wrote:
>
>
> I have the following code as a json service for
Have you tried adding:
auth.user.update(userlevel=newlevel)
Anthony
On Thursday, October 6, 2016 at 6:15:02 PM UTC-4, Michael Ellis wrote:
>
>
> I have the following code as a json service for changing user privileges.
> This app doesn't need the fine-grained control of Web2py RBAC so I'v
Thanks, Marlysson. I understand why it's going wrong when the user changes
their own level. My question was aimed a finding out if web2py had a
convenience function to refresh auth.user from db.auth_user. Otherwise I
have to use an ugly construct like:
try:
aid = auth.user.id # ra
Isn't because you are putting the level user hardcoded? There after that
user change own level , the verification don't works more.
1. If you want that user name are unique mark at table the field with
validator unique=True
2. The size of rows returned could be made with count() , db(query).coun
4 matches
Mail list logo