[ARVADOS] updated: 498a97e6cdb456bf7487f7c62dce08791cb5f453

git at public.curoverse.com git at public.curoverse.com
Wed Feb 11 18:58:54 EST 2015


Summary of changes:
 apps/workbench/app/views/users/_manage_virtual_machines.html.erb | 7 +++++--
 apps/workbench/test/integration/user_manage_account_test.rb      | 4 +++-
 2 files changed, 8 insertions(+), 3 deletions(-)

       via  498a97e6cdb456bf7487f7c62dce08791cb5f453 (commit)
       via  26ac1b2f41916d1f4040073a15dfae5f1b294cb5 (commit)
      from  1de8e55b47ea46fe1e589fbfe1ff0ae77b9e2cbf (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 498a97e6cdb456bf7487f7c62dce08791cb5f453
Author: Radhika Chippada <radhika at curoverse.com>
Date:   Wed Feb 11 18:40:23 2015 -0500

    4951: button_to cannot be used to submit; instead change to link_to

diff --git a/apps/workbench/app/views/users/_manage_virtual_machines.html.erb b/apps/workbench/app/views/users/_manage_virtual_machines.html.erb
index 1e7fb3b..df5c71a 100644
--- a/apps/workbench/app/views/users/_manage_virtual_machines.html.erb
+++ b/apps/workbench/app/views/users/_manage_virtual_machines.html.erb
@@ -13,8 +13,11 @@
         You may request access to a hosted virtual machine with the command line shell.
            
         <div style='display:inline-block'>
-          <%= button_to('Send request for shell access', request_shell_access_user_url(id: current_user.uuid),
-                         id: 'request_shell_submit', class: 'btn btn-xs btn-primary', remote: true) %>
+          <%= link_to({action: 'request_shell_access', controller: 'users', id: current_user.uuid},
+                       method: :post, remote: true, class: 'btn btn-xs btn-primary',
+                       id: 'request_shell_submit', data: {disable_with: "Sending request..."}) do %>
+              Send request for shell access
+          <% end %>
         </div>
       </div><br/>
       <div class='shell_access_requested alert alert-info'>
diff --git a/apps/workbench/test/integration/user_manage_account_test.rb b/apps/workbench/test/integration/user_manage_account_test.rb
index a84d424..ea41543 100644
--- a/apps/workbench/test/integration/user_manage_account_test.rb
+++ b/apps/workbench/test/integration/user_manage_account_test.rb
@@ -137,9 +137,10 @@ class UserManageAccountTest < ActionDispatch::IntegrationTest
   test "request shell access" do
     visit page_with_token('spectator', '/manage_account')
     assert_text 'You do not have access to any virtual machines'
-    click_button 'Send request for shell access'
+    click_link 'Send request for shell access'
     assert_text 'A request for shell access was sent.'
     assert_no_text 'You do not have access to any virtual machines.'
+    assert_no_selector 'a', text: 'Send request for shell access'
 
     # revisit the page and verify that the Request button is no longer shown
     within('.navbar-fixed-top') do
@@ -150,5 +151,6 @@ class UserManageAccountTest < ActionDispatch::IntegrationTest
     end
     assert_text 'You do not have access to any virtual machines.'
     assert_text 'A request for shell access was sent on '
+    assert_selector 'a', text: 'Send request for shell access'
   end
 end

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


hooks/post-receive
-- 




More information about the arvados-commits mailing list