Merge branch 'ent-9662-Restyling-fuentes-colores-botones' of brutus.artica.es:artica/pandorafms into ent-9662-Restyling-fuentes-colores-botones

This commit is contained in:
Jose Gonzalez 2023-03-03 14:51:07 +01:00
commit 9ad97ee267
13 changed files with 324 additions and 308 deletions

View File

@ -486,25 +486,13 @@ if ((int) $load_filter_modal === 1) {
$table = new StdClass; $table = new StdClass;
$table->id = 'load_filter_form'; $table->id = 'load_filter_form';
$table->width = '100%'; $table->width = '100%';
$table->cellspacing = 4; $table->class = 'filter-table-adv';
$table->cellpadding = 4;
$table->class = 'databox';
if (is_metaconsole()) {
$table->cellspacing = 0;
$table->cellpadding = 0;
$table->class = 'databox filters';
}
$table->styleTable = 'font-weight: bold; color: #555; text-align:left;';
$filter_id_width = '200px';
if (is_metaconsole()) {
$filter_id_width = '150px';
}
$data = []; $data = [];
$table->rowid[3] = 'update_filter_row1'; $table->rowid[3] = 'update_filter_row1';
$data[0] = __('Load filter').$jump; $data[0] = html_print_label_input_block(
$data[0] .= html_print_select( __('Load filter'),
html_print_select(
$filters, $filters,
'filter_id', 'filter_id',
$current, $current,
@ -515,21 +503,31 @@ if ((int) $load_filter_modal === 1) {
false, false,
true, true,
'', '',
false, false
'margin-left:5px; width:'.$filter_id_width.';' )
); );
$data[1] = html_print_submit_button(
__('Load filter'),
'load_filter',
false,
'class="sub upd"',
true
);
$data[1] .= html_print_input_hidden('load_filter', 1, true);
$table->data[] = $data; $table->data[] = $data;
$table->rowclass[] = ''; $table->rowclass[] = '';
html_print_table($table); html_print_table($table);
html_print_div(
[
'class' => 'action-buttons',
'content' => html_print_submit_button(
__('Load filter'),
'srcbutton',
false,
[
'icon' => 'search',
'mode' => 'mini',
],
true
),
],
false
);
echo html_print_input_hidden('load_filter', 1, true);
echo '</form>'; echo '</form>';
echo '</div>'; echo '</div>';
?> ?>
@ -562,52 +560,44 @@ if ($save_filter_modal) {
$table = new StdClass; $table = new StdClass;
$table->id = 'save_filter_form'; $table->id = 'save_filter_form';
$table->width = '100%'; $table->width = '100%';
$table->cellspacing = 4; $table->size = [];
$table->cellpadding = 4; $table->size[0] = '50%';
$table->class = 'databox'; $table->size[1] = '50%';
$table->class = 'filter-table-adv';
if (is_metaconsole() === true) {
$table->class = 'databox filters';
$table->cellspacing = 0;
$table->cellpadding = 0;
}
$table->styleTable = 'font-weight: bold; text-align:left;';
if (is_metaconsole() === true) {
$table->style[0] = 'width: 50%; width:50%;';
}
$data = []; $data = [];
$table->rowid[0] = 'update_save_selector'; $table->rowid[0] = 'update_save_selector';
$data[0] = html_print_radio_button( $data[0][0] = html_print_label_input_block(
__('New filter'),
html_print_radio_button(
'filter_mode', 'filter_mode',
'new', 'new',
'', '',
true, true,
true true
).__('New filter').''; )
);
$data[1] = html_print_radio_button( $data[0][1] = html_print_label_input_block(
__('Update/delete filter'),
html_print_radio_button(
'filter_mode', 'filter_mode',
'update', 'update',
'', '',
false, false,
true true
).__('Update/delete filter').''; )
);
$table->data[] = $data;
$table->rowclass[] = '';
$data = [];
$table->rowid[1] = 'save_filter_row1'; $table->rowid[1] = 'save_filter_row1';
$data[0] = __('Filter name').$jump; $data[1][0] = html_print_label_input_block(
$data[0] .= html_print_input_text('id_name', '', '', 15, 255, true); __('Filter name'),
html_print_input_text('id_name', '', '', 15, 255, true)
);
$labelInput = __('Filter group');
if (is_metaconsole() === true) { if (is_metaconsole() === true) {
$data[1] = __('Save in Group').$jump; $labelInput = __('Save in Group');
} else {
$data[1] = __('Filter group').$jump;
} }
$user_groups_array = users_get_groups_for_select( $user_groups_array = users_get_groups_for_select(
@ -617,7 +607,9 @@ if ($save_filter_modal) {
true true
); );
$data[1] .= html_print_select( $data[1][1] = html_print_label_input_block(
$labelInput,
html_print_select(
$user_groups_array, $user_groups_array,
'id_group_filter_dialog', 'id_group_filter_dialog',
$id_group_filter, $id_group_filter,
@ -626,23 +618,15 @@ if ($save_filter_modal) {
0, 0,
true, true,
false, false,
false, false
'w130' ),
['div_class' => 'filter-group-dialog']
); );
$table->data[] = $data;
$table->rowclass[] = '';
$data = [];
$table->rowid[2] = 'save_filter_row2'; $table->rowid[2] = 'save_filter_row2';
$table->data[] = $data; $table->data[] = $data;
$table->rowclass[] = ''; $table->rowclass[] = '';
$data = [];
$table->rowid[3] = 'update_filter_row1';
$data[0] = __('Filter').$jump;
$user_groups = users_get_groups( $user_groups = users_get_groups(
$config['id_user'], $config['id_user'],
'AW', 'AW',
@ -664,7 +648,9 @@ if ($save_filter_modal) {
} }
} }
$data[0] .= html_print_select( $data[2][0] = html_print_label_input_block(
__('Filter'),
html_print_select(
$_filters_update, $_filters_update,
'overwrite_filter', 'overwrite_filter',
'', '',
@ -672,37 +658,63 @@ if ($save_filter_modal) {
'', '',
0, 0,
true true
)
); );
$table->data[] = $data; $table->data = $data;
$table->rowclass[] = '';
html_print_table($table); html_print_table($table);
echo '<div id="update_delete_row"><br>'; html_print_div(
echo html_print_submit_button( [
__('Update filter'), 'id' => 'submit-save_filter',
'update_filter', 'class' => 'action-buttons',
'content' => html_print_submit_button(
__('Save current filter'),
'srcbutton',
false, false,
'class="sub upd" onclick="save_update_filter();"', [
'icon' => 'search',
'mode' => 'mini',
'onclick' => 'save_new_filter();',
],
true true
),
],
false
); );
echo html_print_submit_button(
$input_actions = html_print_submit_button(
__('Delete filter'), __('Delete filter'),
'delete_filter', 'delete_filter',
false, false,
'class="sub delete float-right" onclick="save_delete_filter();"', [
'icon' => 'delete',
'mode' => 'mini',
'onclick' => 'save_delete_filter();',
],
true true
); );
echo '</div>';
echo '<div><br>'; $input_actions .= html_print_submit_button(
echo html_print_submit_button( __('Update filter'),
__('Save current filter'), 'srcbutton',
'save_filter',
false, false,
'class="sub upd float-right" onclick="save_new_filter();"', [
'icon' => 'update',
'mode' => 'mini',
'onclick' => 'save_update_filter();',
],
true true
); );
echo '</div>';
html_print_div(
[
'id' => 'update_filter_row',
'class' => 'action-buttons',
'content' => $input_actions,
],
false
);
} else { } else {
include 'general/noaccess.php'; include 'general/noaccess.php';
} }
@ -712,32 +724,34 @@ if ($save_filter_modal) {
<script type="text/javascript"> <script type="text/javascript">
function show_save_filter() { function show_save_filter() {
$('#save_filter_row1').show(); $('#save_filter_row2').hide();
$('#save_filter_row2').show(); $('#update_filter_row').hide();
$('#update_filter_row1').hide();
$('#update_delete_row').hide(); $('#update_delete_row').hide();
$('.filter-group-dialog').show();
// Filter save mode selector // Filter save mode selector
$("[name='filter_mode']").click(function() { $("[name='filter_mode']").click(function() {
if ($(this).val() == 'new') { if ($(this).val() == 'new') {
$('#save_filter_row1').show(); $('#save_filter_row2').hide();
$('#save_filter_row2').show();
$('#submit-save_filter').show(); $('#submit-save_filter').show();
$('#update_filter_row1').hide(); $('#update_filter_row').hide();
$('#update_delete_row').hide(); $('#update_delete_row').hide();
$('.filter-group-dialog').show();
} }
else { else {
$('#save_filter_row1').hide(); $('#save_filter_row2').show();
$('#save_filter_row2').hide(); $('#update_filter_row').show();
$('#update_filter_row1').show();
$('#submit-save_filter').hide(); $('#submit-save_filter').hide();
$('#update_delete_row').show(); $('#update_delete_row').show();
$('.filter-group-dialog').hide();
} }
}); });
$("#save-filter-select").dialog({ $("#save-filter-select").dialog({
resizable: true, resizable: true,
draggable: true, draggable: true,
modal: false, modal: false,
closeOnEscape: true closeOnEscape: true,
width: 450,
height: 350
}); });
} }

View File

@ -1962,7 +1962,8 @@ if (check_login()) {
true, true,
false, false,
false false
) ),
['div_class' => 'filter-group-dialog']
); );
$table->rowid[2] = 'save_filter_row2'; $table->rowid[2] = 'save_filter_row2';
@ -2056,6 +2057,7 @@ if (check_login()) {
$('#save_filter_row2').hide(); $('#save_filter_row2').hide();
$('#update_filter_row').hide(); $('#update_filter_row').hide();
$('#update_delete_row').hide(); $('#update_delete_row').hide();
$('.filter-group-dialog').show();
// Filter save mode selector // Filter save mode selector
$("[name='filter_mode']").click(function() { $("[name='filter_mode']").click(function() {
if ($(this).val() == 'new') { if ($(this).val() == 'new') {
@ -2063,12 +2065,14 @@ if (check_login()) {
$('#submit-save_filter').show(); $('#submit-save_filter').show();
$('#update_filter_row').hide(); $('#update_filter_row').hide();
$('#update_delete_row').hide(); $('#update_delete_row').hide();
$('.filter-group-dialog').show();
} }
else { else {
$('#save_filter_row2').show(); $('#save_filter_row2').show();
$('#update_filter_row').show(); $('#update_filter_row').show();
$('#submit-save_filter').hide(); $('#submit-save_filter').hide();
$('#update_delete_row').show(); $('#update_delete_row').show();
$('.filter-group-dialog').hide();
} }
}); });
$("#save-filter-select").dialog({ $("#save-filter-select").dialog({

View File

@ -3448,7 +3448,7 @@ function html_print_action_buttons(mixed $content, array $parameters=[], bool $r
'id' => ($parameters['id'] ?? 'principal_action_buttons'), 'id' => ($parameters['id'] ?? 'principal_action_buttons'),
'class' => 'action-buttons '.$typeClass.' '.($parameters['class'] ?? ''), 'class' => 'action-buttons '.$typeClass.' '.($parameters['class'] ?? ''),
'content' => $content, 'content' => $content,
'style' => 'z-index: 100', 'style' => 'z-index: 1',
], ],
$return $return
); );
@ -6777,9 +6777,7 @@ function html_print_label_input_block(
$calbackFn, $calbackFn,
?array $options=[] ?array $options=[]
):string { ):string {
$div_class = '';
$label_class = ''; $label_class = '';
$div_id = '';
$divAttributes = []; $divAttributes = [];
@ -6814,3 +6812,20 @@ function html_print_label_input_block(
return $output; return $output;
} }
function html_print_go_top()
{
$output = '</div>';
$output .= '<div onclick="topFunction()" id="top_btn" title="Go to top">';
$output .= '<svg viewBox="0 0 20 20" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">';
$output .= '<title>Dark / 20 / arrow@svg</title>';
$output .= '<desc>Created with Sketch.</desc>';
$output .= '<g id="Dark-/-20-/-arrow" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">';
$output .= '<path d="M3.41005051,6.39052429 C3.91472805,5.90987901 4.70885153,5.8729063 5.25805922,6.27960615 L5.38994949,6.39052429 L10,10.78 L14.6100505,6.39052429 C15.1147281,5.90987901 15.9088515,5.8729063 16.4580592,6.27960615 L16.5899495,6.39052429 C17.094627,6.87116957 17.1334484,7.62747765 16.7064135,8.15053259 L16.5899495,8.27614237 L10.9899495,13.6094757 C10.4852719,14.090121 9.69114847,14.1270937 9.14194078,13.7203939 L9.01005051,13.6094757 L3.41005051,8.27614237 C2.8633165,7.75544332 2.8633165,6.91122335 3.41005051,6.39052429 Z" id="Path-8" fill="#14524f" fill-rule="nonzero" transform="translate(10.000000, 10.000000) rotate(90.000000) translate(-10.000000, -10.000000) "></path>';
$output .= '</g>';
$output .= '</svg>';
$output .= '</div>';
return $output;
}

View File

@ -1503,7 +1503,7 @@ function ui_print_help_icon(
$help_id, $help_id,
$return=false, $return=false,
$home_url='', $home_url='',
$image='images/help_green.png', $image='images/info@svg.svg',
$is_relative=false, $is_relative=false,
$id='' $id=''
) { ) {
@ -1533,7 +1533,7 @@ function ui_print_help_icon(
$image, $image,
true, true,
[ [
'class' => 'img_help', 'class' => 'img_help main_menu_icon',
'title' => __('Help'), 'title' => __('Help'),
'onclick' => "open_help ('".ui_get_full_url($help_handler)."')", 'onclick' => "open_help ('".ui_get_full_url($help_handler)."')",
'id' => $id, 'id' => $id,
@ -6990,7 +6990,7 @@ function ui_query_result_editor($name='default')
__('Execute query'), __('Execute query'),
'execute_query', 'execute_query',
false, false,
'class="sub next"', ['icon' => 'next'],
true true
), ),
], ],

View File

@ -20949,7 +20949,6 @@ ace.define(
bottom: 0;\ bottom: 0;\
left: 0;\ left: 0;\
cursor: default;\ cursor: default;\
z-index: 4;\
-ms-user-select: none;\ -ms-user-select: none;\
-moz-user-select: none;\ -moz-user-select: none;\
-webkit-user-select: none;\ -webkit-user-select: none;\

View File

@ -2367,3 +2367,35 @@ function observerInputPassword(name) {
observer.observe(input, { attributes: true }); observer.observe(input, { attributes: true });
}); });
} }
function scrollFunction() {
if (
document.body.scrollTop > 400 ||
document.documentElement.scrollTop > 400
) {
if (document.getElementById("top_btn")) {
document.getElementById("top_btn").style.display = "block";
}
} else {
if (document.getElementById("top_btn")) {
document.getElementById("top_btn").style.display = "none";
}
}
}
// When the user clicks on the button, scroll to the top of the document.
function topFunction() {
/*
* Safari.
* document.body.scrollTop = 0;
* For Chrome, Firefox, IE and Opera.
* document.documentElement.scrollTop = 0;
*/
$("HTML, BODY").animate(
{
scrollTop: 0
},
500
);
}

View File

@ -113,7 +113,7 @@ div.arrow_box:before {
#menu_tab_frame_view_bc { #menu_tab_frame_view_bc {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
border-bottom: 2px solid #14524f; border-bottom: 2px solid var(--primary-color);
max-height: 70px; max-height: 70px;
min-height: 55px; min-height: 55px;
width: 100%; width: 100%;
@ -150,15 +150,15 @@ span.breadcrumb_link {
} }
.breadcrumb_link.selected { .breadcrumb_link.selected {
color: #14524f; color: var(--primary-color);
} }
.breadcrumb_link.selected:hover { .breadcrumb_link.selected:hover {
color: #14524f; color: var(--primary-color);
text-decoration: none; text-decoration: none;
} }
.breadcrumb_link:hover { .breadcrumb_link:hover {
color: #14524f; color: var(--primary-color);
text-decoration: none; text-decoration: none;
} }

View File

@ -740,7 +740,7 @@ button.submitButton {
line-height: 24px; line-height: 24px;
box-shadow: 0px 3px 6px #c7c7c7; box-shadow: 0px 3px 6px #c7c7c7;
color: #fff; color: #fff;
border: 2px solid #14524f; border: 2px solid var(--primary-color);
border-radius: 8px; border-radius: 8px;
padding: 0 10px; padding: 0 10px;
cursor: pointer; cursor: pointer;

View File

@ -27,6 +27,11 @@
* ============================================================================ * ============================================================================
*/ */
:root {
--primary-color: #14524f;
--secondary-color: #ffffff;
}
/* /*
* --------------------------------------------------------------------- * ---------------------------------------------------------------------
* - GENERAL STYLES - * - GENERAL STYLES -
@ -1390,7 +1395,7 @@ div#menu_container {
div#menu { div#menu {
width: 45px; width: 45px;
float: left; float: left;
z-index: 2000; z-index: 2;
position: absolute; position: absolute;
} }
@ -1405,7 +1410,7 @@ div#head {
min-width: 882px; min-width: 882px;
background-color: #fff; background-color: #fff;
color: #000; color: #000;
z-index: 1111; z-index: 1;
} }
.fixed_header { .fixed_header {
@ -1762,7 +1767,7 @@ div.title_line {
#menu_tab_frame_view_bc { #menu_tab_frame_view_bc {
position: sticky; position: sticky;
top: 59px; top: 59px;
z-index: 1000; z-index: 1;
display: flex; display: flex;
align-items: flex-end; align-items: flex-end;
justify-content: space-between; justify-content: space-between;
@ -1811,7 +1816,7 @@ div.title_line {
} }
.breadcrumb_active { .breadcrumb_active {
color: #14524f; color: var(--primary-color);
font-size: 10pt; font-size: 10pt;
} }
@ -2058,22 +2063,6 @@ table.databox {
border-bottom-right-radius: 4px; border-bottom-right-radius: 4px;
} }
.databox.data > thead > tr:first-child > th:first-child {
border-left: 1px solid #e2e2e2;
border-top-left-radius: 4px;
border-color: #373737;
}
.databox.data > thead > tr:first-child > th:last-child {
border-right: 1px solid #e2e2e2;
border-top-right-radius: 4px;
border-color: #373737;
}
.databox.data {
border: none;
}
.tabletitle { .tabletitle {
color: #333; color: #333;
} }
@ -2774,7 +2763,10 @@ td.cellBig {
position: fixed; position: fixed;
top: 120px; top: 120px;
right: 10px; right: 10px;
z-index: 100; }
.info_box_container:not(.info_box_information) {
z-index: 1;
} }
.info_box_container.info_box_information { .info_box_container.info_box_information {
@ -3844,13 +3836,13 @@ div.div_groups_status {
} }
#menu_tab li:hover { #menu_tab li:hover {
box-shadow: inset 0px 4px #14524f; box-shadow: inset 0px 4px var(--primary-color);
} }
#menu_tab li.nomn_high, #menu_tab li.nomn_high,
#menu_tab li.nomn_high span { #menu_tab li.nomn_high span {
color: #fff; color: #fff;
box-shadow: inset 0px 4px #14524f; box-shadow: inset 0px 4px var(--primary-color);
background-color: #fff; background-color: #fff;
} }
@ -5128,19 +5120,22 @@ input:checked + .p-slider:before {
right: 4px; right: 4px;
border: none; border: none;
outline: none; outline: none;
background: url("../../images/to_top_menu.png") no-repeat center; transform: rotate(90deg);
background-color: #82b92e; background-color: #fff;
width: 27px; border: 2px solid var(--primary-color);
height: 27px; width: 25px;
height: 25px;
cursor: pointer; cursor: pointer;
border-radius: 5px; border-radius: 5px;
z-index: 10; z-index: 10;
} }
#top_btn:hover { #top_btn:hover {
background: url("../../images/to_top_menu_hover.png") no-repeat center; background-color: var(--primary-color);
background-color: #fff; }
border: 2px solid #82b92e;
#top_btn:hover > svg > g {
filter: brightness(0) invert(1);
} }
/* New white rounded boxes */ /* New white rounded boxes */
@ -9956,8 +9951,8 @@ div#err_msg_centralised {
font-size: 12px !important; font-size: 12px !important;
padding: 5.5pt 20pt; padding: 5.5pt 20pt;
cursor: pointer; cursor: pointer;
color: #14524f !important; color: var(--primary-color) !important;
border: 2px solid #14524f; border: 2px solid var(--primary-color);
box-shadow: none; box-shadow: none;
border-radius: 50px; border-radius: 50px;
align-self: baseline; align-self: baseline;
@ -10039,7 +10034,7 @@ input[type="button"],
input[type="submit"] { input[type="submit"] {
width: 175px; width: 175px;
height: 45px; height: 45px;
background-color: #14524f; background-color: var(--primary-color);
box-shadow: 0px 3px 6px #c7c7c7; box-shadow: 0px 3px 6px #c7c7c7;
letter-spacing: 0px; letter-spacing: 0px;
color: #ffffff; color: #ffffff;
@ -10065,8 +10060,8 @@ input[type="submit"].secondary {
width: 175px; width: 175px;
height: 45px; height: 45px;
background-color: #ffffff; background-color: #ffffff;
border: 2px solid #14524f; border: 2px solid var(--primary-color);
color: #14524f; color: var(--primary-color);
} }
input[type="button"].secondary:hover, input[type="button"].secondary:hover,
@ -10098,7 +10093,7 @@ button.submitButton {
line-height: 24px; line-height: 24px;
box-shadow: 0px 3px 6px #c7c7c7; box-shadow: 0px 3px 6px #c7c7c7;
color: #fff; color: #fff;
border: 2px solid #14524f; border: 2px solid var(--primary-color);
border-radius: 8px; border-radius: 8px;
padding: 0 10px; padding: 0 10px;
cursor: pointer; cursor: pointer;
@ -10108,7 +10103,7 @@ button.submitButton {
button.buttonButton.mini, button.buttonButton.mini,
button.submitButton.mini { button.submitButton.mini {
height: 32px; height: 32px;
border: 2px solid #14524f; border: 2px solid var(--primary-color);
} }
button.buttonButton > div.mini, button.buttonButton > div.mini,
@ -10121,8 +10116,8 @@ button.buttonButton:not(.secondary):not(.link),
button.submitButton:not(.secondary):not(.link) { button.submitButton:not(.secondary):not(.link) {
background: linear-gradient( background: linear-gradient(
90deg, 90deg,
#14524f 0%, var(--primary-color) 0%,
#14524f 49%, var(--primary-color) 49%,
#1d7873 50%, #1d7873 50%,
#1d7873 100% #1d7873 100%
); );
@ -10300,14 +10295,14 @@ button.submitButton.link-create-item {
button.buttonButton.secondary, button.buttonButton.secondary,
button.submitButton.secondary { button.submitButton.secondary {
background-color: #fff; background-color: #fff;
color: #14524f; color: var(--primary-color);
border: 2px solid #14524f; border: 2px solid var(--primary-color);
box-shadow: none; box-shadow: none;
} }
button.buttonButton.secondary > div, button.buttonButton.secondary > div,
button.submitButton.secondary > div { button.submitButton.secondary > div {
background-color: #14524f !important; background-color: var(--primary-color) !important;
} }
button.buttonButton.secondary:hover, button.buttonButton.secondary:hover,
@ -10335,7 +10330,7 @@ button.submitButton.secondary:active > div {
button.buttonButton.link, button.buttonButton.link,
button.submitButton.link { button.submitButton.link {
background-color: rgba(0, 0, 0, 0); background-color: rgba(0, 0, 0, 0);
color: #14524f; color: var(--primary-color);
border: 0; border: 0;
box-shadow: none; box-shadow: none;
justify-content: flex-start; justify-content: flex-start;
@ -10344,7 +10339,7 @@ button.submitButton.link {
button.buttonButton.link > div, button.buttonButton.link > div,
button.submitButton.link > div { button.submitButton.link > div {
background-color: #14524f !important; background-color: var(--primary-color) !important;
} }
button.buttonButton.link:hover, button.buttonButton.link:hover,
@ -10517,9 +10512,9 @@ button.ui-button-text-only.ui-widget.sub {
} }
button.ui-button.ui-widget.submit-next { button.ui-button.ui-widget.submit-next {
background-color: #14524f; background-color: var(--primary-color);
color: #fff; color: #fff;
border: 1px solid #14524f; border: 1px solid var(--primary-color);
} }
button.ui-button.ui-widget.submit-next:hover { button.ui-button.ui-widget.submit-next:hover {
@ -10534,7 +10529,7 @@ button.ui-button.ui-widget.submit-next:active {
button.ui-button.ui-widget.submit-cancel { button.ui-button.ui-widget.submit-cancel {
background-color: #fff; background-color: #fff;
color: #14524f; color: var(--primary-color);
border: 0; border: 0;
box-shadow: none; box-shadow: none;
} }
@ -11252,11 +11247,11 @@ span.subsection_header_title.secondary {
font-size: 15px !important; font-size: 15px !important;
margin-bottom: 5px; margin-bottom: 5px;
margin-left: 9px; margin-left: 9px;
color: #14524f; color: var(--primary-color);
} }
.table-about h2 span { .table-about h2 span {
color: #14524f; color: var(--primary-color);
font-size: large; font-size: large;
font-weight: bolder; font-weight: bolder;
} }

View File

@ -307,12 +307,6 @@ table.dataTable.info_table.no-footer {
border-bottom: none; border-bottom: none;
} }
table.dataTable thead th,
table.dataTable tfoot th {
font-size: 11pt;
font-weight: inherit !important;
}
/* Datatables pagination */ /* Datatables pagination */
.dataTables_paginate.paging_simple_numbers { .dataTables_paginate.paging_simple_numbers {
margin: 2em 0; margin: 2em 0;
@ -357,7 +351,7 @@ a.pandora_pagination:hover {
a.pandora_pagination.current, a.pandora_pagination.current,
a.pandora_pagination.current:hover { a.pandora_pagination.current:hover {
color: #fff; color: #fff;
background-color: #14524f; background-color: var(--primary-color);
} }
/* CSV button datatables */ /* CSV button datatables */
@ -492,7 +486,7 @@ a.pandora_pagination.current:hover {
.section_table_title { .section_table_title {
flex: 0 1 auto; flex: 0 1 auto;
font-size: 15px; font-size: 15px;
color: #14524f; color: var(--primary-color);
font-weight: bold; font-weight: bold;
margin: 4px 0 7px; margin: 4px 0 7px;
} }
@ -502,7 +496,7 @@ a.pandora_pagination.current:hover {
width: 14px; width: 14px;
border-radius: 15px; border-radius: 15px;
height: 3px; height: 3px;
background-color: #14524f; background-color: var(--primary-color);
margin-top: -4px; margin-top: -4px;
/*box-shadow: inset 1px 1px 1px 1px #1d7873;*/ /*box-shadow: inset 1px 1px 1px 1px #1d7873;*/
} }

View File

@ -248,6 +248,8 @@ echo '</head>'."\n";
require_once 'include/functions_themes.php'; require_once 'include/functions_themes.php';
ob_start('ui_process_page_body'); ob_start('ui_process_page_body');
ui_require_javascript_file('pandora');
$config['remote_addr'] = $_SERVER['REMOTE_ADDR']; $config['remote_addr'] = $_SERVER['REMOTE_ADDR'];
$sec2 = get_parameter_get('sec2'); $sec2 = get_parameter_get('sec2');
@ -1176,8 +1178,7 @@ if ($config['pure'] == 0) {
echo '<div id="menu">'; echo '<div id="menu">';
include 'general/main_menu.php'; include 'general/main_menu.php';
echo '</div>'; echo html_print_go_top();
echo '<button onclick="topFunction()" id="top_btn" title="Go to top"></button>';
} else { } else {
echo '<div id="main_pure">'; echo '<div id="main_pure">';
// Require menu only to build structure to use it in ACLs. // Require menu only to build structure to use it in ACLs.
@ -1548,33 +1549,6 @@ require 'include/php_to_js_values.php';
$('.action_buttons_right_content').attr('style', 'left: '+($('#menu_full').width())+'px;'); $('.action_buttons_right_content').attr('style', 'left: '+($('#menu_full').width())+'px;');
} }
function scrollFunction() {
if (document.body.scrollTop > 400 || document.documentElement.scrollTop > 400) {
if (document.getElementById("top_btn")) {
document.getElementById("top_btn").style.display = "block";
}
} else {
if (document.getElementById("top_btn")) {
document.getElementById("top_btn").style.display = "none";
}
}
}
// When the user clicks on the button, scroll to the top of the document.
function topFunction() {
/*
* Safari.
* document.body.scrollTop = 0;
* For Chrome, Firefox, IE and Opera.
* document.documentElement.scrollTop = 0;
*/
$("HTML, BODY").animate({
scrollTop: 0
}, 500);
}
function first_time_identification() { function first_time_identification() {
jQuery.post("ajax.php", { jQuery.post("ajax.php", {
"page": "general/register", "page": "general/register",

View File

@ -362,34 +362,29 @@ $table->data['search_fields'][1] = html_print_label_input_block(
) )
); );
/*
$table->data[1][0] = __('Operating System').'&nbsp;';
$pre_fields = db_get_all_rows_sql( $pre_fields = db_get_all_rows_sql(
'select distinct(tagente.id_os),tconfig_os.name from tagente,tconfig_os where tagente.id_os = tconfig_os.id_os' 'select distinct(tagente.id_os),tconfig_os.name from tagente,tconfig_os where tagente.id_os = tconfig_os.id_os'
); );
$fields = []; $fields = [];
foreach ($pre_fields as $key => $value) { foreach ($pre_fields as $key => $value) {
$fields[$value['id_os']] = $value['name']; $fields[$value['id_os']] = $value['name'];
} }
$table->data[1][0] .= html_print_select($fields, 'os', $os, '', 'All', 0, true); $table->data[1][0] = html_print_label_input_block(
__('Operating System'),
$table->data[1][1] = __('Policies').'&nbsp;'; html_print_select($fields, 'os', $os, '', 'All', 0, true)
);
$pre_fields = policies_get_policies(false, ['id', 'name']); $pre_fields = policies_get_policies(false, ['id', 'name']);
$fields = []; $fields = [];
foreach ($pre_fields as $value) { foreach ($pre_fields as $value) {
$fields[$value['id']] = $value['name']; $fields[$value['id']] = $value['name'];
} }
$table->data[1][1] .= html_print_select($fields, 'policies[]', $policies, '', 'All', 0, true, true); $table->data[1][1] = html_print_label_input_block(
__('Policies'),
$table->data[1][2] = __('Search in custom fields').'&nbsp;'.'&nbsp;'.'&nbsp;'; html_print_select($fields, 'policies[]', $policies, '', 'All', 0, true, true)
$table->data[1][2] .= html_print_input_text('search_custom', $search_custom, '', 15, 255, true); );
$custom_fields = db_get_all_fields_in_table('tagent_custom_fields'); $custom_fields = db_get_all_fields_in_table('tagent_custom_fields');
if ($custom_fields === false) { if ($custom_fields === false) {
@ -428,8 +423,7 @@ $table->data['search_fields'][1] = html_print_label_input_block(
$div_custom_fields .= '</div></div>'; $div_custom_fields .= '</div></div>';
} }
$table->colspan[2][0] = 7; $table->colspan[2][0] = 2;
$table->cellstyle[2][0] = 'padding-left: 10px;';
$table->data[2][0] = ui_toggle( $table->data[2][0] = ui_toggle(
$div_custom_fields, $div_custom_fields,
__('Agent custom fields'), __('Agent custom fields'),
@ -443,42 +437,8 @@ $table->data['search_fields'][1] = html_print_label_input_block(
); );
$table->colspan[4][0] = 4;
$table->cellstyle[4][0] = 'padding-top: 0px;';
$table->data[4][0] = html_print_button(
__('Load filter'),
'load-filter',
false,
'',
'class="float-left margin-right-2 sub config"',
true
);
$table->cellstyle[4][0] .= 'padding-top: 0px;'; $buttons = html_print_submit_button(
$table->data[4][0] .= html_print_button(
__('Manage filter'),
'save-filter',
false,
'',
'class="float-left margin-right-2 sub wand"',
true
);
$table->cellstyle[4][2] = 'padding-top: 0px;';
$table->data[4][2] = html_print_submit_button(
__('Search'),
'srcbutton',
'',
['class' => 'sub search'],
true
);
*/
$searchForm .= html_print_table($table, true);
$searchForm .= html_print_div(
[
'class' => 'action-buttons',
'content' => html_print_submit_button(
__('Filter'), __('Filter'),
'srcbutton', 'srcbutton',
false, false,
@ -487,7 +447,37 @@ $searchForm .= html_print_div(
'mode' => 'mini', 'mode' => 'mini',
], ],
true true
), );
$buttons .= html_print_button(
__('Load filter'),
'load-filter',
false,
'',
[
'icon' => 'load',
'mode' => 'mini secondary',
],
true
);
$buttons .= html_print_button(
__('Manage filter'),
'save-filter',
false,
'',
[
'icon' => 'wand',
'mode' => 'mini secondary',
],
true
);
$searchForm .= html_print_table($table, true);
$searchForm .= html_print_div(
[
'class' => 'action-buttons',
'content' => $buttons,
], ],
true true
); );
@ -1079,7 +1069,7 @@ $tableAgents->head[10] .= ui_get_sorting_arrows($url_up_last_status_change, $url
$tableAgents->size[10] = '10%'; $tableAgents->size[10] = '10%';
$tableAgents->head[11] = '<span>'.__('Agent events').'</span>'; $tableAgents->head[11] = '<span>'.__('Agent events').'</span>';
$tableAgents->head[11] = '4%'; $tableAgents->size[11] = '4%';
$tableAgents->align = []; $tableAgents->align = [];
@ -1200,7 +1190,7 @@ foreach ($agents as $agent) {
$data[1] = '<span class="'.$custom_font_size.'">'.ui_print_truncate_text($agent['description'], 'description', false, true, true, '[&hellip;]').'</span>'; $data[1] = '<span class="'.$custom_font_size.'">'.ui_print_truncate_text($agent['description'], 'description', false, true, true, '[&hellip;]').'</span>';
$data[12] = ''; $data[2] = '';
if (enterprise_installed()) { if (enterprise_installed()) {
enterprise_include_once('include/functions_config_agents.php'); enterprise_include_once('include/functions_config_agents.php');
@ -1279,9 +1269,6 @@ foreach ($agents as $agent) {
] ]
).'</a>'; ).'</a>';
// This old code was returning "never" on agents without modules, BAD !!
// And does not print outdated agents in red. WRONG !!!!
// $data[7] = ui_print_timestamp ($agent_info["last_contact"], true);
array_push($tableAgents->data, $data); array_push($tableAgents->data, $data);
} }

View File

@ -288,8 +288,10 @@ $table->data['agent_row'][] = html_print_label_input_block(
// Button. // Button.
if (is_metaconsole() === true) { if (is_metaconsole() === true) {
$table->data['captions_disabled_row'][] = __('Show only disabled'); $table->data['captions_disabled_row'][] = html_print_label_input_block(
$table->data['inputs_disabled_row'][] = html_print_checkbox('show_disabled', $show_disabled, false, true); __('Show only disabled'),
html_print_checkbox('show_disabled', $show_disabled, false, true)
);
} }
if (is_metaconsole() === false) { if (is_metaconsole() === false) {