From 928ab739e2b4b40077610a7913adb0cf086f2ee1 Mon Sep 17 00:00:00 2001
From: jan <jan@ruken.pw>
Date: Thu, 31 Dec 2015 11:24:43 +0100
Subject: =?UTF-8?q?material=20icons=20sind=20jetzt=20immer=20pr=C3=A4sent.?=
 =?UTF-8?q?=20listen=20werden=20jetzt=20nach=20der=20'order'=20des=20grils?=
 =?UTF-8?q?=20sortiert.?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit


diff --git a/modules/lists/lists.go b/modules/lists/lists.go
index b77120e..8957c5f 100644
--- a/modules/lists/lists.go
+++ b/modules/lists/lists.go
@@ -66,7 +66,7 @@ func (m *Module) Init(g *grilist.Grilist) {
 }
 
 func (m *Module) getListGrils(list *List) error {
-	rows, err := m.g.DB.Query(`SELECT gril_id, "order" FROM grilist.lists_grils WHERE list_id = $1`, list.ID)
+	rows, err := m.g.DB.Query(`SELECT gril_id, "order" FROM grilist.lists_grils WHERE list_id = $1 ORDER BY "order" ASC`, list.ID)
 	if err != nil {
 		return err
 	}
@@ -268,10 +268,10 @@ func (m *Module) displayCreateList(w http.ResponseWriter, r *http.Request, p htt
 		http.Redirect(w, r, "/", 302)
 		return
 	}
-	
+
 	data := m.g.Renderer.DefaultData()
 	data["user"] = user
-	
+
 	m.g.Renderer.RenderPage("create_list", w, data)
 }
 
@@ -282,7 +282,7 @@ func (m *Module) createList(w http.ResponseWriter, r *http.Request, p httprouter
 		http.Error(w, "500", http.StatusInternalServerError)
 		return
 	}
-	
+
 	values, err := readBody(r)
 	if err != nil {
 		log.Println(err)
@@ -297,7 +297,7 @@ func (m *Module) createList(w http.ResponseWriter, r *http.Request, p httprouter
 		http.Error(w, "500", http.StatusInternalServerError)
 		return
 	}
-	
+
 	http.Redirect(w, r, fmt.Sprintf("/list/%d", id), 302)
 }
 
diff --git a/views/create_list.html b/views/create_list.html
index 375dddd..ead61dd 100644
--- a/views/create_list.html
+++ b/views/create_list.html
@@ -3,7 +3,6 @@
 	<head>
 		{{ template "materialize" }}
 		<title>grilist</title>
-		<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
 		<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
 	</head>
 	<body>
diff --git a/views/list.html b/views/list.html
index daa56cd..fa58f91 100644
--- a/views/list.html
+++ b/views/list.html
@@ -7,7 +7,6 @@
 		<title>grilist</title>
 		<link rel="stylesheet" href="/assets/css/list.css" />
 		<link rel="stylesheet" href="/assets/css/search.css" />
-		<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
 		<script src="/assets/js/search.js"></script>
 		<script src="/assets/js/list.js"></script>
 		<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
@@ -15,7 +14,8 @@
 	<body>
 		{{ template "navbar" . }}
 		<div class="container">
-			<h1>{{ $list.Name }}<small>von {{ $list.Owner.GetName }}</small></h1><br />
+			<h1>{{ $list.Name }}<small>von {{ $list.Owner.GetName }}</small></h1>
+			<blockquote>{{ $list.Description }}</blockquote><br />
 			<div class="row">
 				<div class="col s12 {{ if ($user) and eq $user.ID $list.Owner.ID }}l8{{ end }}">
 					<ul class="gril-list">
diff --git a/views/login.html b/views/login.html
index 6014d4d..65c4857 100644
--- a/views/login.html
+++ b/views/login.html
@@ -3,7 +3,6 @@
 	<head>
 		<title>Grilist - Login</title>
 		{{ template "materialize" }}
-		<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
 	</head>
 	<body>
 		<div class="row">
diff --git a/views/materialize.html b/views/materialize.html
index 3648dc5..7c40c0d 100644
--- a/views/materialize.html
+++ b/views/materialize.html
@@ -1,5 +1,6 @@
 {{define "materialize"}}
 	<link rel="stylesheet" href="/assets/css/materialize.css">
 	<script src="/assets/js/materialize.min.js"></script>
+	<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
 	<meta name="viewport" content="width=device_width, initial-scale=1.0" />
 {{end}}
\ No newline at end of file
diff --git a/views/register.html b/views/register.html
index 3c78f46..b946518 100644
--- a/views/register.html
+++ b/views/register.html
@@ -3,7 +3,6 @@
 	<head>
 		<title>Grilist - Registration</title>
 		{{ template "materialize" }}
-		<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
 	</head>
 	<body>
 		<div class="row">
diff --git a/views/tag.html b/views/tag.html
index bc21fc3..d0d4180 100644
--- a/views/tag.html
+++ b/views/tag.html
@@ -4,7 +4,6 @@
 	<head>
 		{{ template "materialize" }}
 		<title>grilist</title>
-		<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
 		<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
 	</head>
 	<body>
-- 
cgit v0.10.1