summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorElizabeth Hunt <elizabeth.hunt@simponic.xyz>2024-04-21 18:46:40 -0700
committerElizabeth Hunt <elizabeth.hunt@simponic.xyz>2024-04-21 18:46:40 -0700
commitd14605d1388aaa7cc9ef1c230eae5ba14c9cef44 (patch)
tree59fcda0fae7899ca577eed1f72d89bff17d5ad5d /templates
downloadbackup-notify-d14605d1388aaa7cc9ef1c230eae5ba14c9cef44.tar.gz
backup-notify-d14605d1388aaa7cc9ef1c230eae5ba14c9cef44.zip
initial commit
Diffstat (limited to 'templates')
-rw-r--r--templates/404.html7
-rw-r--r--templates/backup_list.html27
-rw-r--r--templates/base.html18
-rw-r--r--templates/base_empty.html3
4 files changed, 55 insertions, 0 deletions
diff --git a/templates/404.html b/templates/404.html
new file mode 100644
index 0000000..35b43bb
--- /dev/null
+++ b/templates/404.html
@@ -0,0 +1,7 @@
+{{ define "content" }}
+<h1>page not found</h1>
+<p><em>but hey, at least you found our witty 404 page. that's something, right?</em></p>
+
+<p><a href="/">go back home</a></p>
+
+{{ end }} \ No newline at end of file
diff --git a/templates/backup_list.html b/templates/backup_list.html
new file mode 100644
index 0000000..82256b1
--- /dev/null
+++ b/templates/backup_list.html
@@ -0,0 +1,27 @@
+{{ define "content" }}
+ {{ if (eq (len .HostStatusOverTime) 0) }}
+ no backups yet!
+ {{ end }}
+
+ {{ range $hostname, $backupList := .HostStatusOverTime }}
+ <div>{{ $hostname }}</div><br>
+ <table>
+ <tr>
+ {{ range $i, $_ := $backupList }}
+ <th>{{ $i }}</th>
+ {{ end }}
+ </tr>
+ <tr>
+ {{ range $seen := $backupList }}
+ {{ if $seen }}
+ <td class="success">x</td>
+ {{ else }}
+ <td class="error">!!</td>
+ {{ end }}
+ </td>
+ {{ end }}
+ </tr>
+ </table>
+ <br><hr><br>
+ {{ end }}
+{{ end }}
diff --git a/templates/base.html b/templates/base.html
new file mode 100644
index 0000000..c8766c0
--- /dev/null
+++ b/templates/base.html
@@ -0,0 +1,18 @@
+{{ define "base" }}
+<!DOCTYPE html>
+<html>
+ <head>
+ <title>backup notify</title>
+ <meta charset="utf-8">
+ <meta name="viewport" content=
+ "width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
+ <link rel="stylesheet" type="text/css" href=
+ "/static/css/styles.css">
+ </head>
+ <body data-theme="DARK">
+ <div id="content" class="container">
+ {{ template "content" . }}
+ </div>
+ </body>
+</html>
+{{ end }}
diff --git a/templates/base_empty.html b/templates/base_empty.html
new file mode 100644
index 0000000..6191ab9
--- /dev/null
+++ b/templates/base_empty.html
@@ -0,0 +1,3 @@
+{{ define "base" }}
+ {{ template "content" . }}
+{{ end }} \ No newline at end of file