12863: Adds CR's state label on description cell.
authorLucas Di Pentima <ldipentima@veritasgenetics.com>
Tue, 13 Feb 2018 13:56:44 +0000 (10:56 -0300)
committerLucas Di Pentima <ldipentima@veritasgenetics.com>
Tue, 13 Feb 2018 13:56:44 +0000 (10:56 -0300)
Arvados-DCO-1.1-Signed-off-by: Lucas Di Pentima <ldipentima@veritasgenetics.com>

apps/workbench/app/views/container_requests/_show_object_description_cell.html.erb [new file with mode: 0644]
apps/workbench/app/views/container_requests/_state_label.html.erb [new file with mode: 0644]
apps/workbench/app/views/projects/_show_contents_rows.html.erb
apps/workbench/app/views/projects/_show_tab_contents.html.erb

diff --git a/apps/workbench/app/views/container_requests/_show_object_description_cell.html.erb b/apps/workbench/app/views/container_requests/_show_object_description_cell.html.erb
new file mode 100644 (file)
index 0000000..2df207a
--- /dev/null
@@ -0,0 +1,8 @@
+<%# Copyright (C) The Arvados Authors. All rights reserved.
+
+SPDX-License-Identifier: AGPL-3.0 %>
+
+<div class="nowrap">
+  <%= object.content_summary %><br />
+  <%= render partial: 'container_requests/state_label', locals: {object: object} %>
+</div>
diff --git a/apps/workbench/app/views/container_requests/_state_label.html.erb b/apps/workbench/app/views/container_requests/_state_label.html.erb
new file mode 100644 (file)
index 0000000..1ddd2b2
--- /dev/null
@@ -0,0 +1,8 @@
+<%# Copyright (C) The Arvados Authors. All rights reserved.
+
+SPDX-License-Identifier: AGPL-3.0 %>
+
+<% wu = object.work_unit object.name %>
+<span class="label label-<%=wu.state_bootstrap_class%>">
+  <%=wu.state_label%>
+</span>
index f22af3b76b65a4a71e0be44bea6d46ac47cbf9ee..d440c4670c831c9c17d29738cb68195d28719891 100644 (file)
@@ -29,15 +29,6 @@ SPDX-License-Identifier: AGPL-3.0 %>
       <%= render :partial => "show_object_button", :locals => {object: object, size: 'sm', name_link: name_link} %>
     </td>
 
-    <td>
-    <% if object.respond_to?(:work_unit) %>
-      <% wu = object.work_unit object.name %>
-      <span class="label label-<%=wu.state_bootstrap_class%>">
-        <%=wu.state_label%>
-      </span>
-    <% end %>
-    </td>
-
     <td>
       <% if object.respond_to?(:name) %>
         <%= render_editable_attribute (name_link || object), 'name', nil, {}, {tiptitle: 'rename'} %>
index 4b37cda2df8a9a94a5ceb38e0b9c982f780a0601..2e5c8a3b7fddb3042e23f63209c79b16109cd2d4 100644 (file)
@@ -90,7 +90,6 @@ SPDX-License-Identifier: AGPL-3.0 %>
       <col width="0*" style="max-width: fit-content;" />
       <col width="0*" style="max-width: fit-content;" />
       <col width="0*" style="max-width: fit-content;" />
-      <col width="0*" style="max-width: fit-content;" />
       <col width="60%" style="width: 60%;" />
       <col width="40%" style="width: 40%;" />
     </colgroup>
@@ -101,7 +100,6 @@ SPDX-License-Identifier: AGPL-3.0 %>
         <th></th>
         <th></th>
         <th></th>
-        <th></th>
         <% sort_order = sortable_columns['name'].gsub(/\s/,'') if sortable_columns['name'] %>
         <th <% if !sort_order.nil? %>
               data-sort-order='<%= sort_order %>'