aboutsummaryrefslogtreecommitdiff
path: root/shardweb/lib/templates/identity
diff options
context:
space:
mode:
Diffstat (limited to 'shardweb/lib/templates/identity')
-rw-r--r--shardweb/lib/templates/identity/list.html.eex12
1 files changed, 11 insertions, 1 deletions
diff --git a/shardweb/lib/templates/identity/list.html.eex b/shardweb/lib/templates/identity/list.html.eex
index 1354264..007af3d 100644
--- a/shardweb/lib/templates/identity/list.html.eex
+++ b/shardweb/lib/templates/identity/list.html.eex
@@ -20,11 +20,21 @@
<table class="table table-striped">
<tr>
<th>User name</th>
+ <th></th>
<th>Public key</th>
</tr>
<%= for {_id, manifest, pid} <- people_list() do %>
<tr>
- <td><i class="fa fa-user"></i> <%= GenServer.call(pid, :get_info).nick %> </td>
+ <td><i class="fa fa-user"></i> <%= GenServer.call(pid, :get_info).nick %>
+ <%= if manifest.pk == @pk do %>
+ <span class="badge badge-success"><i class="fa fa-user"></i> myself</span>
+ <% end %>
+ </td>
+ <td>
+ <%= if manifest.pk != @pk do %>
+ <a class="btn btn-xs btn-primary" href="<%= chat_path(@conn, :privchat, manifest.pk |> Base.encode16) %>"><i class="fa fa-comments"></i> PM</a>
+ <% end %>
+ </td>
<td><small><%= manifest.pk |> Base.encode16 %></small></td>
</tr>
<% end %>