mirror of https://github.com/jumpserver/jumpserver
commit
2ece3545ed
|
@ -92,8 +92,7 @@
|
||||||
<th class="text-center">{% trans 'Hostname' %}</th>
|
<th class="text-center">{% trans 'Hostname' %}</th>
|
||||||
<th class="text-center">{% trans 'IP' %}</th>
|
<th class="text-center">{% trans 'IP' %}</th>
|
||||||
<th class="text-center">{% trans 'Hardware' %}</th>
|
<th class="text-center">{% trans 'Hardware' %}</th>
|
||||||
<th class="text-center">{% trans 'Active' %}</th>
|
<th class="text-center">{% trans 'Reachable' %}</th>
|
||||||
{# <th class="text-center">{% trans 'Reachable' %}</th>#}
|
|
||||||
<th class="text-center">{% trans 'Action' %}</th>
|
<th class="text-center">{% trans 'Action' %}</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
|
@ -163,10 +162,12 @@ function initTable() {
|
||||||
$(td).html(rowData.hardware_info)
|
$(td).html(rowData.hardware_info)
|
||||||
}},
|
}},
|
||||||
{targets: 4, createdCell: function (td, cellData) {
|
{targets: 4, createdCell: function (td, cellData) {
|
||||||
if (!cellData) {
|
if (cellData === 1){
|
||||||
$(td).html('<i class="fa fa-times text-danger"></i>')
|
$(td).html('<i class="fa fa-circle text-navy"></i>')
|
||||||
|
} else if (cellData === 0) {
|
||||||
|
$(td).html('<i class="fa fa-circle text-danger"></i>')
|
||||||
} else {
|
} else {
|
||||||
$(td).html('<i class="fa fa-check text-navy"></i>')
|
$(td).html('<i class="fa fa-circle text-warning"></i>')
|
||||||
}
|
}
|
||||||
}},
|
}},
|
||||||
|
|
||||||
|
@ -179,8 +180,8 @@ function initTable() {
|
||||||
ajax_url: '{% url "api-assets:asset-list" %}',
|
ajax_url: '{% url "api-assets:asset-list" %}',
|
||||||
columns: [
|
columns: [
|
||||||
{data: "id"}, {data: "hostname" }, {data: "ip" },
|
{data: "id"}, {data: "hostname" }, {data: "ip" },
|
||||||
{data: "cpu_cores"}, {data: "is_active", orderable: false },
|
{data: "cpu_cores", orderable: false},
|
||||||
{data: "id", orderable: false }
|
{data: "connectivity", orderable: false}, {data: "id", orderable: false }
|
||||||
],
|
],
|
||||||
op_html: $('#actions').html()
|
op_html: $('#actions').html()
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue