Re: [web2py] Using db.table.format (i.e. format attr outside of table definition)

2019-07-09 Thread Val K
I suppose it is also needed to add IS_IN_DB validator to the field that is reference -- 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 me

Re: [web2py] Using db.table.format (i.e. format attr outside of table definition)

2019-07-09 Thread Eliezer (Vlad) Tseytkin
Oh, I see, here is what's happening: I now have the following code: db.product._format = lambda row: 'test' grid = SQLFORM.grid(db.flavor) The table flavor has a column referencing the table product. So, the grid displays the product column correctly now (with _format - this is where just

Re: [web2py] Using db.table.format (i.e. format attr outside of table definition)

2019-07-08 Thread Val K
Show your code, please -- 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-

Re: [web2py] Using db.table.format (i.e. format attr outside of table definition)

2019-07-08 Thread Eliezer (Vlad) Tseytkin
Nope, still doesn't work... On Mon, Jul 8, 2019, 1:20 PM Val K wrote: > Try db.table._format=... > > -- > 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)

[web2py] Using db.table.format (i.e. format attr outside of table definition)

2019-07-08 Thread Val K
Try db.table._format=... -- 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 "web2

[web2py] Using db.table.format (i.e. format attr outside of table definition)

2019-07-07 Thread Vlad
Please help! Any way to use this format property outside of a table definition? -- 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

[web2py] Using db.table.format (i.e. format attr outside of table definition)

2019-07-03 Thread Vlad
Using the following db.table.format = lambda row: 'test' before SQLFORM.grid creation doesn't seem to work. What's the proper way to set record representation outside of table definition? -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web