On Monday, June 5, 2017 at 1:11:25 AM UTC-4, [email protected] wrote:
>
> I could't use the smartgrid because smartgrid works on complete table but 
> i had to query the table first.
>

The smartgrid has the "constraints" argument for that purpose (it is a 
dictionary with table names as keys and DAL queries as values). See 
http://web2py.com/books/default/chapter/29/07/forms-and-validators#smartgrid-signature.
 

> I still don't know what the problem was but solution given by @Leandro 
> Paz worked.
>
> you just have to do:
> grid = SQLFORM.grid (db.auth_user, user_signature = False)
>
>
I don't think that is related to the problem Rudy is having. By default, 
user_signature=True, which simply means the grid will not display 
create/edite/delete buttons (nor allow those operations). You wouldn't get 
a "not authorized" message simply by attempting to load the grid. 
Furthermore, for logged in users, create/edit/delete is allowed, even with 
user_signature=True, and Rudy indicated his code started with using the 
@auth.requires_login() decorator, which requires a logged in user.

Anthony

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to