% provide(:head_title, t("users.settings.organizations.head_title")) %> <%= render partial: "users/settings/navigation.html.erb" %>
<%=t "users.settings.organizations.index.thead_name" %> | <%=t "users.settings.organizations.index.thead_role" %> | <%=t "users.settings.organizations.index.thead_created_at" %> | <%=t "users.settings.organizations.index.thead_joined_on" %> | <%=t "users.settings.organizations.index.thead_members" %> | |
---|---|---|---|---|---|
<% if user_org.admin? %> <%= link_to org.name, organization_path(org) %> <% else %> <%= org.name %> <% end %> | <%= user_org.role_str %> | <% if user_org.guest? %> <%= t("users.settings.organizations.index.na") %> <% else %> <%= l(org.created_at, format: :full) %> <% end %> | <%= l(user_org.created_at, format: :full) %> | <% if user_org.guest? %> <%= t("users.settings.organizations.index.na") %> <% else %> <%= org.users.count %> <% end %> |
<% if user_org.admin? && org.user_organizations.where(role: 2).count <= 1 %>
<%= t("users.settings.organizations.index.leave") %>
<% else %>
<%= link_to leave_user_organization_html_path(user_org, format: :json), remote: true, class: "btn btn-default btn-xs", type: "button", data: { action: "leave-user-organization" } do %>
<%= t("users.settings.organizations.index.leave") %>
<% end %>
<% end %>
|