otwarchive-symphonyarchive/app/views/users/_header_navigation.html.erb

24 lines
1 KiB
Text
Raw Normal View History

2026-03-11 22:22:11 +00:00
<% # expects @user to be set %>
<ul class="navigation actions" role="navigation">
<% if @user == current_user %>
<li><%= link_to t(".new_work"), new_work_path %></li>
<li><%= span_if_current t(".edit_multiple"), (path = show_multiple_user_works_path(@user)),
current_page?(path) && params[:work_ids].blank? %></li>
<button><%= link_to t("New Status!"), new_user_status_path(current_user) %></button> <% end %>
<% if current_user && @subscription %>
<li>
<%= render :partial => 'subscriptions/form', :locals => { :subscription => @subscription } %>
</li>
<% end %>
<% if @user == current_user || policy(User).can_manage_users? %>
<li><%= span_if_current t(".invitations"), user_invitations_path(@user) %></li>
<% end %>
<% if current_user && @user != current_user %>
<li><%= block_link(@user) %></li>
<li><%= mute_link(@user) %></li>
<% end %>
<% if policy(User).can_manage_users? %>
<li><%= link_to t(".admin_user"), admin_user_path(@user) %></li>
<% end %>
</ul>