<% if CurrentUser.is_manager? %>
<% if key.owner.avatar.attached? %> <%= image_tag(key.owner.avatar, width: 30, height: 30, class: "rounded-4") %> <% end %> <%= key.owner.name %>
<% end %>
<%= key.application_name %>

<%= key.usage %>

Services

<%= key.access_string %>

<% if key.disabled? %>
Disabled

<%= key.disabled_reason || "No Reason Provided" %>

<% end %> <% unless key.active? %>
Inactive
<% end %>
<% if key.can_view?(CurrentUser) %> <% end %> <% if key.can_edit?(CurrentUser) %> <% if CurrentUser.is_admin? %> <%= link_to "Edit", edit_yiff_rest_apikey_path(key), class: "btn btn-success" %> <% else %> <% end %> <% end %> <% if key.can_delete?(CurrentUser) %> <% end %>