Hash :
ba816e5c
Author :
Thomas de Grivel
Date :
2021-12-14T17:00:14
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82
<div class="container-fluid">
<h1>User <%= User.login(@user) %></h1>
<table class="table admin-properties">
<tr>
<th><%= gettext "Id" %></th>
<td><%= @user.id %></td>
</tr>
<tr>
<th><%= gettext "Name" %></th>
<td><%= @user.name %></td>
</tr>
<tr>
<th><%= gettext "Email" %></th>
<td><%= link @user.email, to: "mailto:#{@user.email}" %></td>
</tr>
<tr>
<th><%= gettext "Login" %></th>
<td><%= User.login(@user) %></td>
</tr>
<tr>
<th><%= gettext "Description" %></th>
<td>
<%= if @user.description do %>
<%= raw Earmark.as_html!(@user.description) %>
<% end %>
</td>
</tr>
<tr>
<th>
<%= gettext "Organisations" %>
</th>
<td>
<%= for org <- @user.organisations do %>
<%= link(org.name || org.slug.slug, to: Routes.admin_organisation_path(@conn, :show, org), class: "org") %>
<% end %>
</td>
</tr>
<tr>
<th><%= gettext "Repositories" %></th>
<td>
<ul>
<%= for repo <- @repos do %>
<li>
<%= link(Repository.full_slug(repo), to: Routes.admin_repository_path(@conn, :show, repo), class: "repo") %>
</li>
<% end %>
</ul>
</td>
</tr>
<tr>
<th><%= gettext "Admin" %></th>
<td><%= @user.is_admin %></td>
</tr>
<tr>
<th><%= gettext "Deploy only" %></th>
<td><%= @user.deploy_only %></td>
</tr>
<tr>
<th><%= gettext "SSH keys" %></th>
<td><pre class="admin_ssh_keys"><%= @user.ssh_keys %></pre></td>
</tr>
</table>
<%= link gettext("Delete user"),
to: Routes.admin_user_path(@conn, :delete, @user),
class: "btn btn-danger",
data: [confirm: gettext("Are you sure you want to delete this user ?")],
method: :delete %>
<%= link gettext("Edit user"),
to: Routes.admin_user_path(@conn, :edit, @user),
class: "btn btn-primary" %>
<%= link gettext("Edit password"),
to: Routes.admin_user__path(@conn, :edit_password, @user),
class: "btn btn-primary" %>
<%= link gettext("Show"),
to: Routes.slug_path(@conn, :show, User.login(@user) || ""),
class: "btn btn-primary" %>
</div>