Fix 2.4.2 upgrade notes formatting refs #19330
[arvados.git] / apps / workbench / app / views / projects / _index_projects.html.erb
1 <%# Copyright (C) The Arvados Authors. All rights reserved.
2
3 SPDX-License-Identifier: AGPL-3.0 %>
4
5 <div class="container-fluid arv-project-list">
6   <% tree.each do |projectnode| %>
7     <% rowtype = projectnode[:object].class %>
8     <% next if rowtype != Group and !show_root_node %>
9     <div class="<%= 'project' if rowtype.in?([Group,User]) %> row">
10       <div class="col-md-4" style="padding-left: <%= projectnode[:depth] - (show_root_node ? 0 : 1) %>em;">
11         <% if show_root_node and rowtype == String %>
12           <i class="fa fa-fw fa-share-alt"></i>
13           <%= projectnode[:object] %>
14         <% elsif show_root_node and rowtype == User %>
15           <% if projectnode[:object].uuid == current_user.andand.uuid %>
16             <i class="fa fa-fw fa-folder-o"></i>
17             <%= link_to project_path(id: projectnode[:object].uuid) do %>
18               Home
19             <% end %>
20           <% else %>
21             <i class="fa fa-fw fa-folder-o"></i>
22             <%= projectnode[:object].friendly_link_name %>
23           <% end %>
24         <% elsif rowtype == Group %>
25           <i class="fa fa-fw fa-folder-o"></i>
26           <%= link_to projectnode[:object] do %>
27             <%= projectnode[:object].friendly_link_name %>
28           <% end %>
29         <% end %>
30       </div>
31       <% if projectnode[:object].respond_to?(:description) and not projectnode[:object].description.blank? %>
32         <div class="col-md-8 small"><%= render_attribute_as_textile(projectnode[:object], "description", projectnode[:object].description, true) %></div>
33       <% end %>
34     </div>
35   <% end %>
36 </div>