Fix natural sorting
parent
9a33973452
commit
9d03162886
|
|
@ -213,7 +213,7 @@ interfaces {
|
||||||
}
|
}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{# Physical interfaces should be sorted by FPC/PIC/Port value - that's a challenge to do in Jinja so we cheat for now by putting the xe- interfaces first. This won't work for all devices! #}
|
{# Physical interfaces should be sorted by FPC/PIC/Port value - that's a challenge to do in Jinja so we cheat for now by putting the xe- interfaces first. This won't work for all devices! #}
|
||||||
{% for interface in device.interfaces.filter(name__contains='-')|natsort(key="name") %}
|
{% for interface in device.interfaces.filter(name__contains='-')|natsort(attribute="name") %}
|
||||||
{{ interfaceconfig(interface) }}
|
{{ interfaceconfig(interface) }}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% for interface in device.interfaces.filter(name__startswith='ae') %}
|
{% for interface in device.interfaces.filter(name__startswith='ae') %}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue