diff --git a/pandora_console/godmode/alerts/alert_commands.php b/pandora_console/godmode/alerts/alert_commands.php
index 610c503cdc..5369864105 100644
--- a/pandora_console/godmode/alerts/alert_commands.php
+++ b/pandora_console/godmode/alerts/alert_commands.php
@@ -171,7 +171,7 @@ if (is_ajax()) {
$ffield = $editor_type_chkbx;
$ffield .= html_print_textarea(
'field'.$i.'_value',
- 1,
+ 5,
1,
'',
'class="fields"',
@@ -208,7 +208,7 @@ if (is_ajax()) {
$rfield = $editor_type_chkbx;
$rfield .= html_print_textarea(
'field'.$i.'_recovery_value',
- 1,
+ 5,
1,
'',
'class="fields_recovery"',
@@ -329,7 +329,7 @@ if (is_ajax()) {
$ffield .= html_print_textarea(
'field'.$i.'_value[]',
- 1,
+ 5,
1,
'',
'style="min-height:40px; '.$style.'" class="fields"',
@@ -341,7 +341,7 @@ if (is_ajax()) {
$rfield .= html_print_textarea(
'field'.$i.'_recovery_value[]',
- 1,
+ 5,
1,
'',
'style="min-height:40px; '.$style.'" class="fields_recovery',
@@ -484,7 +484,7 @@ if (is_ajax()) {
} else {
$ffield = html_print_textarea(
'field'.$i.'_value',
- 1,
+ 5,
1,
$fv[0],
'style="'.$style.'" class="fields min-height-40px"',
@@ -494,7 +494,7 @@ if (is_ajax()) {
);
$rfield = html_print_textarea(
'field'.$i.'_recovery_value',
- 1,
+ 5,
1,
$fv[0],
'style="'.$style.'" class="fields_recovery min-height-40px',
@@ -507,7 +507,7 @@ if (is_ajax()) {
} else {
$ffield = html_print_textarea(
'field'.$i.'_value',
- 1,
+ 5,
1,
'',
'style="'.$style.'" class="fields min-height-40px"',
@@ -517,7 +517,7 @@ if (is_ajax()) {
);
$rfield = html_print_textarea(
'field'.$i.'_recovery_value',
- 1,
+ 5,
1,
'',
'style="'.$style.'" class="fields_recovery min-height-40px"',
@@ -533,7 +533,7 @@ if (is_ajax()) {
$fields_rows[$i] = '';
} else {
$fields_rows[$i] = '
';
- $fields_rows[$i] .= ''.$fdesc.' | ';
+ $fields_rows[$i] .= ''.$fdesc.' | ';
$fields_rows[$i] .= ''.$ffield.' | ';
if ($get_recovery_fields) {
$fields_rows[$i] .= ''.$rfield.' | ';
@@ -575,12 +575,19 @@ if ($update_command) {
if (defined('METACONSOLE')) {
alerts_meta_print_header();
} else {
- ui_print_page_header(
- __('Alerts').' » '.__('Alert commands'),
+ ui_print_standard_header(
+ __('Alerts'),
'images/gm_alerts.png',
false,
'',
- true
+ true,
+ [],
+ [
+ [
+ 'link' => '',
+ 'label' => __('Alert commands'),
+ ],
+ ]
);
}
@@ -811,10 +818,9 @@ foreach ($commands as $command) {
array_push($table->data, $data);
}
-ui_pagination($total_commands, $url);
if (isset($data) === true && count($table->data) > 0) {
html_print_table($table);
- ui_pagination($total_commands, $url, 0, 0, false, 'offset', true, 'pagination-bottom');
+ $pagination = ui_pagination($total_commands, $url, 0, 0, true, 'offset', false, '');
} else {
ui_print_info_message(
[
@@ -826,12 +832,17 @@ if (isset($data) === true && count($table->data) > 0) {
// Commands can only be created by the super administrator.
if (users_is_admin() === true) {
- echo '';
echo '';
- echo '
';
}
?>
diff --git a/pandora_console/godmode/alerts/configure_alert_action.php b/pandora_console/godmode/alerts/configure_alert_action.php
index eb1d6d32ee..de5d93a082 100644
--- a/pandora_console/godmode/alerts/configure_alert_action.php
+++ b/pandora_console/godmode/alerts/configure_alert_action.php
@@ -68,12 +68,19 @@ if ($al_action !== false) {
if (defined('METACONSOLE')) {
alerts_meta_print_header();
} else {
- ui_print_page_header(
- __('Alerts').' » '.__('Configure alert action'),
+ ui_print_standard_header(
+ __('Alerts'),
'images/gm_alerts.png',
false,
- 'alert_config',
- true
+ '',
+ true,
+ [],
+ [
+ [
+ 'link' => '',
+ 'label' => __('Configure alert action'),
+ ],
+ ]
);
}
} else {
@@ -81,12 +88,19 @@ if ($al_action !== false) {
if (defined('METACONSOLE')) {
alerts_meta_print_header();
} else {
- ui_print_page_header(
- __('Alerts').' » '.__('Configure alert action'),
+ ui_print_standard_header(
+ __('Alerts'),
'images/gm_alerts.png',
false,
- 'alert_config',
- true
+ '',
+ true,
+ [],
+ [
+ [
+ 'link' => '',
+ 'label' => __('Configure alert action'),
+ ],
+ ]
);
}
@@ -290,73 +304,99 @@ $table->data[1][1] = html_print_label_input_block(
)
);
-$table->data[2][0] = html_print_label_input_block(
+$table_macros = new stdClass();
+$table_macros->id = 'table_macros';
+$table_macros->width = '100%';
+$table_macros->class = 'databox filters filter-table-adv';
+$table_macros->style = [];
+$table_macros->size = [];
+$table_macros->size[0] = '20%';
+$table_macros->size[1] = '40%';
+$table_macros->size[2] = '40%';
+$table_macros->data = [];
+
+$table_macros->data[0][0] = '';
+$table_macros->data[0][1] = html_print_label_input_block(
+ __('Triggering'),
+ ''
+);
+
+$table_macros->data[0][2] = html_print_label_input_block(
__('Recovery'),
''
);
-$table->data[2][1] = html_print_label_input_block(
- __('Recovery'),
+$table_macros->data[1][0] = html_print_label_input_block(
+ __('Command preview'),
''
);
-$table->data[5][0] = __('Command preview');
-$table->data[5][1] = html_print_textarea(
- 'command_preview',
- 5,
- 30,
+$table_macros->data[1][1] = html_print_label_input_block(
'',
- 'disabled="disabled"',
- true
+ html_print_textarea(
+ 'command_preview',
+ 5,
+ 30,
+ '',
+ 'disabled="disabled"',
+ true
+ )
);
-$table->data[5][2] = html_print_textarea(
- 'command_recovery_preview',
- 5,
- 30,
+
+$table_macros->data[1][2] = html_print_label_input_block(
'',
- 'disabled="disabled"',
- true
+ html_print_textarea(
+ 'command_recovery_preview',
+ 5,
+ 30,
+ '',
+ 'disabled="disabled"',
+ true
+ )
);
// Selector will work only with Integria activated.
$integriaIdName = 'integria_wu';
-$table->data[$integriaIdName][0] = __('Create workunit on recovery').ui_print_help_tip(
- __('If closed status is set on recovery, a workunit will be added to the ticket in Integria IMS rather that closing the ticket.'),
- true
-);
-$table->data[$integriaIdName][1] = html_print_checkbox_switch_extended(
- 'create_wu_integria',
- 1,
- $create_wu_integria,
- false,
- '',
- $disabled_attr,
- true
+$table_macros->colspan[$integriaIdName][0] = 3;
+$table_macros->data[$integriaIdName][0] = html_print_label_input_block(
+ __('Create workunit on recovery').ui_print_help_tip(
+ __('If closed status is set on recovery, a workunit will be added to the ticket in Integria IMS rather that closing the ticket.'),
+ true
+ ),
+ html_print_checkbox_switch_extended(
+ 'create_wu_integria',
+ 1,
+ $create_wu_integria,
+ false,
+ '',
+ $disabled_attr,
+ true
+ )
);
for ($i = 1; $i <= $config['max_macro_fields']; $i++) {
- $table->data['field'.$i][0] = html_print_image(
+ $table_macros->data['field'.$i][0] = html_print_image(
'images/spinner.gif',
true
);
- $table->data['field'.$i][1] = html_print_image(
+ $table_macros->data['field'.$i][1] = html_print_image(
'images/spinner.gif',
true
);
- $table->data['field'.$i][2] = html_print_image(
+ $table_macros->data['field'.$i][2] = html_print_image(
'images/spinner.gif',
true
);
// Store the value in a hidden to keep it on first execution
- $table->data['field'.$i][1] .= html_print_input_hidden(
+ $table_macros->data['field'.$i][1] .= html_print_input_hidden(
'field'.$i.'_value',
(!empty($action['field'.$i]) || $action['field'.$i] == 0) ? $action['field'.$i] : '',
true,
'',
$disabled_attr
);
- $table->data['field'.$i][2] .= html_print_input_hidden(
+ $table_macros->data['field'.$i][2] .= html_print_input_hidden(
'field'.$i.'_recovery_value',
(!empty($action['field'.$i.'_recovery']) || $action['field'.$i] == 0) ? $action['field'.$i.'_recovery'] : '',
true,
@@ -369,10 +409,12 @@ $offset = (int) get_parameter('offset', 0);
echo '';
diff --git a/pandora_console/include/class/CalendarManager.class.php b/pandora_console/include/class/CalendarManager.class.php
index 989d921e88..033e8986bd 100644
--- a/pandora_console/include/class/CalendarManager.class.php
+++ b/pandora_console/include/class/CalendarManager.class.php
@@ -1040,7 +1040,7 @@ class CalendarManager
'id' => 'templates_alerts_special_days',
'return' => true,
'class' => 'info_table',
- 'style' => 'width: 100%',
+ 'style' => 'width: 99%',
'columns' => $columns,
'column_names' => $column_names,
'ajax_url' => 'godmode/alerts/alert_special_days',
@@ -1075,7 +1075,9 @@ class CalendarManager
'name' => 'name',
],
],
+ 'class' => 'no_border',
],
+ 'filter_main_class' => 'box-flat white_table_graph',
]
);
} catch (Exception $e) {
diff --git a/pandora_console/include/javascript/pandora.js b/pandora_console/include/javascript/pandora.js
index 30da9745eb..8bfdee500c 100644
--- a/pandora_console/include/javascript/pandora.js
+++ b/pandora_console/include/javascript/pandora.js
@@ -2400,3 +2400,10 @@ function topFunction() {
500
);
}
+
+function menuActionButtonResizing() {
+ $(".action_buttons_right_content").attr(
+ "style",
+ "left: " + $("#menu_full").width() + "px;"
+ );
+}
diff --git a/pandora_console/include/styles/alert.css b/pandora_console/include/styles/alert.css
index 24915928ab..8033a8a7fe 100644
--- a/pandora_console/include/styles/alert.css
+++ b/pandora_console/include/styles/alert.css
@@ -354,3 +354,35 @@ div#rules.show {
.note-special-day div a.tip > img {
margin: 0px;
}
+
+form#icalendar-special-days.calendar-upload-form {
+ border: 0px;
+ padding: 0px;
+}
+
+form#icalendar-special-days.calendar-upload-form > ul {
+ align-items: flex-start !important;
+}
+
+form#icalendar-special-days.calendar-upload-form > ul > li > label {
+ font-size: 13px;
+ line-height: 16px;
+ margin-bottom: 10px;
+}
+
+.special-days-thead > thead > tr > th:not(.header) {
+ border: 1px solid #e2e2e2;
+}
+
+.special-days-thead > thead > tr > th.header {
+ border: 0px;
+ border-bottom: 1px solid #878787;
+}
+
+.special-days-thead > thead > tr > th.c0 {
+ border-left: 1px solid #e2e2e2;
+}
+
+.special-days-thead > thead > tr > th.c6 {
+ border-right: 1px solid #e2e2e2;
+}
diff --git a/pandora_console/include/styles/pandora.css b/pandora_console/include/styles/pandora.css
index 60a361ce01..63ad0d2e52 100644
--- a/pandora_console/include/styles/pandora.css
+++ b/pandora_console/include/styles/pandora.css
@@ -675,6 +675,14 @@ select:-internal-list-box {
width: 40%;
}
+.w45p {
+ width: 45%;
+}
+
+.w48p {
+ width: 48%;
+}
+
.w47p {
width: 47%;
}
@@ -11567,3 +11575,7 @@ ul.tag-editor {
background: #f6f7fb;
line-height: 20px;
}
+
+.max-width-100p {
+ max-width: 100% !important;
+}
diff --git a/pandora_console/include/styles/wizard.css b/pandora_console/include/styles/wizard.css
index fa91c6f2b9..c7c37a8143 100644
--- a/pandora_console/include/styles/wizard.css
+++ b/pandora_console/include/styles/wizard.css
@@ -46,7 +46,6 @@ ul.wizard li > label:not(.p-switch):first-of-type {
}
ul.wizard li > textarea {
- width: 600px;
height: 15em;
display: inline-block;
}
@@ -206,6 +205,7 @@ li#textarea-create-site > textarea {
width: 100%;
}
+form.alert-correlation > ul.wizard > li > label,
form#create_site > ul.wizard > li > label {
font-size: 13px;
line-height: 16px;
@@ -216,3 +216,23 @@ form#create_site > ul.wizard > li > label {
select[multiple] {
min-height: 20em;
}
+
+form.alert-correlation > div > ul,
+form.alert-correlation > ul {
+ display: flex;
+ flex-wrap: wrap;
+ justify-content: space-between;
+}
+
+form.alert-correlation > div > ul > li.flex-flex-end {
+ display: flex;
+ align-items: flex-end;
+}
+
+form.alert-correlation > div > ul > li.flex-flex-end > input {
+ width: 150px !important;
+}
+
+form.alert-correlation > div > ul > li.flex-flex-end > label {
+ width: 50px !important;
+}
diff --git a/pandora_console/index.php b/pandora_console/index.php
index 78de0734b4..a78d97d926 100755
--- a/pandora_console/index.php
+++ b/pandora_console/index.php
@@ -1524,17 +1524,6 @@ require 'include/php_to_js_values.php';
}
}
- //$('.button_collapse').on('click', menuActionButtonResizing());
-
- // Cursor change for show a spinner. Experimental.
- /*
- $('.buttonButton').not('.dialog_opener').on('click', function(){
- $('*').css('cursor', 'wait');
- });
- $('.submitButton').not('.dialog_opener').on('click', function(){
- $('*').css('cursor', 'wait');
- });
-*/
// When the user scrolls down 400px from the top of the document, show the
// button.
window.onscroll = function() {
@@ -1545,10 +1534,6 @@ require 'include/php_to_js_values.php';
scrollFunction()
};
- function menuActionButtonResizing() {
- $('.action_buttons_right_content').attr('style', 'left: '+($('#menu_full').width())+'px;');
- }
-
function first_time_identification() {
jQuery.post("ajax.php", {
"page": "general/register",
diff --git a/pandora_console/views/calendar/edit.php b/pandora_console/views/calendar/edit.php
index 905c77801b..06d8b93d01 100644
--- a/pandora_console/views/calendar/edit.php
+++ b/pandora_console/views/calendar/edit.php
@@ -34,19 +34,19 @@ if (\is_metaconsole() === true) {
\alerts_meta_print_header($tabs);
} else {
// Header.
- \ui_print_page_header(
- // Title.
- __('Calendars Edit'),
- // Icon.
+ \ui_print_standard_header(
+ __('Alerts'),
'images/gm_alerts.png',
- // Return.
false,
- // Help.
'alert_special_days',
- // Godmode.
true,
- // Options.
- $tabs
+ $tabs,
+ [
+ [
+ 'link' => '',
+ 'label' => __('Calendars Edit'),
+ ],
+ ]
);
}
@@ -114,19 +114,24 @@ $inputs[] = [
'rows' => 50,
'columns' => 30,
],
+ 'class' => 'w100p',
];
-
+$button_create = '';
if ($is_management_allowed === true) {
// Submit.
- $inputs[] = [
- 'arguments' => [
- 'name' => 'button',
- 'label' => (($create === true) ? __('Create') : __('Update')),
- 'type' => 'submit',
- 'attributes' => 'class="sub next"',
- ],
- ];
+ html_print_action_buttons(
+ html_print_submit_button(
+ (($create === true) ? __('Create') : __('Update')),
+ 'button',
+ false,
+ [
+ 'icon' => 'wand',
+ 'form' => 'create_specia_days',
+ ],
+ true
+ )
+ );
}
// Print form.
@@ -135,6 +140,8 @@ HTML::printForm(
'form' => [
'action' => $url.'&op=edit&action=save&id='.$calendar->id(),
'method' => 'POST',
+ 'id' => 'create_specia_days',
+ 'class' => 'aaaa',
],
'inputs' => $inputs,
],
diff --git a/pandora_console/views/calendar/list.php b/pandora_console/views/calendar/list.php
index 25589ff15f..3e8e924a7d 100644
--- a/pandora_console/views/calendar/list.php
+++ b/pandora_console/views/calendar/list.php
@@ -101,7 +101,7 @@ try {
[
'id' => $tableId,
'class' => 'info_table',
- 'style' => 'width: 100%',
+ 'style' => 'width: 99%',
'columns' => $columns,
'column_names' => $column_names,
'ajax_url' => $ajax_url,
@@ -117,12 +117,14 @@ try {
[
'label' => __('Free search'),
'type' => 'text',
- 'class' => 'mw250px',
+ 'class' => 'w25p',
'id' => 'free_search',
'name' => 'free_search',
],
],
],
+ 'filter_main_class' => 'box-flat white_table_graph fixed_filter_bar',
+ 'dom_elements' => 'lftpB',
]
);
} catch (Exception $e) {
@@ -130,7 +132,7 @@ try {
}
if ((bool) check_acl($config['id_user'], 0, 'LM') === true) {
- HTML::printForm(
+ $form_create = HTML::printForm(
[
'form' => [
'action' => $url.'&op=edit',
@@ -142,10 +144,12 @@ if ((bool) check_acl($config['id_user'], 0, 'LM') === true) {
'name' => 'button',
'label' => __('Create'),
'type' => 'submit',
- 'attributes' => 'class="sub next"',
+ 'attributes' => ['icon' => 'wand'],
],
],
],
- ]
+ ],
+ true
);
+ html_print_action_buttons($form_create);
}
diff --git a/pandora_console/views/calendar/special_days.php b/pandora_console/views/calendar/special_days.php
index 659eb7283a..905a057f05 100644
--- a/pandora_console/views/calendar/special_days.php
+++ b/pandora_console/views/calendar/special_days.php
@@ -35,19 +35,19 @@ if (\is_metaconsole() === true) {
\alerts_meta_print_header($tabs);
} else {
// Header.
- \ui_print_page_header(
- // Title.
- __('Special days'),
- // Icon.
+ ui_print_standard_header(
+ __('Alerts'),
'images/gm_alerts.png',
- // Return.
false,
- // Help.
'alert_special_days',
- // Godmode.
true,
- // Options.
- $tabs
+ $tabs,
+ [
+ [
+ 'link' => '',
+ 'label' => __('Special days'),
+ ],
+ ]
);
}
@@ -85,6 +85,7 @@ $inputs[] = [
'rows' => 10,
'options' => ['required' => 1],
],
+ 'class' => 'flex flex_column',
];
$days = [];
@@ -104,6 +105,7 @@ $inputs[] = [
'type' => 'select',
'fields' => $days,
],
+ 'class' => 'mrgn_right_20px',
];
// Group.
@@ -114,6 +116,7 @@ $inputs[] = [
'returnAllGroup' => true,
'name' => 'id_group',
],
+ 'class' => 'mrgn_right_20px',
];
// Group.
@@ -128,6 +131,7 @@ $inputs[] = [
'id' => 'overwrite',
'disabled_hidden' => true,
],
+ 'class' => 'flex flex_column',
];
// Submit.
@@ -136,23 +140,39 @@ $inputs[] = [
'name' => 'button',
'label' => __('Upload'),
'type' => 'submit',
- 'attributes' => 'class="sub next"',
+ 'attributes' => [
+ 'icon' => 'wand',
+ 'class' => 'mini',
+ ],
],
];
if ($is_management_allowed === true) {
// Print form.
- HTML::printForm(
+ $form_upload = HTML::printForm(
[
'form' => [
'action' => $url.'&op=upload_ical&id='.$id_calendar,
'method' => 'POST',
'id' => 'icalendar-special-days',
'enctype' => 'multipart/form-data',
+ 'class' => 'calendar-upload-form',
],
'inputs' => $inputs,
],
- false
+ true
+ );
+
+ ui_toggle(
+ $form_upload,
+ '',
+ __('Upload'),
+ 'upload',
+ true,
+ false,
+ '',
+ 'white-box-content no_border',
+ 'filter-datatable-main box-flat white_table_graph fixed_filter_bar '
);
}
@@ -216,7 +236,7 @@ for ($month = 1; $month <= 12; $month++) {
$cal_table = new stdClass();
$cal_table->width = '100%';
- $cal_table->class = 'databox data';
+ $cal_table->class = 'databox data special-days-thead';
$cal_table->data = [];
$cal_table->head = [];
@@ -238,7 +258,7 @@ for ($month = 1; $month <= 12; $month++) {
$cal_table->size[6] = '14%';
$cal_table->align = [];
$cal_table->border = '1';
- $cal_table->titlestyle = 'text-align:center; font-weight: bold;';
+ $cal_table->titlestyle = 'text-align:center;';
switch ($display_month) {
case 1:
$cal_table->title = __('January');
@@ -467,7 +487,7 @@ for ($month = 1; $month <= 12; $month++) {
}
if ((bool) check_acl($config['id_user'], 0, 'LM') === true) {
- HTML::printForm(
+ $form_create = HTML::printForm(
[
'form' => [
'action' => $url.'&op=edit',
@@ -479,12 +499,14 @@ if ((bool) check_acl($config['id_user'], 0, 'LM') === true) {
'name' => 'button',
'label' => __('Create'),
'type' => 'submit',
- 'attributes' => 'class="sub next"',
+ 'attributes' => ['icon' => 'wand'],
],
],
],
- ]
+ ],
+ true
);
+ html_print_action_buttons($form_create);
}
echo '';
diff --git a/pandora_console/views/calendar/special_days_edit.php b/pandora_console/views/calendar/special_days_edit.php
index 1e86a27466..09c7725ebf 100644
--- a/pandora_console/views/calendar/special_days_edit.php
+++ b/pandora_console/views/calendar/special_days_edit.php
@@ -156,14 +156,18 @@ $inputs[] = [
if ($is_management_allowed === true) {
// Submit.
- $inputs[] = [
- 'arguments' => [
- 'name' => 'button',
- 'label' => (($create === true) ? __('Create') : __('Update')),
- 'type' => 'submit',
- 'attributes' => 'class="sub next"',
- ],
- ];
+ html_print_action_buttons(
+ html_print_submit_button(
+ (($create === true) ? __('Create') : __('Update')),
+ 'button',
+ false,
+ [
+ 'icon' => 'wand',
+ 'form' => 'form-special-days',
+ ],
+ true
+ )
+ );
}
// Print form.