2013-07-26 Sergio Martin <sergio.martin@artica.es>

* godmode/reporting/reporting_builder.php: Fix errors
	on reports edition



git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@8582 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
zarzuelo 2013-07-26 11:39:32 +00:00
parent 5989111af0
commit 7f97d231fc
2 changed files with 15 additions and 4 deletions

View File

@ -1,3 +1,8 @@
2013-07-26 Sergio Martin <sergio.martin@artica.es>
* godmode/reporting/reporting_builder.php: Fix errors
on reports edition
2013-07-26 Sergio Martin <sergio.martin@artica.es> 2013-07-26 Sergio Martin <sergio.martin@artica.es>
* include/functions_filemanager.php: Fixed file manager * include/functions_filemanager.php: Fixed file manager

View File

@ -530,7 +530,6 @@ switch ($action) {
$private = 1; $private = 1;
break; break;
} }
if ($action == 'update') { if ($action == 'update') {
if ($reportName != "" && $idGroupReport != "") { if ($reportName != "" && $idGroupReport != "") {
$new_values = array('name' => $reportName, $new_values = array('name' => $reportName,
@ -544,14 +543,14 @@ switch ($action) {
array('id_report' => $idReport)); array('id_report' => $idReport));
$report_id_user = $report['id_user']; $report_id_user = $report['id_user'];
if ($report_id_user != $config['id_user'] && if ($report_id_user != $config['id_user'] &&
is_user_admin ($config["id_user"])) { !is_user_admin ($config["id_user"])) {
unset($new_values['private']); unset($new_values['private']);
unset($new_values['id_group_edit']); unset($new_values['id_group_edit']);
} }
$resultOperationDB = (bool)db_process_sql_update( $resultOperationDB = (bool)db_process_sql_update(
'treport', $new_values, 'treport', $new_values,
array('id_report' => $idReport)); array('id_report' => $idReport));
if ($resultOperationDB !== false) if ($resultOperationDB !== false)
db_pandora_audit( "Report management", db_pandora_audit( "Report management",
"Update report #$idReport"); "Update report #$idReport");
@ -1352,7 +1351,7 @@ switch ($action) {
$buttons = array( $buttons = array(
'list_reports' => array('active' => false, 'list_reports' => array('active' => false,
'text' => '<a href="index.php?sec=reporting&sec2=godmode/reporting/reporting_builder&pure='.$pure.'">' . 'text' => '<a href="index.php?sec=reporting&sec2=godmode/reporting/reporting_builder&pure='.$pure.'">' .
html_print_image("images/op_reporting.png", true, array ("title" => __('Reports list'))) .'</a>') html_print_image("images/report_list.png", true, array ("title" => __('Reports list'))) .'</a>')
); );
$buttons = reporting_enterprise_add_main_Tabs($buttons); $buttons = reporting_enterprise_add_main_Tabs($buttons);
@ -1401,7 +1400,14 @@ if ($enterpriseEnable) {
} }
} }
$buttons = array(
);
$buttons = array( $buttons = array(
'list_reports' => array('active' => false,
'text' => '<a href="index.php?sec=reporting&sec2=godmode/reporting/reporting_builder&pure='.$pure.'">' .
html_print_image("images/report_list.png", true, array ("title" => __('Reports list'))) .'</a>'),
'main' => array('active' => false, 'main' => array('active' => false,
'text' => '<a href="index.php?sec=reporting&sec2=godmode/reporting/reporting_builder&tab=main&action=edit&id_report=' . $idReport . '&pure='.$pure.'">' . 'text' => '<a href="index.php?sec=reporting&sec2=godmode/reporting/reporting_builder&tab=main&action=edit&id_report=' . $idReport . '&pure='.$pure.'">' .
html_print_image("images/op_reporting.png", true, array ("title" => __('Main data'))) .'</a>'), html_print_image("images/op_reporting.png", true, array ("title" => __('Main data'))) .'</a>'),