X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/7f3ed5e22e01b9cc8efe9ebfc79a2591b37b14d7..274ca7a6c2f1f600de4242eee6cb4e8465d4440c:/apps/workbench/app/controllers/actions_controller.rb diff --git a/apps/workbench/app/controllers/actions_controller.rb b/apps/workbench/app/controllers/actions_controller.rb index b1beb9fb38..347644bdbd 100644 --- a/apps/workbench/app/controllers/actions_controller.rb +++ b/apps/workbench/app/controllers/actions_controller.rb @@ -158,6 +158,7 @@ class ActionsController < ApplicationController normalized = arv_normalize combined newc = Collection.new({:manifest_text => normalized}) + newc.name = newc.name || "Collection created at #{Time.now.localtime}" newc.save! chash.each do |k,v| @@ -170,7 +171,12 @@ class ActionsController < ApplicationController l.save! end - redirect_to controller: 'collections', action: :show, id: newc.uuid + action_data = JSON.parse(params['action_data']) if params['action_data'] + if action_data && action_data['selection_param'].eql?('project') + redirect_to :back + else + redirect_to url_for(controller: 'collections', action: :show, id: newc.uuid) + end end def report_issue_popup