Add optional parameter to hide moving buttons
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sat, 1 Aug 2015 20:58:13 +0000 (22:58 +0200)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sat, 1 Aug 2015 20:58:13 +0000 (22:58 +0200)
src/main/resources/templates/include/viewAlbum.html

index bf9ea78..10e8368 100644 (file)
                <div class="title"><a href="imageBrowser.html?album=<% album.id|html>"><% album.title|html></a></div>
                <div class="author"><% =View.Album.SizeAndAuthor|l10n 0=album.sone.niceName 1=album.images.size|html|replace needle=="[link]" replacement=='<a href="viewSone.html?sone=<sone-id>">'|replace needle=='[/link]' replacement=='</a>'|replace needle=='<sone-id>' replacement=album.sone.id></div>
                <%if album.sone.local>
-                       <form class="edit-album" action="editAlbum.html" method="post">
-                               <input type="hidden" name="formPassword" value="<%formPassword|html>" />
-                               <input type="hidden" name="returnPage" value="<%request.uri|html>" />
-                               <input type="hidden" name="album" value="<%album.id|html>" />
-                               <div class="move-buttons">
-                                       <button <%if loop.first>class="hidden" <%/if>type="submit" name="moveLeft" value="true"><%= Page.ImageBrowser.Image.Button.MoveLeft|l10n|html></button>
-                                       <button <%if loop.last>class="hidden" <%/if>type="submit" name="moveRight" value="true"><%= Page.ImageBrowser.Image.Button.MoveRight|l10n|html></button>
-                               </div>
-                       </form>
+                       <%if !hideMoveButtons>
+                               <form class="edit-album" action="editAlbum.html" method="post">
+                                       <input type="hidden" name="formPassword" value="<%formPassword|html>" />
+                                       <input type="hidden" name="returnPage" value="<%request.uri|html>" />
+                                       <input type="hidden" name="album" value="<%album.id|html>" />
+                                       <div class="move-buttons">
+                                               <button <%if loop.first>class="hidden" <%/if>type="submit" name="moveLeft" value="true"><%= Page.ImageBrowser.Image.Button.MoveLeft|l10n|html></button>
+                                               <button <%if loop.last>class="hidden" <%/if>type="submit" name="moveRight" value="true"><%= Page.ImageBrowser.Image.Button.MoveRight|l10n|html></button>
+                                       </div>
+                               </form>
+                       <%/if>
                <%/if>
                <div class="description"><% album.description|parse sone=album.sone|render></div>
        </div>