2016-02-12 23:52:43 +08:00
|
|
|
<h5 class="text-center"><%= t("projects.index.users_tab") %></h5>
|
|
|
|
<hr>
|
2019-01-08 23:30:52 +08:00
|
|
|
<ul class="no-style content-users" data-hook="project-users-tab-list">
|
2016-02-12 23:52:43 +08:00
|
|
|
<% if @users.size == 0 then %>
|
|
|
|
<li><em><%= t 'projects.index.no_users' %></em></li>
|
|
|
|
<% else %>
|
2017-06-29 18:56:14 +08:00
|
|
|
<% @users.each_with_index do |user_proj, i| user = user_proj.user %>
|
2016-02-12 23:52:43 +08:00
|
|
|
<li>
|
|
|
|
<% if i > 0 %><hr><% end %>
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-xs-2">
|
2019-05-21 21:19:44 +08:00
|
|
|
<span class='global-avatar-container'>
|
|
|
|
<%= image_tag avatar_path(user, :icon_small), class: 'img-circle pull-left' %>
|
|
|
|
</span>
|
2016-02-12 23:52:43 +08:00
|
|
|
</div>
|
2019-05-21 21:19:44 +08:00
|
|
|
<div class="col-xs-10" style="line-height: 15px">
|
2017-06-29 18:56:14 +08:00
|
|
|
<span><%= user.full_name %></span>
|
2017-06-28 23:15:09 +08:00
|
|
|
<br><span class="text-muted"><%= t('user_projects.enums.role.'<< user_proj.role.to_s) %></span>
|
2016-02-12 23:52:43 +08:00
|
|
|
</div>
|
2018-02-03 01:48:55 +08:00
|
|
|
</div>
|
2016-02-12 23:52:43 +08:00
|
|
|
</li>
|
|
|
|
<% end %>
|
|
|
|
<% end %>
|
2016-07-21 19:11:15 +08:00
|
|
|
</ul>
|
2018-02-03 01:48:55 +08:00
|
|
|
<% if can_manage_project?(@project) %>
|
2018-02-19 21:47:36 +08:00
|
|
|
<p>
|
|
|
|
<hr>
|
|
|
|
<%= link_to t("projects.index.manage_users"), project_users_edit_path(@project, format: :json), class: "manage-users-link", remote: true %>
|
|
|
|
</p>
|
|
|
|
<% end %>
|