lens @ bf23e30e4c6c548b94479b57aae5ebec14f9c95a

fix: Fix album and media navidation
diff --git a/pkg/view/album.go b/pkg/view/album.go
index a96b9bd89530fbb8e557a68e2c4fb2f299784748..9e70b4b7b832bae74032c8d9ca67cfac613de5b8 100644
--- a/pkg/view/album.go
+++ b/pkg/view/album.go
@@ -85,8 +85,9 @@ 		Medias: medias,
 		Albums: albums,
 		Name:   album.Name,
 		Next: &repository.Pagination{
-			Size: p.Size,
-			Page: p.Page + 1,
+			Size:    p.Size,
+			Page:    p.Page + 1,
+			AlbumID: &album.ID,
 		},
 		Settings: settings,
 	}
diff --git a/pkg/view/media.go b/pkg/view/media.go
index d5aace24688b861992e6f6147889e9b5a25eb5ac..f490ce1e77f979d19c995e17be7b382a34aee3d1 100644
--- a/pkg/view/media.go
+++ b/pkg/view/media.go
@@ -44,8 +44,7 @@ 		page = p
 	}
 
 	if albumIDStr == "" {
-		id := uint(0)
-		albumID = &id
+		albumID = nil
 	} else if p, err := strconv.Atoi(albumIDStr); err == nil {
 		id := uint(p)
 		albumID = &id
@@ -133,9 +132,9 @@ 	return nil
 }
 
 func (self *MediaView) SetMyselfIn(r *ext.Router) {
-	r.GET("/media", self.Index)
-	r.POST("/media", self.Index)
+	r.GET("/media/", self.Index)
+	r.POST("/media/", self.Index)
 
-	r.GET("/media/image", self.GetImage)
-	r.GET("/media/thumbnail", self.GetThumbnail)
+	r.GET("/media/image/", self.GetImage)
+	r.GET("/media/thumbnail/", self.GetThumbnail)
 }
diff --git a/templates/album.qtpl b/templates/album.qtpl
index 1f25bf6a6e2aa62127718cc5c94e62d908a57568..835db5703c2c07cc98145f76fd435e52d4f5707e 100644
--- a/templates/album.qtpl
+++ b/templates/album.qtpl
@@ -30,7 +30,7 @@ <div class="columns">
 {%= Mosaic(p.Medias, p.PreloadAttr()) %}
 </div>
 <div>
-    <a href="/media?page={%d p.Next.Page %}" class="button is-pulled-right">next</a>
+    <a href="/album/?albumId={%s FromUInttoString(p.Next.AlbumID) %}&page={%d p.Next.Page %}" class="button is-pulled-right">next</a>
 </div>
 {% endfunc %}
 
diff --git a/templates/media.qtpl b/templates/media.qtpl
index 737d03d63a2ae301fc37dd3a9926e216a6fe325a..4251deb32c1b561ecdbad544bb7adbe42fec0571 100644
--- a/templates/media.qtpl
+++ b/templates/media.qtpl
@@ -22,7 +22,7 @@ <div class="columns">
 {%= Mosaic(p.Medias, p.PreloadAttr()) %}
 </div>
 <div>
-    <a href="/media?page={%d p.Next.Page %}" class="button is-pulled-right">next</a>
+    <a href="/media/?page={%d p.Next.Page %}" class="button is-pulled-right">next</a>
 </div>
 {% endfunc %}
 
diff --git a/templates/mosaic.qtpl b/templates/mosaic.qtpl
index 18dbcba489fef78faa1326522e834762f3efadba..3e6ccf86d9ac5359d8a2a097af4269589af25fb7 100644
--- a/templates/mosaic.qtpl
+++ b/templates/mosaic.qtpl
@@ -8,12 +8,12 @@     <div class="column is-2">
     {% for _, media := range c %}
     <div class="card-image">
        {% if media.IsVideo() %}
-       <video class="image is-fit" controls muted="true" poster="/media/thumbnail?path_hash={%s media.PathHash %}" preload="{%s preloadAttr %}">
-           <source src="/media/image?path_hash={%s media.PathHash %}" type="{%s media.MIMEType %}">
+       <video class="image is-fit" controls muted="true" poster="/media/thumbnail/?path_hash={%s media.PathHash %}" preload="{%s preloadAttr %}">
+           <source src="/media/image/?path_hash={%s media.PathHash %}" type="{%s media.MIMEType %}">
        </video>
        {% else %}
         <figure class="image is-fit">
-            <img src="/media/thumbnail?path_hash={%s media.PathHash %}">
+            <img src="/media/thumbnail/?path_hash={%s media.PathHash %}">
         </figure>
         {% endif %}
     </div>