mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Do not use annotated_date on custom date fields to avoid date parsing
@jeremystretch: > It'd be better to have the custom field return a date object than to > accommodate string values in the template filter. Let's just omit custom > field dates for now to keep this from getting any more complex.
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
{% load helpers %}
|
||||
{% with custom_fields=object.get_custom_fields %}
|
||||
{% if custom_fields %}
|
||||
<div class="panel panel-default">
|
||||
@@ -18,8 +17,6 @@
|
||||
<a href="{{ value }}">{{ value|truncatechars:70 }}</a>
|
||||
{% elif field.type == 'multiselect' and value %}
|
||||
{{ value|join:", " }}
|
||||
{% elif field.type == 'date' and value %}
|
||||
{{ value|annotated_date }}
|
||||
{% elif value is not None %}
|
||||
{{ value }}
|
||||
{% elif field.required %}
|
||||
|
Reference in New Issue
Block a user