2985: use move_selections_into_project action
authorTim Pierce <twp@curoverse.com>
Thu, 24 Jul 2014 19:01:48 +0000 (15:01 -0400)
committerTim Pierce <twp@curoverse.com>
Thu, 24 Jul 2014 19:01:48 +0000 (15:01 -0400)
apps/workbench/app/views/projects/_show_tab_contents.html.erb
apps/workbench/config/routes.rb

index 9ac3be0c346372e60338214fb3f2b280c230fc97..0f2ad6f4988f7f51b41aa3c27124b400b5de4e64 100644 (file)
                                    title: 'Move to...',
                                    editable: true,
                                    action_name: 'Move',
-                                   action_href: url_for(action: :update),
+                                   action_href: url_for(action: :move_selections_into_project,
+                                                        controller: 'actions'),
                                    action_method: 'patch',
-                                   action_data: {selection_param: @object.resource_param_name+'[owner_uuid]',
+                                   action_data: {selection_param: 'selection[]',
                                                  success: 'page-refresh'}.to_json),
                   'data-remote' => true,
-                  'data-selection-param-name' => 'uuids[]',
+                  'data-selection-param-name' => 'selection[]',
                  'data-selection-action' => 'move'
             %></li>
         </ul>
index 55e2fdae364465ef07958d728e9b992b26fffa5a..15cd178d14a02f65f6a53d5a9ce222de229197b2 100644 (file)
@@ -66,7 +66,7 @@ ArvadosWorkbench::Application.routes.draw do
     get 'choose', on: :collection
     post 'share_with', on: :member
   end
-
+  match '/move_selections_into_project' => 'actions#move_selections_into_project', via: :patch
   post 'actions' => 'actions#post'
   get 'websockets' => 'websocket#index'