Skip to Content
Menu
You need to be registered to interact with the community.
This question has been flagged
2 Odgovori
2435 Prikazi

Hi. I am working with Odoo enterprise web 16.4+e

In my QWeb report, I have a field that getting datetime from Attendance like this:

Currently it is showing 12/03/2024 17:30:10

How can I only show time like 17:30:10 ?

Thanks in advance!

Avatar
Opusti
Best Answer

Hello,

 <span t-esc="context_timestamp(YOUR_FIELD).strftime('%H:%M:%S')"/>



Avatar
Opusti
Avtor

works perfectly. thanks!

Best Answer

Hi,

If the field is a Datetime field you can use your_field.strftime.('%H:%M:%S)


Hope it helps

Avatar
Opusti
Avtor

thanks! but in my case, Sahar's answer is more acceptable

Related Posts Odgovori Prikazi Aktivnost
1
jan. 21
8670
2
jul. 20
4688
1
sep. 19
13179
2
okt. 19
12707
3
jun. 25
840