Search code examples
xmlreportodooodoo-9qweb

Odoo - Add (AM/PM) in datetime in qweb report


<span t-field="o.date_order"/>

which gives output as:

04/11/2017 09:48:35

But how can I get output like:

04/11/2017 09:48 AM


Solution

  • try this

    <span t-field="o.date_order" t-field-options='{"format": "MM dd y h:mm a"}'/>