🆕 IP clickable in Devices views #856

This commit is contained in:
jokob-sk
2024-10-21 21:50:01 +11:00
parent c0f14e46ce
commit 26503eaf52
2 changed files with 25 additions and 7 deletions

View File

@@ -545,15 +545,33 @@ function initializeDatatable (status) {
}
} },
// IP address
// IP address
{targets: [mapIndx(8)],
'createdCell': function (td, cellData, rowData, row, col) {
if (!emptyArr.includes(cellData)){
$(td).html (`<span class="anonymizeIp">
<a href="http://${cellData}" target="_blank">
${cellData}
</a>
<a href="https://${cellData}" target="_blank">
<i class="fa fa-lock "></i>
</a>
<span>`);
} else {
$(td).html ('');
}
}
},
// IP address (ordeable)
{targets: [mapIndx(12)],
'createdCell': function (td, cellData, rowData, row, col) {
if (!emptyArr.includes(cellData)){
$(td).html ('<span class="anonymizeIp">'+cellData+'</span>');
} else {
$(td).html ('');
}
} },
if (!emptyArr.includes(cellData)){
$(td).html (`<span class="anonymizeIp">${cellData}<span>`);
} else {
$(td).html ('');
}
}
},
// Favorite
{targets: [mapIndx(4)],