diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 09d9597fad..252100f0f1 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,12 @@ +2013-04-24 Miguel de Dios + + * godmode/events/event_responses.editor.php: set the sizes of + the widgets for the form in the metaconsole. + + Fixes: #3611423 + + * godmode/users/configure_user.php + 2013-04-24 Miguel de Dios * godmode/tag/edit_tag.php: change the input text for textarea for diff --git a/pandora_console/godmode/events/event_responses.editor.php b/pandora_console/godmode/events/event_responses.editor.php index 17326e8e31..1aa7177b60 100644 --- a/pandora_console/godmode/events/event_responses.editor.php +++ b/pandora_console/godmode/events/event_responses.editor.php @@ -25,9 +25,20 @@ if (! check_acl($config['id_user'], 0, "PM")) { return; } +$meta = false; +if(enterprise_installed() && defined("METACONSOLE")) { + $meta = true; +} + +$class_description = 'response_description'; +if ($meta) { + $class_description = 'response_description_metaconsole'; +} + + $event_response_id = get_parameter('id_response',0); -if($event_response_id > 0) { +if ($event_response_id > 0) { $event_response = db_get_row('tevent_response','id',$event_response_id); } else { @@ -55,7 +66,8 @@ $table->data = array(); $data = array(); $data[0] = __('Name'); -$data[1] = html_print_input_text('name',$event_response['name'],'',100,255,true); +$data[1] = html_print_input_text('name', $event_response['name'], '', + 50, 255, true); $data[1] .= html_print_input_hidden('id_response',$event_response['id'],true); $data[2] = __('Group'); @@ -65,7 +77,8 @@ $table->data[0] = $data; $data = array(); $table->colspan[1][1] = 3; $data[0] = __('Description'); -$data[1] = html_print_textarea('description',5,40,$event_response['description'],'',true); +$data[1] = html_print_textarea('description', 5, 40, + $event_response['description'], 'class="' . $class_description . '"', true); $table->data[1] = $data; $data = array(); @@ -74,10 +87,10 @@ $locations = array(__('Modal window'), __('New window')); $data[1] = html_print_select($locations,'new_window',$event_response['new_window'],'','','',true); $data[2] = ''.__('Size').''; -if($event_response['modal_width'] == 0) { +if ($event_response['modal_width'] == 0) { $event_response['modal_width'] = 620; } -if($event_response['modal_height'] == 0) { +if ($event_response['modal_height'] == 0) { $event_response['modal_height'] = 500; } $data[3] = ''.__('Width').' (px) '; @@ -88,7 +101,8 @@ $table->data[2] = $data; $data = array(); $data[0] = __('Parameters').ui_print_help_icon ("response_parameters", true); -$data[1] = html_print_input_text('params',$event_response['params'],'',100,255,true); +$data[1] = html_print_input_text('params', $event_response['params'], + '', 50, 255, true); $types = array('url' => __('URL'), 'command' => __('Command')); $data[2] = __('Type'); $data[3] = html_print_select($types,'type',$event_response['type'],'','','',true); @@ -97,11 +111,12 @@ $table->data[3] = $data; $data = array(); $table->colspan[4][1] = 3; $data[0] = ''.__('Command').''.ui_print_help_icon ("response_macros", true); -$data[1] = html_print_input_text('target',$event_response['target'],'',150,255,true); +$data[1] = html_print_input_text('target', $event_response['target'], + '', 100, 255, true); $types = array('url' => __('URL'), 'command' => __('Command')); $table->data[4] = $data; -if($event_response_id == 0) { +if ($event_response_id == 0) { echo '
'; html_print_table($table); echo '

'; @@ -124,9 +139,10 @@ $('#type').change(function() { $('.labels').hide(); $('#'+$(this).val()+'_label').show(); - switch($(this).val()) { + switch ($(this).val()) { case 'command': - $('#new_window option[value="0"]').attr('selected','selected'); + $('#new_window option[value="0"]') + .attr('selected','selected'); $('#new_window').attr('disabled','disabled'); break; case 'url': @@ -136,7 +152,7 @@ $('#type').change(function() { }); $('#new_window').change(function() { - switch($(this).val()) { + switch ($(this).val()) { case '0': $('.size').css('visibility','visible'); break; diff --git a/pandora_console/godmode/users/configure_user.php b/pandora_console/godmode/users/configure_user.php index cf1e05b44e..caac032821 100644 --- a/pandora_console/godmode/users/configure_user.php +++ b/pandora_console/godmode/users/configure_user.php @@ -67,7 +67,7 @@ $tab = get_parameter('tab', 'user'); // Header if ($meta) { - + user_meta_print_header(); $sec = 'advanced'; @@ -445,7 +445,7 @@ else { $id_usr = $id; } -if(!$meta) { +if (!$meta) { // User only can change skins if has more than one group if (count($usr_groups) > 1) { if ($isFunctionSkins !== ENTERPRISE_NOT_HOOK) {