Inicio del mensaje redirigido:

Fecha: Tue, 13 Nov 2012 15:27:38 -0300
Desde: Marco Mansilla <conta...@marcomansilla.com.ar>
Para: web2py@googlegroups.com
Asunto: Re: [web2py] SQLFORM.smartgrid. This is a bug?


still you need to give to orderby the name of the field that you want
to order, even when the table has only one field... but the error seems
odd...

def something():
     grilla = SQLFORM.smartgrid(table_1, orderby=table_1.name)

also, since you you don't use represent you could add format at the end
of your table definition...

#Model:
table_1 = db.define_table('table1',    
    Field('name'),
    format='%(name)s')
> 
> 
> El martes, 13 de noviembre de 2012 02:10:03 UTC-3, marco mansilla
> escribió:
> >
> > aren't you missing the db. before table? 
> >
> 
>  
> No, the way I define the table is not necessary
> 
> table_1 = db.define_table('table1',    
>     Field('name'),
> )
> 
> *table_1 *is equals to* db.table1*
> 
> Jose
> 

-- 



Reply via email to