[web2py] Re: request.now - one day

2016-09-15 Thread Daniel Dos Santos Guilhermino
Helped me a lot! Thank you so much! Em segunda-feira, 19 de janeiro de 2015 14:36:58 UTC-2, Niphlod escreveu: > > slightly incorrect ... > > either > > from datetime import timedelta > yesterday = request.now - timedelta(days=1) > > > or > > > import datetime > yesterday = request.now -

[web2py] Re: request.now - one day

2015-01-19 Thread Mark Anderson
I found the answer. yesterday = request.now - datetime.timedelta( days=1) I'm loving web2py and about to complete a major project. Thanks to Massimo and crew! On Sunday, January 18, 2015 at 12:48:03 AM UTC-6, Mark Anderson wrote: Should be an easy one... How do I subtract one day from a

[web2py] Re: request.now - one day

2015-01-19 Thread Paolo Valleri
Hi, from datetime import timedelta request.now - datetime.timedelta(days=1) Paolo On Sunday, January 18, 2015 at 7:48:03 AM UTC+1, Mark Anderson wrote: Should be an easy one... How do I subtract one day from a request.now? Seems like it should be easy but I can't find clear documentation.

[web2py] Re: request.now - one day

2015-01-19 Thread Niphlod
slightly incorrect ... either from datetime import timedelta yesterday = request.now - timedelta(days=1) or import datetime yesterday = request.now - datetime.timedelta(days=1) -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py