Add 'tools/arvbox/' from commit 'd3d368758db1f4a9fa5b89f77b5ee61d68ef5b72'
[arvados.git] / apps / workbench / app / views / projects / show.html.erb
1 <% content_for :content_top do %>
2   <h2>
3     <% if @object.uuid == current_user.andand.uuid %>
4       Home
5     <% else %>
6       <%= render partial: "show_star" %>
7       <%= render_editable_attribute @object, 'name', nil, { 'data-emptytext' => "New project" } %>
8     <% end %>
9   </h2>
10 <% end %>
11
12 <% content_for :tab_line_buttons do %>
13   <% if @object.editable? %>
14     <div class="btn-group btn-group-sm">
15       <button type="button" class="btn btn-primary dropdown-toggle" data-toggle="dropdown"><i class="fa fa-fw fa-plus"></i> Add data <span class="caret"></span></button>
16       <ul class="dropdown-menu pull-right" role="menu">
17         <li>
18           <%= link_to(
19                 choose_collections_path(
20                   title: 'Choose a collection to copy into this project:',
21                   multiple: true,
22                   action_name: 'Copy',
23                   action_href: actions_path(id: @object.uuid),
24                   action_method: 'post',
25                   action_data: {selection_param: 'selection[]', copy_selections_into_project: @object.uuid, success: 'page-refresh'}.to_json),
26                 { remote: true, data: {'event-after-select' => 'page-refresh', 'toggle' => 'dropdown'} }) do %>
27             <i class="fa fa-fw fa-clipboard"></i> Copy data from another project
28           <% end %>
29         </li>
30         <li>
31           <%= link_to(collections_path(options: {ensure_unique_name: true}, collection: {manifest_text: "", name: "New collection", owner_uuid: @object.uuid}, redirect_to_anchor: 'Upload'), {
32               method: 'post',
33               data: {toggle: 'dropdown'}}) do %>
34             <i class="fa fa-fw fa-upload"></i> Upload files from my computer
35           <% end %>
36         </li>
37       </ul>
38     </div>
39     <%= link_to(
40           choose_pipeline_templates_path(
41             title: 'Choose a pipeline to run:',
42             action_name: 'Next: choose inputs <i class="fa fa-fw fa-arrow-circle-right"></i>',
43             action_href: pipeline_instances_path,
44             action_method: 'post',
45             action_data: {'selection_param' => 'pipeline_instance[pipeline_template_uuid]', 'pipeline_instance[owner_uuid]' => @object.uuid, 'success' => 'redirect-to-created-object'}.to_json),
46           { class: "btn btn-primary btn-sm", remote: true, title: "Run a pipeline in this project" }) do %>
47       <i class="fa fa-fw fa-gear"></i> Run a pipeline...
48     <% end %>
49     <%= link_to projects_path({'project[owner_uuid]' => @object.uuid, 'options' => {'ensure_unique_name' => true}}), method: :post, title: "Add a subproject to this project", class: 'btn btn-sm btn-primary' do %>
50       <i class="fa fa-fw fa-plus"></i>
51       Add a subproject
52     <% end %>
53   <% end %>
54 <% end %>
55
56 <%= render file: 'application/show.html.erb', locals: local_assigns %>