2871: add preload_objects_for_dataclass method to application_controller
[arvados.git] / apps / workbench / app / views / pipeline_templates / _show_recent.html.erb
1 <%= render partial: "paging", locals: {results: @objects, object: @object} %>
2
3 <table class="table table-condensed arv-index">
4   <colgroup>
5     <col width="8%" />
6     <col width="10%" />
7     <col width="22%" />
8     <col width="45%" />
9     <col width="15%" />
10   </colgroup>
11   <thead>
12     <tr class="contain-align-left">
13       <th>
14       </th><th>
15       </th><th>
16         name
17       </th><th>
18         description/components
19       </th><th>
20         owner
21       </th>
22     </tr>
23   </thead>
24   <tbody>
25
26     <% @objects.sort_by { |ob| ob[:created_at] }.reverse.each do |ob| %>
27
28     <tr>
29       <td>
30         <%= form_tag '/pipeline_instances' do |f| %>
31           <%= hidden_field :pipeline_instance, :pipeline_template_uuid, :value => ob.uuid %>
32           <%= button_tag nil, {class: "btn btn-default btn-xs", title: "Run #{ob.name}"} do %>
33             Run <i class="fa fa-fw fa-play"></i>
34           <% end %>
35         <% end %>
36       </td>
37       <td>
38         <%= render :partial => "show_object_button", :locals => {object: ob, size: 'xs'} %>
39       </td><td>
40         <%= render_editable_attribute ob, 'name' %>
41       </td><td>
42         <% if ob.respond_to?(:description) and ob.description %>
43           <%= ob.description %>
44           <br />
45         <% end %>
46         <% ob.components.collect { |k,v| k.to_s }.each do |k| %>
47           <span class="label label-default"><%= k %></span>
48         <% end %>
49       </td><td>
50         <%= link_to_if_arvados_object ob.owner_uuid, friendly_name: true %>
51       </td>
52     </tr>
53
54     <% end %>
55
56   </tbody>
57 </table>
58
59 <%= render partial: "paging", locals: {results: @objects, object: @object} %>