aboutsummaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
authorjan <jan@ruken.pw>2015-12-25 20:37:02 (UTC)
committerjan <jan@ruken.pw>2015-12-25 20:37:02 (UTC)
commita31b9dbddf94dba7be23fcb67b169e1fe5ffc81b (patch)
tree7ac12a3bd3fd44460f8cc8e1286575c09ebc95e2 /views
parent3a79416f963d1c72298ac4eaf842e3fedd323022 (diff)
simple list & gril view und parsing
Diffstat (limited to 'views')
-rw-r--r--views/gril.html21
-rw-r--r--views/list.html26
2 files changed, 47 insertions, 0 deletions
diff --git a/views/gril.html b/views/gril.html
new file mode 100644
index 0000000..d62fc75
--- /dev/null
+++ b/views/gril.html
@@ -0,0 +1,21 @@
1{{ define "gril" }}
2{{ $gril := .gril }}
3<html>
4 <head>
5 {{ template "materialize" }}
6 <title>grilist</title>
7 <link rel="stylesheet" href="/assets/css/gril.css" />
8 <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
9 </head>
10 <body>
11 <div class="container">
12 {{ if .loggedIn }}
13 <div class="row right-align">
14 <a class="waves-effect waves-teal btn-flat large" style="top: 24px; font-size: 18px" href="/logout">Ausloggen</a>
15 </div>
16 {{ end }}
17 <h1>{{ $gril.RomajiName }}<small>{{ $gril.KanjiName }}</small></h1>
18 </div>
19 </body>
20</html>
21{{ end }} \ No newline at end of file
diff --git a/views/list.html b/views/list.html
new file mode 100644
index 0000000..63cfd9c
--- /dev/null
+++ b/views/list.html
@@ -0,0 +1,26 @@
1{{ define "list" }}
2{{ $list := .list }}
3<html>
4 <head>
5 {{ template "materialize" }}
6 <title>grilist</title>
7 <link rel="stylesheet" href="/assets/css/gril.css" />
8 <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
9 </head>
10 <body>
11 <div class="container">
12 {{ if .loggedIn }}
13 <div class="row right-align">
14 <a class="waves-effect waves-teal btn-flat large" style="top: 24px; font-size: 18px" href="/logout">Ausloggen</a>
15 </div>
16 {{ end }}
17 <h1>{{ $list.Name }}<small>von xyz</small></h1><br />
18 <ul>
19 {{ range $lg := $list.Grils }}
20 <li><a href="/gril/{{ $lg.Gril.ID }}">{{ $lg.Gril.RomajiName }}</a></li>
21 {{ end }}
22 </ul>
23 </div>
24 </body>
25</html>
26{{ end }} \ No newline at end of file