feat(panel.html): change bg color based on status

This commit is contained in:
2025-06-16 12:10:39 +02:00
parent 7c98d16cc2
commit 6872348375

View File

@@ -28,8 +28,7 @@
{% for pc in pcs.values() %} {% for pc in pcs.values() %}
<tr> <tr>
<td><a href="{{ url_for('details', pc_id=pc.id) }}">{{ pc.id }}</a></td> <td><a href="{{ url_for('details', pc_id=pc.id) }}">{{ pc.id }}</a></td>
<td>{{ pc.status if pc.status else 'Unknown' }}</td> <td class='{% if pc.status == "online" %}green-bg{% elif pc.status == "offline" %}red-bg{% else %}yellow-bg{% endif %}'>{{ pc.status if pc.status else 'Unknown' }}</td> <td>{{ pc.last_seen if pc.last_seen else 'Never' }}</td>
<td>{{ pc.last_seen if pc.last_seen else 'Never' }}</td>
</tr> </tr>
{% else %} {% else %}
<tr> <tr>