X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/7e723d29f206fcc5ba4d8a26f8d547a72d5f0425..6d5e04a731edc9ce8944ecea637070afbdadeb05:/apps/workbench/app/views/collections/show_file_links.html.erb
diff --git a/apps/workbench/app/views/collections/show_file_links.html.erb b/apps/workbench/app/views/collections/show_file_links.html.erb
index 22baaa8783..a829d8f274 100644
--- a/apps/workbench/app/views/collections/show_file_links.html.erb
+++ b/apps/workbench/app/views/collections/show_file_links.html.erb
@@ -44,10 +44,11 @@ the entire collection with wget, try:
File Listing
-<% if @object.andand.files_tree.andand.any? %>
+<% file_tree = @object.andand.files_tree %>
+<% if file_tree.andand.any? %>
- <% dirstack = [@object.files_tree.first.first] %>
- <% @object.files_tree.each_with_index do |(dirname, filename, size), index| %>
+ <% dirstack = [file_tree.first.first] %>
+ <% file_tree.take(10000).each_with_index do |(dirname, filename, size), index| %>
<% file_path = CollectionsHelper::file_path([dirname, filename]) %>
<% while dirstack.any? and (dirstack.last != dirname) %>
<% dirstack.pop %>
@@ -59,9 +60,7 @@ the entire collection with wget, try:
<% else %>
<%= link_to(filename,
- {controller: 'collections', action: 'show_file',
- uuid: @object.uuid, file: file_path,
- reader_token: params[:reader_token]},
+ link_opts.merge(file: file_path),
{title: "Download #{file_path}"}) %>
<% end %>