openerp - How to change timezone when printing time in qweb report? -


<b>date:</b><span t-esc="time.strftime('%d-%m-%y %h:%m:%s')"/> 

this attempted code.i want print current date , time in report page.i live in india , our timezone 5.30 hrs ahead of gmt.i changed timezone in odoo user settings.but still printing time in gmt , not in ist(gmt+5.30)

checkout module https://apps.openerp.com/apps/modules/8.0/qweb_usertime/ adds tag specify time of report based on usertime, internally uses pytz module

so can roll implementation if don't want install it, how you'll use in case

<b>date:</b><span t-usertime="%y-%m-%d %h:%m:%s" /> 

Comments

Popular posts from this blog

sql - invalid in the select list because it is not contained in either an aggregate function -

Angularjs unit testing - ng-disabled not working when adding text to textarea -

How to start daemon on android by adb -