mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2024-12-26 23:25:53 -05:00
Details tab improvement when displaying network information.
This commit is contained in:
parent
a383bd1cb3
commit
edcc64548e
@ -5772,20 +5772,13 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (var j = 0; j < m.length; j++) {
|
for (var j = 0; j < m.length; j++) {
|
||||||
var iplayer = m[j];
|
var iplayer = m[j], items = [];
|
||||||
if (iplayer.family == 'IPv4') {
|
if (iplayer.address) { items.push(format("IP: {0}", EscapeHtml(iplayer.address))); }
|
||||||
if (iplayer.gateway && iplayer.netmask) {
|
if (iplayer.netmask) { items.push(format("Mask: {0}", EscapeHtml(iplayer.netmask))); }
|
||||||
x += addDetailItem("IPv4 Layer", format("{0}, Mask: {1}, Gateway: {2}", EscapeHtml(iplayer.address), EscapeHtml(iplayer.netmask), EscapeHtml(iplayer.gateway)));
|
if (iplayer.gateway) { items.push(format("Gateway: {0}", EscapeHtml(iplayer.gateway))); }
|
||||||
} else {
|
if (items.length > 0) {
|
||||||
if (iplayer.address) { x += addDetailItem("IPv4 Layer", format("{0}", EscapeHtml(iplayer.address))); }
|
if (iplayer.family == 'IPv4') { x += addDetailItem("IPv4 Layer", items.join(", ")); }
|
||||||
}
|
if (iplayer.family == 'IPv6') { x += addDetailItem("IPv6 Layer", items.join(", ")); }
|
||||||
}
|
|
||||||
if (iplayer.family == 'IPv6') {
|
|
||||||
if (iplayer.gateway && iplayer.netmask) {
|
|
||||||
x += addDetailItem("IPv6 Layer", format("{0}, Mask: {1}, Gateway: {2}", EscapeHtml(iplayer.address), EscapeHtml(iplayer.netmask), EscapeHtml(iplayer.gateway)));
|
|
||||||
} else {
|
|
||||||
if (iplayer.address) { x += addDetailItem("IPv6 Layer", format("{0}", EscapeHtml(iplayer.address))); }
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
x += '</div>';
|
x += '</div>';
|
||||||
|
@ -11190,20 +11190,13 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (var j = 0; j < m.length; j++) {
|
for (var j = 0; j < m.length; j++) {
|
||||||
var iplayer = m[j];
|
var iplayer = m[j], items = [];
|
||||||
if (iplayer.family == 'IPv4') {
|
if (iplayer.address) { items.push(format("IP: {0}", EscapeHtml(iplayer.address))); }
|
||||||
if (iplayer.gateway && iplayer.netmask) {
|
if (iplayer.netmask) { items.push(format("Mask: {0}", EscapeHtml(iplayer.netmask))); }
|
||||||
x += addDetailItem("IPv4 Layer", format("IP: {0}, Mask: {1}, Gateway: {2}", EscapeHtml(iplayer.address), EscapeHtml(iplayer.netmask), EscapeHtml(iplayer.gateway)));
|
if (iplayer.gateway) { items.push(format("Gateway: {0}", EscapeHtml(iplayer.gateway))); }
|
||||||
} else {
|
if (items.length > 0) {
|
||||||
if (iplayer.address) { x += addDetailItem("IPv4 Layer", format("IP: {0}", EscapeHtml(iplayer.address))); }
|
if (iplayer.family == 'IPv4') { x += addDetailItem("IPv4 Layer", items.join(", ")); }
|
||||||
}
|
if (iplayer.family == 'IPv6') { x += addDetailItem("IPv6 Layer", items.join(", ")); }
|
||||||
}
|
|
||||||
if (iplayer.family == 'IPv6') {
|
|
||||||
if (iplayer.gateway && iplayer.netmask) {
|
|
||||||
x += addDetailItem("IPv6 Layer", format("IP: {0}, Mask: {1}, Gateway: {2}", EscapeHtml(iplayer.address), EscapeHtml(iplayer.netmask), EscapeHtml(iplayer.gateway)));
|
|
||||||
} else {
|
|
||||||
if (iplayer.address) { x += addDetailItem("IPv6 Layer", format("IP: {0}", EscapeHtml(iplayer.address))); }
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
x += '</div>';
|
x += '</div>';
|
||||||
|
Loading…
Reference in New Issue
Block a user