1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Introduced a placeholder template filter

This commit is contained in:
Jeremy Stretch
2018-11-05 13:00:46 -05:00
parent 53b6a07a41
commit 045856c9ac
23 changed files with 75 additions and 301 deletions

View File

@@ -75,23 +75,11 @@
</tr>
<tr>
<td>Date Added</td>
<td>
{% if aggregate.date_added %}
<span>{{ aggregate.date_added }}</span>
{% else %}
<span class="text-muted">N/A</span>
{% endif %}
</td>
<td>{{ aggregate.date_added|placeholder }}</td>
</tr>
<tr>
<td>Description</td>
<td>
{% if aggregate.description %}
<span>{{ aggregate.description }}</span>
{% else %}
<span class="text-muted">N/A</span>
{% endif %}
</td>
<td>{{ aggregate.description|placeholder }}</td>
</tr>
</table>
</div>

View File

@@ -105,13 +105,7 @@
</tr>
<tr>
<td>Description</td>
<td>
{% if ipaddress.description %}
<span>{{ ipaddress.description }}</span>
{% else %}
<span class="text-muted">N/A</span>
{% endif %}
</td>
<td>{{ ipaddress.description|placeholder }}</td>
</tr>
<tr>
<td>Assignment</td>
@@ -119,7 +113,7 @@
{% if ipaddress.interface %}
<span><a href="{{ ipaddress.interface.parent.get_absolute_url }}">{{ ipaddress.interface.parent }}</a> ({{ ipaddress.interface }})</span>
{% else %}
<span class="text-muted">None</span>
<span class="text-muted">&mdash;</span>
{% endif %}
</td>
</tr>

View File

@@ -160,13 +160,7 @@
</tr>
<tr>
<td>Description</td>
<td>
{% if prefix.description %}
<span>{{ prefix.description }}</span>
{% else %}
<span class="text-muted">N/A</span>
{% endif %}
</td>
<td>{{ prefix.description|placeholder }}</td>
</tr>
<tr>
<td>Is a pool</td>

View File

@@ -70,13 +70,7 @@
</tr>
<tr>
<td>Description</td>
<td>
{% if service.description %}
{{ service.description }}
{% else %}
<span class="text-muted">N/A</span>
{% endif %}
</td>
<td>{{ service.description|placeholder }}</td>
</tr>
</table>
</div>

View File

@@ -129,13 +129,7 @@
</tr>
<tr>
<td>Description</td>
<td>
{% if vlan.description %}
{{ vlan.description }}
{% else %}
<span class="text-muted">N/A</span>
{% endif %}
</td>
<td>{{ vlan.description|placeholder }}</td>
</tr>
</table>
</div>

View File

@@ -82,13 +82,7 @@
</tr>
<tr>
<td>Description</td>
<td>
{% if vrf.description %}
<span>{{ vrf.description }}</span>
{% else %}
<span class="text-muted">N/A</span>
{% endif %}
</td>
<td>{{ vrf.description|placeholder }}</td>
</tr>
</table>
</div>