Add links to follow and unfollow Sones from the “Known Sones” page.
[Sone.git] / src / main / resources / templates / knownSones.html
1 <%include include/head.html>
2
3         <h1><%= Page.KnownSones.Page.Title|l10n|html></h1>
4
5         <div id="known-sones">
6                 <%foreach knownSones sone>
7                         <div>
8                                 <div class="profile-link"><a href="viewSone.html?sone=<% sone.id>" title="<% sone.requestUri|html>"><% sone.niceName|html></a></div>
9                                 <div class="last-update">(<%= View.Sone.Label.LastUpdate|l10n|html> <% sone.time|date format="MMM d, yyyy, HH:mm:ss">)</div>
10                                 <%ifnull ! currentSone>
11                                         <%if sone.isFriend>
12                                                 <form class="unfollow" action="unfollowSone.html" method="post">
13                                                         <input type="hidden" name="formPassword" value="<% formPassword|html>" />
14                                                         <input type="hidden" name="sone" value="<% sone.id>" />
15                                                         <button type="submit"><%= View.Sone.Button.UnfollowSone|l10n|html></button>
16                                                 </form>
17                                         <%else>
18                                                 <form class="follow" action="followSone.html" method="post">
19                                                         <input type="hidden" name="formPassword" value="<% formPassword|html>" />
20                                                         <input type="hidden" name="sone" value="<% sone.id>" />
21                                                         <button type="submit"><%= View.Sone.Button.FollowSone|l10n|html></button>
22                                                 </form>
23                                         <%/if>
24                                         <%if sone.isBlocked>
25                                                 <form class="unblock" action="unblockSone.html" method="post">
26                                                         <input type="hidden" name="formPassword" value="<% formPassword|html>" />
27                                                         <input type="hidden" name="sone" value="<% sone.id>" />
28                                                         <button type="submit"><%= View.Sone.Button.UnblockSone|l10n|html></button>
29                                                 </form>
30                                         <%else>
31                                                 <form class="block" action="blockSone.html" method="post">
32                                                         <input type="hidden" name="formPassword" value="<% formPassword|html>" />
33                                                         <input type="hidden" name="sone" value="<% sone.id>" />
34                                                         <button type="submit"><%= View.Sone.Button.BlockSone|l10n|html></button>
35                                                 </form>
36                                         <%/if>
37                                 <%/if>
38                         </div>
39                 <%foreachelse>
40                         <div><%= Page.KnownSones.Text.NoKnownSones|l10n|html></div>
41                 <%/foreach>
42         </div>
43
44 <%include include/tail.html>