You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

16 lines
428 B

$ ->
ssh_submit = ->
host = $('#ssh_check_host').val()
port = $('#ssh_check_port').val()
port = 22 if port == ''
window.location.href = "<%= Rails.configuration.relative_url_root %>/ssh/#{host}:#{port}"
$('#ssh_check_host').keypress (e) ->
ssh_submit() if e.which == 13
return
$('#ssh_check_port').keypress (e) ->
ssh_submit() if e.which == 13
return
$('#ssh_check_submit').click ->
ssh_submit()
return