From 94195cf70afa677d090e7267cc68b987252df2a6 Mon Sep 17 00:00:00 2001 From: Tatiana Llorente Date: Thu, 29 Aug 2019 11:27:40 +0200 Subject: [PATCH] Change permissions to save custom graph in agent view - #4575 --- pandora_console/operation/agentes/graphs.php | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/pandora_console/operation/agentes/graphs.php b/pandora_console/operation/agentes/graphs.php index 79ff02b021..308481d8e0 100644 --- a/pandora_console/operation/agentes/graphs.php +++ b/pandora_console/operation/agentes/graphs.php @@ -244,14 +244,18 @@ $htmlForm = '
'; -$htmlForm .= html_print_button( - __('Save as custom graph'), - 'save_custom_graph', - false, - '', - 'class="sub add" style=""', - true -).'  '.html_print_submit_button(__('Filter'), 'filter_button', false, 'class="sub upd" style=""', true); +if (check_acl($config['id_user'], 0, 'RW') || check_acl($config['id_user'], 0, 'RM')) { + $htmlForm .= html_print_button( + __('Save as custom graph'), + 'save_custom_graph', + false, + '', + 'class="sub add" style=""', + true + ); +} + +$htmlForm .= '  '.html_print_submit_button(__('Filter'), 'filter_button', false, 'class="sub upd" style=""', true); $htmlForm .= ''; $htmlForm .= '
';