first commit
This commit is contained in:
57
templates/history.html
Normal file
57
templates/history.html
Normal file
@ -0,0 +1,57 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="pl">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Historia zapytan o {{ city }}</title>
|
||||
<style>
|
||||
body {
|
||||
font-family: Arial, sans-serif;
|
||||
background-color: #eef2f3;
|
||||
color: #333;
|
||||
margin: 20px;
|
||||
}
|
||||
h1 {
|
||||
color: #2a6ebb;
|
||||
}
|
||||
.error {
|
||||
color: red;
|
||||
font-weight: bold;
|
||||
}
|
||||
table {
|
||||
border-collapse: collapse;
|
||||
width: 60%;
|
||||
margin-top: 20px;
|
||||
}
|
||||
th, td {
|
||||
border: 1px solid #aaa;
|
||||
padding: 8px 12px;
|
||||
text-align: center;
|
||||
}
|
||||
th {
|
||||
background-color: #2a6ebb;
|
||||
color: #fff;
|
||||
}
|
||||
tr:nth-child(even) {
|
||||
background-color: #d9e1ec;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Historia zapytan o {{ city }}</h1>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th>Data</th>
|
||||
<th>Temperatura (°C)</th>
|
||||
<th>Wiatr (m/s)</th>
|
||||
</tr>
|
||||
{% for r in records %}
|
||||
<tr>
|
||||
<td>{{ r.time.strftime('%Y-%m-%d %H:%M') }}</td>
|
||||
<td>{{ r.temperature }}</td>
|
||||
<td>{{ r.windspeed }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user