#11713 Fix action button title
This commit is contained in:
parent
0a6301a3a8
commit
fd56631ae4
|
@ -807,12 +807,12 @@ foreach ($commands as $command) {
|
|||
// (IMPORTANT, DO NOT CHANGE!) only users with permissions over "All" group have access to edition of commands belonging to "All" group.
|
||||
if ($is_management_allowed === true && !$command['internal'] && check_acl_restricted_all($config['id_user'], $command['id_group'], 'LM')) {
|
||||
if (is_user_admin($config['id_user']) === true) {
|
||||
$data['action'] = '<span class="inline_flex">';
|
||||
$data['action'] = '<span class="inline_flex">';
|
||||
$data['action'] .= '<a href="index.php?sec='.$sec.'&sec2=godmode/alerts/alert_commands&copy_command=1&id='.$command['id'].'&pure='.$pure.'&offset='.$offset.'"
|
||||
onClick="if (!confirm(\''.__('Are you sure?').'\')) return false;">'.html_print_image('images/copy.svg', true, ['class' => 'main_menu_icon invert_filter']).'</a>';
|
||||
onClick="if (!confirm(\''.__('Are you sure?').'\')) return false;">'.html_print_image('images/copy.svg', true, ['class' => 'main_menu_icon invert_filter ', 'title' => 'Duplicate']).'</a>';
|
||||
|
||||
$data['action'] .= '<a href="index.php?sec='.$sec.'&sec2=godmode/alerts/alert_commands&delete_command=1&id='.$command['id'].'&pure='.$pure.'&offset='.$offset_delete.'"
|
||||
onClick="if (!confirm(\''.__('Are you sure?').'\')) return false;">'.html_print_image('images/delete.svg', true, ['class' => 'main_menu_icon invert_filter']).'</a>';
|
||||
onClick="if (!confirm(\''.__('Are you sure?').'\')) return false;">'.html_print_image('images/delete.svg', true, ['class' => 'main_menu_icon invert_filter', 'title' => 'Delete']).'</a>';
|
||||
$data['action'] .= '</span>';
|
||||
}
|
||||
}
|
||||
|
|
|
@ -912,7 +912,10 @@ foreach ($simple_alerts as $alert) {
|
|||
1,
|
||||
'padding:0px; width: 22px; height: 22px;',
|
||||
true,
|
||||
['class' => 'invert_filter main_menu_icon']
|
||||
[
|
||||
'class' => 'invert_filter main_menu_icon',
|
||||
'title' => __('Enable'),
|
||||
]
|
||||
);
|
||||
$data[4] .= html_print_input_hidden('enable_alert', 1, true);
|
||||
} else {
|
||||
|
@ -922,7 +925,10 @@ foreach ($simple_alerts as $alert) {
|
|||
1,
|
||||
'padding:0px; width: 22px; height: 22px;',
|
||||
true,
|
||||
['class' => 'main_menu_icon']
|
||||
[
|
||||
'class' => 'main_menu_icon',
|
||||
'title' => __('Disable'),
|
||||
]
|
||||
);
|
||||
$data[4] .= html_print_input_hidden('disable_alert', 1, true);
|
||||
}
|
||||
|
@ -940,7 +946,10 @@ foreach ($simple_alerts as $alert) {
|
|||
1,
|
||||
'padding:0px; width: 22px; height: 22px;',
|
||||
true,
|
||||
['class' => 'invert_filter main_menu_icon']
|
||||
[
|
||||
'class' => 'invert_filter main_menu_icon',
|
||||
'title' => __('Standby off'),
|
||||
]
|
||||
);
|
||||
$data[4] .= html_print_input_hidden('standbyon_alert', 1, true);
|
||||
} else {
|
||||
|
@ -950,7 +959,10 @@ foreach ($simple_alerts as $alert) {
|
|||
1,
|
||||
'padding:0px; width: 22px; height: 22px;',
|
||||
true,
|
||||
['class' => 'invert_filter main_menu_icon']
|
||||
[
|
||||
'class' => 'invert_filter main_menu_icon',
|
||||
'title' => __('Standby on'),
|
||||
]
|
||||
);
|
||||
$data[4] .= html_print_input_hidden('standbyoff_alert', 1, true);
|
||||
}
|
||||
|
|
|
@ -210,7 +210,10 @@ if ((isset($_GET['form_add'])) or (isset($_GET['form_edit']))) {
|
|||
echo '<td class="'.$tdcolor.' table_action_buttons"><a href="index.php?sec=gsetup&sec2=godmode/setup/links&id_link='.$row['id_link'].'&borrar='.$row['id_link'].'" onClick="if (!confirm(\' '.__('Are you sure?').'\')) return false;">'.html_print_image(
|
||||
'images/delete.svg',
|
||||
true,
|
||||
['class' => 'invert_filter']
|
||||
[
|
||||
'class' => 'invert_filter main_menu_icon',
|
||||
'title' => __('Delete'),
|
||||
]
|
||||
).'</a></td></tr>';
|
||||
}
|
||||
|
||||
|
|
|
@ -132,7 +132,15 @@ foreach ($osList as $os) {
|
|||
$data[] = html_print_anchor(
|
||||
[
|
||||
'href' => $hrefDelete,
|
||||
'content' => html_print_image('images/delete.svg', true, ['class' => 'main_menu_icon invert_filter']),
|
||||
'content' => html_print_image(
|
||||
'images/delete.svg',
|
||||
true,
|
||||
[
|
||||
'alt' => __('Delete'),
|
||||
'title' => __('Delete'),
|
||||
'class' => 'main_menu_icon invert_filter',
|
||||
]
|
||||
),
|
||||
],
|
||||
true
|
||||
);
|
||||
|
|
|
@ -2002,6 +2002,7 @@ if ($create_alert || $update_alert) {
|
|||
'alt' => __('Update'),
|
||||
'border' => 0,
|
||||
'class' => 'main_menu_icon',
|
||||
'title' => __('Edit'),
|
||||
]
|
||||
),
|
||||
],
|
||||
|
@ -2170,24 +2171,11 @@ if ($create_alert || $update_alert) {
|
|||
echo '</form>';
|
||||
}
|
||||
|
||||
echo '<div class="right">';
|
||||
echo '<form name="agente" method="post" action="index.php?sec=snmpconsole&sec2=godmode/snmpconsole/snmp_alert">';
|
||||
html_print_input_hidden('create_alert', 1);
|
||||
$submitButton = html_print_submit_button(
|
||||
__('Create'),
|
||||
'alert',
|
||||
false,
|
||||
['icon' => 'wand'],
|
||||
true
|
||||
);
|
||||
html_print_action_buttons($submitButton.$deleteButton, ['right_content' => $pagination]);
|
||||
echo '</form></div>';
|
||||
|
||||
$legend = '<table id="legend_snmp_alerts"class="w100p"><td><div class="snmp_view_div w100p legend_white">';
|
||||
$legend .= '<div class="display-flex"><div class="flex-50">';
|
||||
$priorities = get_priorities();
|
||||
$half = (count($priorities) / 2);
|
||||
$count = 0;
|
||||
$legend = '<table id="legend_snmp_alerts"class="w100p"><td><div class="snmp_view_div w100p legend_white">';
|
||||
$legend .= '<div class="display-flex"><div class="flex-50">';
|
||||
$priorities = get_priorities();
|
||||
$half = (count($priorities) / 2);
|
||||
$count = 0;
|
||||
foreach ($priorities as $num => $name) {
|
||||
if ($count == $half) {
|
||||
$legend .= '</div><div class="mrgn_lft_5px flex-50">';
|
||||
|
@ -2198,11 +2186,24 @@ if ($create_alert || $update_alert) {
|
|||
$count++;
|
||||
}
|
||||
|
||||
$legend .= '</div></div></div></td>';
|
||||
$legend .= '</div></div></div></td></tr></table>';
|
||||
|
||||
ui_toggle($legend, __('Legend'));
|
||||
ui_toggle($legend, __('Legend'));
|
||||
|
||||
unset($table);
|
||||
unset($table);
|
||||
|
||||
echo '<div class="right">';
|
||||
echo '<form name="agente" method="post" action="index.php?sec=snmpconsole&sec2=godmode/snmpconsole/snmp_alert">';
|
||||
html_print_input_hidden('create_alert', 1);
|
||||
$submitButton = html_print_submit_button(
|
||||
__('Create'),
|
||||
'alert',
|
||||
false,
|
||||
['icon' => 'wand'],
|
||||
true
|
||||
);
|
||||
html_print_action_buttons($submitButton.$deleteButton, ['right_content' => $pagination]);
|
||||
echo '</form></div>';
|
||||
}
|
||||
|
||||
ui_require_javascript_file('pandora', 'include/javascript/', true);
|
||||
|
|
|
@ -766,7 +766,18 @@ function filemanager_file_explorer(
|
|||
&& ($readOnly === false)
|
||||
) {
|
||||
$data[4] .= '<form method="post" action="'.$url.'" style="">';
|
||||
$data[4] .= '<input type="image" style="margin-top: 2px;height:21px" class="invert_filter main_menu_icon" src="images/delete.svg" onClick="if (!confirm(\' '.__('Are you sure?').'\')) return false;">';
|
||||
$data[4] .= html_print_input_image(
|
||||
'delete',
|
||||
'images/delete.svg',
|
||||
1,
|
||||
'margin-top: 2px;height:21px',
|
||||
true,
|
||||
[
|
||||
'title' => __('Delete'),
|
||||
'class' => 'invert_filter main_menu_icon',
|
||||
'onclick' => 'if (!confirm(\' '.__('Are you sure?').'\')) return false;',
|
||||
]
|
||||
);
|
||||
$data[4] .= html_print_input_hidden('filename', $fileinfo['realpath'], true);
|
||||
$data[4] .= html_print_input_hidden('hash', md5($fileinfo['realpath'].$config['server_unique_identifier']), true);
|
||||
$data[4] .= html_print_input_hidden('delete_file', 1, true);
|
||||
|
|
|
@ -3329,6 +3329,18 @@ function html_print_input_image($name, $src, $value, $style='', $return=false, $
|
|||
'disabled',
|
||||
];
|
||||
|
||||
if (isset($options['title']) && $options['title'] != '') {
|
||||
if (isset($options['class'])) {
|
||||
$options['class'] .= ' forced_title';
|
||||
} else {
|
||||
$options['class'] = 'forced_title';
|
||||
}
|
||||
|
||||
// New way to show the force_title (cleaner and better performance).
|
||||
$output .= 'data-title="'.io_safe_input_html($options['title']).'" ';
|
||||
$output .= 'data-use_title_for_force_title="1" ';
|
||||
}
|
||||
|
||||
foreach ($attrs as $attribute) {
|
||||
if (isset($options[$attribute])) {
|
||||
$output .= ' '.$attribute.'="'.io_safe_input_html($options[$attribute]).'"';
|
||||
|
|
Loading…
Reference in New Issue