🚨 — HTML linting

This commit is contained in:
Luc Didry 2023-11-21 15:52:06 +01:00
parent d2a12aea30
commit 1f33110e68
5 changed files with 54 additions and 54 deletions

View file

@ -9,7 +9,6 @@
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
{% for result in last_seen %} {% for result in last_seen %}
<tr> <tr>
<td>{{ result.agent_id }}</td> <td>{{ result.agent_id }}</td>

View file

@ -3,14 +3,17 @@
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>Argos</title> <title>Argos</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="IE=Edge">
<link href="{{ url_for('static', path='/styles.css') }}" rel="stylesheet"> <link href="{{ url_for('static', path='/styles.css') }}" rel="stylesheet">
</head> </head>
<body> <body>
<main class="container"> <main class="container">
<div id="header"> <div id="header">
{% block title %}<a href="/"><h1 id="title">Argos monitoring</h1></a>{% endblock %} {% block title %}
<a href="/"><h1 id="title">Argos monitoring</h1></a>
{% endblock %}
</div> </div>
<div id="content"> <div id="content">
{% block content %} {% block content %}
{% endblock %} {% endblock %}

View file

@ -5,30 +5,28 @@
{{ domains | length}} domains, {{ domains | length}} domains,
{{ total_task_count }} tasks, {{ total_task_count }} tasks,
<a href="/agents">{{ agents | length }} agent{% if agents | length > 1 %}s{% endif %}</a> <a href="/agents">{{ agents | length }} agent{% if agents | length > 1 %}s{% endif %}</a>
</p> </p>
<table id="domains-list" role="grid"> <table id="domains-list" role="grid">
<thead> <thead>
<tr> <tr>
<th>Domain</th> <th>Domain</th>
<th class="today">Current status</th> <th class="today">Current status</th>
<th>Last check</th> <th>Last check</th>
</tr>
</thead> </thead>
<tbody id="domains-body"> <tbody id="domains-body">
{% for (domain, status) in domains %} {% for (domain, status) in domains %}
<tr> <tr>
<td> <td>
<a href="/domain/{{domain}}"> <a href="/domain/{{ domain }}">{{ domain }}</a>
{{ domain }} </a> </td>
<td class="status highlight">
{% if status == "ok" %}✅ OK {% elif statuts == "warning"%}⚠ Warning{% elif status == "critical"%}❌ Critical{% elif status == "to-process" %}⏱︎ Waiting for the jobs{% endif %}
</td> </td>
<td class="status highlight">{% if status == "ok" %}✅ OK {% elif statuts == "warning"%}⚠ Warning{% elif status == "critical"%}❌ Critical{% elif status == "to-process" %}⏱︎ Waiting for the jobs{% endif %}</td>
<td>{{ last_checks.get(domain) }}</td> <td>{{ last_checks.get(domain) }}</td>
</tr> </tr>
{% endfor %} {% endfor %}
</tbody> </tbody>
</table> </table>
</div> </div>

View file

@ -19,11 +19,12 @@
<td>{{ task.url }}</td> <td>{{ task.url }}</td>
<td>{{ task.check }}</td> <td>{{ task.check }}</td>
<td>{{ task.expected }}</td> <td>{{ task.expected }}</td>
<td class="status highlight"><a data-tooltip="Completed at {{ task.completed_at }}" href="/result/{{ task.last_result.id }}">{% if task.status == "success" %}✅ Success {% elif task.status == "error"%}⚠ Error{% elif task.status == "failure"%}❌ Failure{% endif %}</a></td> <td class="status highlight">
<a data-tooltip="Completed at {{ task.completed_at }}" href="/result/{{ task.last_result.id }}">{% if task.status == "success" %}✅ Success {% elif task.status == "error"%}⚠ Error{% elif task.status == "failure"%}❌ Failure{% endif %}</a>
</td>
<td><a href="/task/{{task.id}}/results">view all</a></td> <td><a href="/task/{{task.id}}/results">view all</a></td>
</tr> </tr>
{% endfor %} {% endfor %}
</tbody> </tbody>
</table> </table>
</div> </div>

View file

@ -13,5 +13,4 @@
<dt>Context</dt> <dt>Context</dt>
<dd>{{ result.context }}</dd> <dd>{{ result.context }}</dd>
</dl> </dl>
{% endblock %} {% endblock %}