Skip to content

Commit

Permalink
🆕 IP clickable in Devices views #856
Browse files Browse the repository at this point in the history
  • Loading branch information
jokob-sk committed Oct 21, 2024
1 parent c0f14e4 commit 26503ea
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 7 deletions.
32 changes: 25 additions & 7 deletions front/devices.php
Original file line number Diff line number Diff line change
Expand Up @@ -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)],
Expand Down
Empty file modified front/php/templates/language/es_es.json
100644 → 100755
Empty file.

0 comments on commit 26503ea

Please sign in to comment.