Merge branch 'master' into 4036-combine-collections-in-project-issue
[arvados.git] / apps / workbench / app / views / projects / _show_tab_contents.html.erb
1 <div class="selection-action-container">
2   <div class="row">
3     <div class="col-sm-5">
4       <div class="btn-group btn-group-sm">
5         <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">Selection... <span class="caret"></span></button>
6         <ul class="dropdown-menu" role="menu">
7           <li><%= link_to "Create new collection with selected collections", '#',
8                   'data-href' => combine_selected_path(
9                     action_data: {current_project_uuid: @object.uuid}.to_json
10                   ),
11                   'id' => 'combine_selections_button',
12                   'data-selection-param-name' => 'selection[]',
13                   'data-selection-action' => 'combine-project-contents',
14                   'method' => 'post',
15                   'data-toggle' => 'dropdown'
16             %></li>
17           <li><%= link_to "Compare selected", 'action',
18                   'data-href' => compare_pipeline_instances_path,
19                   'data-selection-param-name' => 'uuids[]',
20                   'data-selection-action' => 'compare'
21             %></li>
22           <li><%= link_to "Copy selected", '#',
23                   'data-href' => choose_projects_path(
24                     title: 'Copy selected items to...',
25                     editable: true,
26                     action_name: 'Copy',
27                     action_href: actions_path,
28                     action_method: 'post',
29                     action_data_from_params: ['selection'],
30                     action_data: {
31                       copy_selections_into_project: true,
32                       selection_param: 'uuid',
33                       success: 'page-refresh'}.to_json),
34                   'data-remote' => true,
35                   'data-selection-param-name' => 'selection[]',
36                   'data-selection-action' => 'copy'
37             %></li>
38           <li><%= link_to "Move selected", '#',
39                   'data-href' => choose_projects_path(
40                     title: 'Move selected items to...',
41                     editable: true,
42                     action_name: 'Move',
43                     action_href: actions_path,
44                     action_method: 'post',
45                     action_data_from_params: ['selection'],
46                     action_data: {
47                       move_selections_into_project: true,
48                       selection_param: 'uuid',
49                       success: 'page-refresh'}.to_json),
50                   'data-remote' => true,
51                   'data-selection-param-name' => 'selection[]',
52                   'data-selection-action' => 'move'
53             %></li>
54           <li><%= link_to "Remove selected", '#',
55                   'data-href' => url_for(action: :remove_items),
56                   'data-selection-param-name' => 'item_uuids[]',
57                   'data-selection-action' => 'remove',
58                   'data-remote' => true,
59                   'method' => 'delete',
60                   'data-toggle' => 'dropdown'
61             %></li>
62         </ul>
63       </div>
64     </div>
65     <div class="col-sm-4 pull-right">
66       <input type="text" class="form-control filterable-control" placeholder="Search project contents" data-filterable-target="table.arv-index.arv-project-<%= tab_pane %> tbody"/>
67     </div>
68   </div>
69
70   <table class="table table-condensed arv-index arv-project-<%= tab_pane %>">
71     <colgroup>
72       <col width="0*" style="max-width: fit-content;" />
73       <col width="0*" style="max-width: fit-content;" />
74       <col width="0*" style="max-width: fit-content;" />
75       <col width="60%" style="width: 60%;" />
76       <col width="40%" style="width: 40%;" />
77     </colgroup>
78     <tbody data-infinite-scroller="#<%= tab_pane %>-scroll" data-infinite-content-href="<%= url_for partial: :contents_rows %>" data-infinite-content-params-projecttab="<%= {filters: filters}.to_json %>">
79     </tbody>
80     <thead>
81       <tr>
82         <th></th>
83         <th></th>
84         <th></th>
85         <th>name</th>
86         <th>description</th>
87       </tr>
88     </thead>
89   </table>
90 </div>