users_list_table_options = {
"language": {
"search": "Search: ",
"lengthMenu":"Show _MENU_ entries per page",
"info":"Showing _START_ to _END_ of _TOTAL_ active users",
"infoEmpty":"Showing 0 to 0 of 0 entries",
"infoFiltered":"",
"emptyTable": "No data in table",
},
"destroy": true,
"processing": false,
"serverSide": true,
"pageLength": 10,
"order": [ 1, 'asc'],
"autoWidth": true,
"stateSave": true,
"pagingType": "bootstrap",
"columnDefs": [
{
"targets": [0],
"data": "user_thumb",
"createdCell": function (td, cellData, rowData, row, col) {
if (cellData === '') {
$(td).html('');
} else {
$(td).html('
');
}
},
"orderable": false,
"searchable": false,
"width": "5%",
"className": "users-poster-face"
},
{
"targets": [1],
"data": "friendly_name",
"createdCell": function (td, cellData, rowData, row, col) {
if (cellData !== '') {
if (rowData['user_id'] > 0) {
$(td).html('' + cellData + '');
} else {
$(td).html('' + cellData + '');
}
} else {
$(td).html(cellData);
}
},
"width": "15%"
},
{
"targets": [2],
"data": "last_seen",
"render": function ( data, type, full ) {
if (data) {
return moment(data, "X").fromNow();
} else {
return "never";
}
},
"searchable": false,
"width": "15%",
"className": "no-wrap hidden-xs"
},
{
"targets": [3],
"data": "ip_address",
"createdCell": function (td, cellData, rowData, row, col) {
if (cellData) {
if (isPrivateIP(cellData)) {
if (cellData != '') {
$(td).html(cellData);
} else {
$(td).html('n/a');
}
} else {
$(td).html(' ' + cellData + '');
}
} else {
$(td).html('n/a');
}
},
"width": "15%",
"className": "no-wrap hidden-md hidden-sm hidden-xs modal-control-ip"
},
{
"targets": [4],
"data":"platform",
"createdCell": function (td, cellData, rowData, row, col) {
if (cellData) {
var transcode_dec = '';
if (rowData['video_decision'] === 'transcode') {
transcode_dec = ' ';
} else if (rowData['video_decision'] === 'copy') {
transcode_dec = ' ';
} else if (rowData['video_decision'] === 'direct play' || rowData['video_decision'] === '') {
transcode_dec = ' ';
}
$(td).html('