[ARVADOS] updated: 5828355672e3fc7926125dcc35882a642a4cde1a

git at public.curoverse.com git at public.curoverse.com
Thu Sep 4 16:56:18 EDT 2014


Summary of changes:
 .../workbench/app/controllers/actions_controller.rb | 21 ++++++++++++++-------
 1 file changed, 14 insertions(+), 7 deletions(-)

       via  5828355672e3fc7926125dcc35882a642a4cde1a (commit)
      from  2449ae26b0d8be41aa5411e62032c9fb1ea9af71 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 5828355672e3fc7926125dcc35882a642a4cde1a
Author: radhika <radhika at curoverse.com>
Date:   Thu Sep 4 16:55:36 2014 -0400

    3710: handle the scenario where files from named collections are selected

diff --git a/apps/workbench/app/controllers/actions_controller.rb b/apps/workbench/app/controllers/actions_controller.rb
index ec71acc..a5c2e94 100644
--- a/apps/workbench/app/controllers/actions_controller.rb
+++ b/apps/workbench/app/controllers/actions_controller.rb
@@ -139,29 +139,36 @@ class ActionsController < ApplicationController
       end
     end
 
-    collections = Collection.where(uuid: lst)
-
+    lst = lst.uniq
     chash = {}
+
+    collections = Collection.where(uuid: lst)
     collections.each do |c|
       c.reload()
       chash[c.uuid] = c
     end
 
+    collections = Collection.where(portable_data_hash: lst)
+    collections.each do |c|
+      c.reload()
+      chash[c.portable_data_hash] = c
+    end
+
     combined = ""
     files.each do |m|
       if CollectionsHelper.match_uuid_with_optional_filepath(m[0])
-        mt = chash[m[1]].manifest_text
+        mt = chash[m[1]].andand.manifest_text
         if m[2].andand.size>0
           combined += arv_normalize mt, '--extract', m[2][1..-1]
         else
-          combined += chash[m[1]].manifest_text
+          combined += mt
         end
       else
-        mt = chash[m[1]+m[2]].manifest_text
-        if m[4]
+        mt = chash[m[1]+m[2]].andand.manifest_text
+        if m[4].andand.size>0
           combined += arv_normalize mt, '--extract', m[4][1..-1]
         else
-          combined += chash[m[1]+m[2]].manifest_text
+          combined += mt
         end
       end
     end

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list