From: David ‘Bombe’ Roden Date: Mon, 7 Mar 2011 16:34:22 +0000 (+0100) Subject: Show hint if some posts could not be shown. X-Git-Tag: 0.4.4^2~4 X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=commitdiff_plain;h=f5ae451a5603ac8865d731e059d656a6dc47d515 Show hint if some posts could not be shown. --- diff --git a/src/main/resources/i18n/sone.en.properties b/src/main/resources/i18n/sone.en.properties index 2165bb5..4c85ab0 100644 --- a/src/main/resources/i18n/sone.en.properties +++ b/src/main/resources/i18n/sone.en.properties @@ -167,6 +167,7 @@ Page.Unbookmark.Title=Remove Bookmark - Sone Page.Bookmarks.Title=Bookmarks - Sone Page.Bookmarks.Page.Title=Bookmarks Page.Bookmarks.Text.NoBookmarks=You don’t have any bookmarks defined right now. You can bookmark posts by clicking the star below the post. +Page.Bookmarks.Text.PostsNotLoaded=Some of your bookmarked posts have not been shown because they could not be loaded. This can happen if your restarted Sone recently or if the originating Sone has deleted the post. Page.NoPermission.Title=Unauthorized Access - Sone Page.NoPermission.Page.Title=Unauthorized Access diff --git a/src/main/resources/templates/bookmarks.html b/src/main/resources/templates/bookmarks.html index ddf2bfc..af592db 100644 --- a/src/main/resources/templates/bookmarks.html +++ b/src/main/resources/templates/bookmarks.html @@ -7,10 +7,20 @@
<%include include/pagination.html> <%foreach posts post> - <%include include/viewPost.html> - <%foreachelse> -

<%= Page.Bookmarks.Text.NoBookmarks|l10n|html>

+ <%if post.loaded> + <%= true|store key=postShown> + <%include include/viewPost.html> + <%else> + <%= true|store key=postNotLoaded> + <%/if> <%/foreach> + <%if postNotLoaded> +

<%= Page.Bookmarks.Text.PostsNotLoaded|l10n|html>

+ <%else> + <%if !postShown> +

<%= Page.Bookmarks.Text.NoBookmarks|l10n|html>

+ <%/if> + <%/if> <%include include/pagination.html>