@@ -33,10 +33,6 @@ function showHostsTab() {
3333
3434 var dialogAddRouting = $ ( "#dialog_add_routing" ) ;
3535
36- //xenserver supports cluster. kvm doesn't support cluster.
37- if ( getHypervisorType ( ) == "kvm" )
38- dialogAddRouting . find ( "#cluster_options_container, #new_cluster_radio_container, #existing_cluster_radio_container, #no_cluster_radio_container" ) . hide ( ) ;
39-
4036 $ . ajax ( {
4137 data : createURL ( "command=listZones&available=true&response=json" + maxPageSize ) ,
4238 dataType : "json" ,
@@ -594,11 +590,6 @@ function showHostsTab() {
594590 isValid &= validateString ( "Host name" , dialogBox . find ( "#host_hostname" ) , dialogBox . find ( "#host_hostname_errormsg" ) ) ;
595591 isValid &= validateString ( "User name" , dialogBox . find ( "#host_username" ) , dialogBox . find ( "#host_username_errormsg" ) ) ;
596592 isValid &= validateString ( "Password" , dialogBox . find ( "#host_password" ) , dialogBox . find ( "#host_password_errormsg" ) ) ;
597- //xenserver supports cluster. kvm doesn't support cluster.
598- if ( getHypervisorType ( ) != "kvm" ) {
599- if ( clusterRadio == "new_cluster_radio" )
600- isValid &= validateString ( "Cluster name" , dialogBox . find ( "#new_cluster_name" ) , dialogBox . find ( "#new_cluster_name_errormsg" ) ) ;
601- }
602593 if ( ! isValid ) return ;
603594
604595 var array1 = [ ] ;
@@ -615,21 +606,6 @@ function showHostsTab() {
615606 var password = trim ( dialogBox . find ( "#host_password" ) . val ( ) ) ;
616607 array1 . push ( "&password=" + encodeURIComponent ( password ) ) ;
617608
618- //xenserver supports cluster. kvm doesn't support cluster.
619- if ( getHypervisorType ( ) != "kvm" ) {
620- if ( clusterRadio == "new_cluster_radio" ) {
621- var newClusterName = trim ( dialogBox . find ( "#new_cluster_name" ) . val ( ) ) ;
622- array1 . push ( "&clustername=" + encodeURIComponent ( newClusterName ) ) ;
623- }
624- else if ( clusterRadio == "existing_cluster_radio" ) {
625- var clusterId = dialogBox . find ( "#cluster_select" ) . val ( ) ;
626- // We will default to no cluster if someone selects Join Cluster with no cluster available.
627- if ( clusterId != '-1' ) {
628- array1 . push ( "&clusterid=" + clusterId ) ;
629- }
630- }
631- }
632-
633609 var hostname = trim ( dialogBox . find ( "#host_hostname" ) . val ( ) ) ;
634610 var url ;
635611 if ( hostname . indexOf ( "http://" ) == - 1 )
0 commit comments