diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 0560cce58b..87ab104537 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,10 @@ +2012-07-06 Sergio Martin + + * godmode/modules/manage_network_components_form.php + godmode/modules/manage_network_components_form_common.php + godmode/modules/manage_network_components.php: Added wizard level + and flag for "only metaconsole" in network components editor + 2012-07-06 Sergio Martin * pandoradb.sql diff --git a/pandora_console/godmode/modules/manage_network_components.php b/pandora_console/godmode/modules/manage_network_components.php index d2baa48b83..ab616a074b 100644 --- a/pandora_console/godmode/modules/manage_network_components.php +++ b/pandora_console/godmode/modules/manage_network_components.php @@ -60,6 +60,8 @@ $history_data = (bool) get_parameter ('history_data'); $post_process = (float) get_parameter('post_process'); $unit = (string) get_parameter('unit'); $id = (int) get_parameter ('id'); +$wizard_level = get_parameter ('wizard_level'); +$only_metaconsole = get_parameter ('only_metaconsole'); $snmp_version = (string) get_parameter('snmp_version'); $snmp3_auth_user = (string) get_parameter('snmp3_auth_user'); @@ -140,7 +142,9 @@ if ($create_component) { 'custom_string_2' => $custom_string_2, 'custom_string_3' => $custom_string_3, 'post_process' => $post_process, - 'unit' => $unit)); + 'unit' => $unit, + 'wizard_level' => $wizard_level, + 'only_metaconsole' => $only_metaconsole)); } else { $id = ''; @@ -207,7 +211,9 @@ if ($update_component) { 'custom_string_2' => $custom_string_2, 'custom_string_3' => $custom_string_3, 'post_process' => $post_process, - 'unit' => $unit)); + 'unit' => $unit, + 'wizard_level' => $wizard_level, + 'only_metaconsole' => $only_metaconsole)); } else { $result = ''; diff --git a/pandora_console/godmode/modules/manage_network_components_form.php b/pandora_console/godmode/modules/manage_network_components_form.php index 18aaa7d07e..cc9637b775 100644 --- a/pandora_console/godmode/modules/manage_network_components_form.php +++ b/pandora_console/godmode/modules/manage_network_components_form.php @@ -58,7 +58,9 @@ if (isset ($id)) { $history_data = $component["history_data"]; $post_process = $component["post_process"]; $unit = $component["unit"]; - + $wizard_level = $component["wizard_level"]; + $only_metaconsole = $component["only_metaconsole"]; + if ($type >= 15 && $type <= 18) { // New support for snmp v3 @@ -98,6 +100,8 @@ if (isset ($id)) { $history_data = true; $post_process = 0; $unit = ''; + $wizard_level = 'nowizard'; + $only_metaconsole = 0; $snmp_version = 1; $snmp3_auth_user = ''; diff --git a/pandora_console/godmode/modules/manage_network_components_form_common.php b/pandora_console/godmode/modules/manage_network_components_form_common.php index d6fa992649..0f89285e81 100644 --- a/pandora_console/godmode/modules/manage_network_components_form_common.php +++ b/pandora_console/godmode/modules/manage_network_components_form_common.php @@ -41,11 +41,23 @@ $table->style = array (); $table->style[0] = 'font-weight: bold'; $table->style[2] = 'font-weight: bold'; $table->colspan = array (); -$table->colspan[0][1] = 3; +if(!enterprise_installed()) { + $table->colspan[0][1] = 3; +} $table->data = array (); $table->data[0][0] = __('Name'); $table->data[0][1] = html_print_input_text ('name', $name, '', 55, 255, true); +if(enterprise_installed()) { + $table->data[0][2] = __('Wizard level'); + $wizard_levels = array('nowizard' => __('No wizard'), + 'basic' => __('Basic'), + 'advanced' => __('Advanced'), + //'custom' => __('Custom'), + ); + $table->data[0][3] = html_print_select($wizard_levels,'wizard_level',$wizard_level,'','',-1,true, false, false); + $table->data[0][3] .= html_print_checkbox('only_metaconsole',1,(int)$only_metaconsole,true).__('Only for metaconsole'); +} $table->data[1][0] = __('Type') . ' ' . ui_print_help_icon ('module_type', true); $sql = sprintf ('SELECT id_tipo, descripcion