mirror of
https://github.com/netbox-community/netbox.git
synced 2026-04-27 19:27:33 +02:00
Closes #5503: ISO 8601 date in UI and alternative format as tooltip
With this commit all dates in the UI are now consistently displayed. I changed the long date format as suggested by @xkilian and confirmed by my own research. * DATETIME_FORMAT * Before July 20, 2020 4:52 p.m. * Now 20th July, 2020 16:52 "20th July, 2020" would be spoken as "the 20th of July, 2020" but the "the" and "of" are never written. The only exception is `object_list.html`. I tried it but there it does not work so easily because the dates are passed to Jinja as SafeString.
This commit is contained in:
@@ -80,7 +80,11 @@
|
||||
<td>
|
||||
{% if object.time_zone %}
|
||||
{{ object.time_zone }} (UTC {{ object.time_zone|tzoffset }})<br />
|
||||
<small class="text-muted">Site time: {% timezone object.time_zone %}{% now "SHORT_DATETIME_FORMAT" %}{% endtimezone %}</small>
|
||||
<small class="text-muted">Site time:
|
||||
{% timezone object.time_zone %}
|
||||
{% annotated_now %}
|
||||
{% endtimezone %}
|
||||
</small>
|
||||
{% else %}
|
||||
<span class="text-muted">—</span>
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user