Use Font Awesome for device status indication
This commit is contained in:
parent
df941650dd
commit
b91dcb755c
2 changed files with 2 additions and 2 deletions
|
@ -217,7 +217,7 @@ else showdevices();
|
||||||
|
|
||||||
filtertables();
|
filtertables();
|
||||||
|
|
||||||
$("div[id$='-indicator']").each(function() {
|
$("i[id$='-indicator']").each(function() {
|
||||||
device_id = this.id.split("-")[0];
|
device_id = this.id.split("-")[0];
|
||||||
updateStatus(device_id);
|
updateStatus(device_id);
|
||||||
setInterval(updateStatus, 10000, device_id);
|
setInterval(updateStatus, 10000, device_id);
|
||||||
|
|
|
@ -36,7 +36,7 @@
|
||||||
{% userDevices as devices %}
|
{% userDevices as devices %}
|
||||||
{% for device in devices %}
|
{% for device in devices %}
|
||||||
<tr data-orga="[{{ device.organization.id }}]">
|
<tr data-orga="[{{ device.organization.id }}]">
|
||||||
<td><div style="display: inline; color: grey; font-weight: bold;" title="No information available" id="{{ device.id }}-indicator">⬤</div>{% if device.model.deprecated %} <i style="color: red;" title="Device outdated{% if not user.is_superuser %} – please contact us to replace it with a new one{% endif %}" class="fas fa-exclamation-triangle"></i>{% elif user.is_superuser and device.upgrade_available %} <i style="color: green;" title="Firmware upgrade available" class="fas fa-upload"></i>{% endif %} <div style="display: inline;" {% if user.is_superuser %}title="{{ device.organization.name }}"{% endif %} id="{{ device.id }}-id">{{ device.serial }}{% if device.ssid %}<br><small>SSID: {{ device.ssid }}</small>{% endif %}</div></td>
|
<td><i class="fas fa-circle" style="color: grey;" title="No information available" id="{{ device.id }}-indicator"></i>{% if device.model.deprecated %} <i style="color: red;" title="Device outdated{% if not user.is_superuser %} – please contact us to replace it with a new one{% endif %}" class="fas fa-exclamation-triangle"></i>{% elif user.is_superuser and device.upgrade_available %} <i style="color: green;" title="Firmware upgrade available" class="fas fa-upload"></i>{% endif %} <div style="display: inline;" {% if user.is_superuser %}title="{{ device.organization.name }}"{% endif %} id="{{ device.id }}-id">{{ device.serial }}{% if device.ssid %}<br><small>SSID: {{ device.ssid }}</small>{% endif %}</div></td>
|
||||||
<td id="{{ device.id }}-name">{% if device.name %}{{ device.name }}{% endif %}</td>
|
<td id="{{ device.id }}-name">{% if device.name %}{{ device.name }}{% endif %}</td>
|
||||||
<td id="{{ device.id }}-network">{{ device.network }}</td>
|
<td id="{{ device.id }}-network">{{ device.network }}</td>
|
||||||
<td><div style="display:inline;" id="{{ device.id }}-ip">{% if device.curip %}{{ device.curip }} (at {{ device.lasttime }}){% endif %}</div></td>
|
<td><div style="display:inline;" id="{{ device.id }}-ip">{% if device.curip %}{{ device.curip }} (at {{ device.lasttime }}){% endif %}</div></td>
|
||||||
|
|
Loading…
Reference in a new issue