Show hint if some posts could not be shown.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Mon, 7 Mar 2011 16:34:22 +0000 (17:34 +0100)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Mon, 7 Mar 2011 16:34:22 +0000 (17:34 +0100)
src/main/resources/i18n/sone.en.properties
src/main/resources/templates/bookmarks.html

index 2165bb5..4c85ab0 100644 (file)
@@ -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
index ddf2bfc..af592db 100644 (file)
@@ -7,10 +7,20 @@
        <div id="posts">
                <%include include/pagination.html>
                <%foreach posts post>
-                       <%include include/viewPost.html>
-               <%foreachelse>
-                       <p><%= Page.Bookmarks.Text.NoBookmarks|l10n|html></p>
+                       <%if post.loaded>
+                               <%= true|store key=postShown>
+                               <%include include/viewPost.html>
+                       <%else>
+                               <%= true|store key=postNotLoaded>
+                       <%/if>
                <%/foreach>
+               <%if postNotLoaded>
+                       <p><%= Page.Bookmarks.Text.PostsNotLoaded|l10n|html></p>
+               <%else>
+                       <%if !postShown>
+                               <p><%= Page.Bookmarks.Text.NoBookmarks|l10n|html></p>
+                       <%/if>
+               <%/if>
                <%include include/pagination.html>
        </div>