show date from Python part tfrom datetime import datetime,date def strToDate(dt): return date(int(dt[0:4]), int(dt[5:7]), int(dt[8:10]))
date_invoice = rec.date_invoice date_invoice = strToDate(date_invoice).strftime('%d/%m/%Y')
in xml part
<span t-esc="get_amount_untaxed['date_invoice']"/>normal date format<span t-field="get_amount_untaxed['date_invoice']"r{"format": "d MMMM y"}'/>
No comments:
Post a Comment