I had to download paydal. It seems working. Except I need to difine
search_text. N since thats an input, I believe i need to do
form=SQLFORM.factory (Field ('search_text', label='peak inside',
requires=IS_NOT_EMPTY ())) n then if form.process.accepted (): search_text
= form.vars.search_name redirect(URL ('search results')). Right?
On Mar 6, 2015 1:06 PM, "Massimo Di Pierro" <massimo.dipie...@gmail.com>
wrote:

> I agree with Leonel,
>
> is is better to make your own search. The all point of the grid is
> pagination of results. If that is not what you need, make your own search
> using this:
>
> from pydal.helpers.methods import smart_query
>
> list_of_searchable_fields = [db.table.field1, db.table.field2, ...]
>
> query = smart_query(list_of_searchable_fields, search_text)
>
> rows = db(query).select()
>
>
> This supports the same search syntax as the grid.
>
>
>
>
>
> On Friday, 6 March 2015 10:27:01 UTC-6, Leonel Câmara wrote:
>>
>> Well you can use LOAD to put the form there and then have the controller
>> redirect if it has results.
>>
>> But really it's much simpler to just make your own search.
>>
>  --
> 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 a topic in the
> Google Groups "web2py-users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/web2py/xTCJzJrRuoo/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> web2py+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to