Sort records label-wise reverse

Account for the hierarchical nature of DNS by sorting records by their
name label-wise from right to left. Also justify the record names to the
right, so they visually line up on label borders.
This commit is contained in:
corubba 2023-03-03 13:35:14 +01:00
parent 077bbb813c
commit 934e4a7af3

View File

@ -202,6 +202,17 @@
{% else %} {% else %}
targets: [5] targets: [5]
{% endif %} {% endif %}
},
{
targets: [0],
className: "text-right",
data: {
'_': "0",
'sort': function (row, _type, _set, _meta) {
const data = row[0] || '';
return data.split('.').reverse().join('.');
},
},
} }
], ],
{% if domain.type != 'Slave' %} {% if domain.type != 'Slave' %}