[web2py] Re: Pass a query from form to another function

2018-04-20 Thread Yoel Benitez Fonseca
Umm... sorry took long to answer, i have put on issue on PyDAL repo and a pull request with a posible fix: https://github.com/web2py/pydal/pull/531 El martes, 10 de abril de 2018, 22:20:04 (UTC-4), Anthony escribió: > > On Tuesday, April 10, 2018 at 6:14:06 PM UTC-4, Yoel Benitez Fonseca wrote:

[web2py] Re: Pass a query from form to another function

2018-04-10 Thread Anthony
On Tuesday, April 10, 2018 at 6:14:06 PM UTC-4, Yoel Benitez Fonseca wrote: > > Is this not working any more ? > > >>> q = (db.photo.id == 1) > >>> db(q.as_dict(flat=True)).select() > File "", line unknown > SyntaxError: Operator not supported: eq > > That is in a web2py shell,i mean is the same

[web2py] Re: Pass a query from form to another function

2018-04-10 Thread Anthony
> > On Tuesday, April 10, 2018 at 3:14:06 PM UTC-7, Yoel Benitez Fonseca wrote: >> >> Is this not working any more ? >> >> >>> q = (db.photo.id == 1) >> >>> db(q.as_dict(flat=True)).select() >> File "", line unknown >> SyntaxError: Operator not supported: eq >> >> That is in a web2py shell,i mea

[web2py] Re: Pass a query from form to another function

2018-04-10 Thread Dave S
On Tuesday, April 10, 2018 at 3:14:06 PM UTC-7, Yoel Benitez Fonseca wrote: > > Is this not working any more ? > > >>> q = (db.photo.id == 1) > >>> db(q.as_dict(flat=True)).select() > File "", line unknown > SyntaxError: Operator not supported: eq > > That is in a web2py shell,i mean is the sam

[web2py] Re: Pass a query from form to another function

2018-04-10 Thread Yoel Benitez Fonseca
Is this not working any more ? >>> q = (db.photo.id == 1) >>> db(q.as_dict(flat=True)).select() File "", line unknown SyntaxError: Operator not supported: eq That is in a web2py shell,i mean is the same thing passing around the query in the session as a dict, is not ? El miércoles, 7 de dicie

[web2py] Re: Pass a query from form to another function

2016-12-08 Thread Marlysson Silva
Can't by definition of DAL code? or by security.. Em quarta-feira, 7 de dezembro de 2016 16:56:20 UTC-3, Anthony escreveu: > > On Wednesday, December 7, 2016 at 9:33:16 AM UTC-5, Marlysson Silva wrote: >> >> You can use sessions.. >> >> session.content = query_search >> > > A Query object can't be

Re: [web2py] Re: Pass a query from form to another function

2016-12-07 Thread Áureo Dias Neto
Thank guys, it's work 2016-12-07 17:56 GMT-02:00 Anthony : > On Wednesday, December 7, 2016 at 9:33:16 AM UTC-5, Marlysson Silva wrote: >> >> You can use sessions.. >> >> session.content = query_search >> > > A Query object can't be pickled to store it in the session, but you can > first conv

[web2py] Re: Pass a query from form to another function

2016-12-07 Thread Anthony
On Wednesday, December 7, 2016 at 9:33:16 AM UTC-5, Marlysson Silva wrote: > > You can use sessions.. > > session.content = query_search > A Query object can't be pickled to store it in the session, but you can first convert to a dictionary: session.search_query = search_query.as_dict(flat=True)

Re: [web2py] Re: Pass a query from form to another function

2016-12-07 Thread Áureo Dias Neto
with 'session.content = query_search' i save the query in session? and request this on argument of function? 2016-12-07 12:33 GMT-02:00 Marlysson Silva : > You can use sessions.. > > session.content = query_search > > and in your view responsible by generate pdf use: > > generate_pdf(session.con

[web2py] Re: Pass a query from form to another function

2016-12-07 Thread Marlysson Silva
You can use sessions.. session.content = query_search and in your view responsible by generate pdf use: generate_pdf(session.content) Em quarta-feira, 7 de dezembro de 2016 10:08:45 UTC-3, Áureo Dias Neto escreveu: > > I have a search form, which filter the fields, I filter my query .. so far