Merge branch 'ent-13283-botones-de-borrar-y-crear-en-custom-graphs-con-usuario-de-solo-lectura-sin-edit-o-manage' into 'develop'

Ent 13283 botones de borrar y crear en custom graphs con usuario de solo lectura sin edit o manage

See merge request artica/pandorafms!7347
This commit is contained in:
Enrique Martin 2024-05-09 09:52:05 +00:00
commit 89381e4b8b
2 changed files with 15 additions and 11 deletions

View File

@ -22,14 +22,18 @@ $msg = __(
$msg .= '<br><br>'.__("There are two types of graphs: The agent's automated graphs and the graphs the user customizes by using one or more modules to do so.");
$url_new = 'index.php?sec=reporting&sec2=godmode/reporting/graph_builder';
$button = '<form action="'.$url_new.'" method="post">
<input type="submit" class="button_task button_task_mini mrgn_0px_imp" value="'.__('Create custom graph').'" />
</form>';
$button = '';
echo ui_print_empty_view(
__('Create custom graph'),
$msg,
'custom-graph.svg',
$button
);
if (check_acl($config['id_user'], 0, 'RW') || check_acl($config['id_user'], 0, 'RM')) {
$url_new = 'index.php?sec=reporting&sec2=godmode/reporting/graph_builder';
$button = '<form action="'.$url_new.'" method="post">
<input type="submit" class="button_task button_task_mini mrgn_0px_imp" value="'.__('Create custom graph').'" />
</form>';
}
echo ui_print_empty_view(
__('Create custom graph'),
$msg,
'custom-graph.svg',
$button
);

View File

@ -481,7 +481,7 @@ if (!empty($graphs)) {
$ActionButtons[] = '</form>';
}
if (!empty($result_graphs)) {
if (!empty($result_graphs) && ($report_w || $report_m)) {
$ActionButtons[] = "<form method='post' id='form_delete' action='index.php?sec=reporting&sec2=godmode/reporting/graphs'>";
$ActionButtons[] = html_print_input_hidden('multiple_delete', 1, true);
$ActionButtons[] = html_print_submit_button(