projects
/
arvados.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch '17719-keep-web-pdh-cache'
[arvados.git]
/
apps
/
workbench
/
app
/
views
/
application
/
_show_recent.html.erb
diff --git
a/apps/workbench/app/views/application/_show_recent.html.erb
b/apps/workbench/app/views/application/_show_recent.html.erb
index 04387ffb3e9d8e45227f69e7ce85f2deadb14f35..537cce7a3182feb25aee0e4a6ca1fd5cad5472a2 100644
(file)
--- a/
apps/workbench/app/views/application/_show_recent.html.erb
+++ b/
apps/workbench/app/views/application/_show_recent.html.erb
@@
-1,57
+1,68
@@
-<% if @objects.empty? %>
+<%# Copyright (C) The Arvados Authors. All rights reserved.
+
+SPDX-License-Identifier: AGPL-3.0 %>
+
+<% if objects.empty? %>
<br/>
<p style="text-align: center">
<br/>
<p style="text-align: center">
- No <%= controller.
model_class.to_s.pluralize.underscore.gsub '_', ' '
%> to display.
+ No <%= controller.
controller_name.humanize.downcase
%> to display.
</p>
<% else %>
</p>
<% else %>
-<% attr_blacklist = ' created_at modified_at modified_by_user_uuid modified_by_client_uuid updated_at' %>
+<% attr_blacklist = ' created_at modified_at modified_by_user_uuid modified_by_client_uuid updated_at
owner_uuid group_class properties
' %>
-<%= render partial: "paging", locals: {results:
@
objects, object: @object} %>
+<%= render partial: "paging", locals: {results: objects, object: @object} %>
<%= form_tag do |f| %>
<table class="table table-condensed arv-index">
<thead>
<tr>
<%= form_tag do |f| %>
<table class="table table-condensed arv-index">
<thead>
<tr>
+ <% if objects.first and objects.first.class.goes_in_projects? %>
+ <th></th>
+ <% end %>
<th></th>
<th></th>
- <%
@
objects.first.attributes_for_display.each do |attr, attrvalue| %>
+ <% objects.first.attributes_for_display.each do |attr, attrvalue| %>
<% next if attr_blacklist.index(" "+attr) %>
<th class="arv-attr-<%= attr %>">
<%= controller.model_class.attribute_info[attr.to_sym].andand[:column_heading] or attr.sub /_uuid/, '' %>
</th>
<% end %>
<% next if attr_blacklist.index(" "+attr) %>
<th class="arv-attr-<%= attr %>">
<%= controller.model_class.attribute_info[attr.to_sym].andand[:column_heading] or attr.sub /_uuid/, '' %>
</th>
<% end %>
+ <th>
+ <!-- a column for user's home -->
+ </th>
<th>
<!-- a column for delete buttons -->
</th>
</tr>
</thead>
<th>
<!-- a column for delete buttons -->
</th>
</tr>
</thead>
-
+
<tbody>
<tbody>
- <%
@
objects.each do |object| %>
+ <% objects.each do |object| %>
<tr data-object-uuid="<%= object.uuid %>">
<tr data-object-uuid="<%= object.uuid %>">
+ <% if objects.first.class.goes_in_projects? %>
+ <td>
+ <%= render :partial => "selection_checkbox", :locals => {:object => object} %>
+ </td>
+ <% end %>
<td>
<td>
- <%= render :partial => "s
election_checkbox", :locals => {:object => object
} %>
+ <%= render :partial => "s
how_object_button", :locals => {object: object, size: 'xs'
} %>
</td>
<% object.attributes_for_display.each do |attr, attrvalue| %>
<% next if attr_blacklist.index(" "+attr) %>
<td class="arv-object-<%= object.class.to_s %> arv-attr-<%= attr %>">
<% if attr == 'uuid' %>
</td>
<% object.attributes_for_display.each do |attr, attrvalue| %>
<% next if attr_blacklist.index(" "+attr) %>
<td class="arv-object-<%= object.class.to_s %> arv-attr-<%= attr %>">
<% if attr == 'uuid' %>
- <%= link_to_if_arvados_object object %>
- <%= link_to_if_arvados_object(object, { link_text: raw('<i class="icon-hand-right"></i>') }) %>
- <% else %>
- <% if object.attribute_editable? attr %>
- <%= render_editable_attribute object, attr %>
+ <span class="arvados-uuid"><%= attrvalue %></span>
<% else %>
<% else %>
- <%= resource_class_for_uuid(attrvalue, referring_attr: attr, referring_object: @object).to_s %>
- <%= attrvalue %>
- <% end %>
- <%= link_to_if_arvados_object(attrvalue, { referring_object: @object, link_text: raw('<i class="icon-hand-right"></i>') }) if resource_class_for_uuid(attrvalue, {referring_object: @object}) %>
+ <%= link_to_if_arvados_object attrvalue, {referring_attr: attr, referring_object: object, with_class_name: true, friendly_name: true} %>
<% end %>
</td>
<% end %>
<% end %>
</td>
<% end %>
+ <td>
+ <%= render partial: 'show_home_button', locals: {object:object} %>
+ </td>
<td>
<%= render partial: 'delete_object_button', locals: {object:object} %>
</td>
<td>
<%= render partial: 'delete_object_button', locals: {object:object} %>
</td>
@@
-65,6
+76,6
@@
<% end %>
<% end %>
-<%= render partial: "paging", locals: {results:
@
objects, object: @object} %>
+<%= render partial: "paging", locals: {results: objects, object: @object} %>
<% end %>
<% end %>