From: Nik Okuntseff Date: Wed, 24 Apr 2019 13:52:34 +0000 (+0000) Subject: Fixed approve_all_reports right assignment and check. X-Git-Tag: timetracker_1.19-1~48 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=67e827dacf08d8a55dff9118c82dd964f5da12c1;p=timetracker.git Fixed approve_all_reports right assignment and check. --- diff --git a/WEB-INF/lib/ttRoleHelper.class.php b/WEB-INF/lib/ttRoleHelper.class.php index fcffd9ca..326d0faf 100644 --- a/WEB-INF/lib/ttRoleHelper.class.php +++ b/WEB-INF/lib/ttRoleHelper.class.php @@ -193,7 +193,7 @@ class ttRoleHelper { $rights_user = 'track_own_time,track_own_expenses,view_own_reports,view_own_charts,view_own_projects,view_own_tasks,manage_own_settings,view_users'; $rights_supervisor = $rights_user.',track_time,track_expenses,view_reports,approve_reports,approve_timesheets,view_charts,view_own_clients,override_punch_mode,override_date_lock,override_own_date_lock,swap_roles,update_work'; $rights_comanager = $rights_supervisor.',manage_own_account,manage_users,manage_projects,manage_tasks,manage_custom_fields,manage_clients,manage_invoices,override_allow_ip,manage_basic_settings,view_all_reports,manage_work,bid_on_work'; - $rights_manager = $rights_comanager.',manage_features,manage_advanced_settings,manage_roles,export_data,approve_own_timesheets,manage_subgroups'; + $rights_manager = $rights_comanager.',manage_features,manage_advanced_settings,manage_roles,export_data,approve_all_reports,approve_own_timesheets,manage_subgroups'; // Active roles. $name = $mdb2->quote($i18n->get('role.user.label')); @@ -254,7 +254,7 @@ class ttRoleHelper { $rights_user = 'track_own_time,track_own_expenses,view_own_reports,view_own_charts,view_own_projects,view_own_tasks,manage_own_settings,view_users'; $rights_supervisor = $rights_user.',track_time,track_expenses,view_reports,view_charts,view_own_clients,override_punch_mode,override_date_lock,override_own_date_lock,swap_roles,approve_timesheets'; $rights_comanager = $rights_supervisor.',manage_own_account,manage_users,manage_projects,manage_tasks,manage_custom_fields,manage_clients,manage_invoices,override_allow_ip,manage_basic_settings,view_all_reports'; - $rights_manager = $rights_comanager.',manage_features,manage_advanced_settings,manage_roles,export_data,approve_all_reports,manage_subgroups'; + $rights_manager = $rights_comanager.',manage_features,manage_advanced_settings,manage_roles,export_data,manage_subgroups'; // Active roles. $name = $mdb2->quote($i18n->get('role.user.label')); diff --git a/WEB-INF/resources/en.lang.php b/WEB-INF/resources/en.lang.php index 49d50236..4d1a1828 100644 --- a/WEB-INF/resources/en.lang.php +++ b/WEB-INF/resources/en.lang.php @@ -579,7 +579,7 @@ $i18n_key_words = array( 'role.top_manager.description' => 'Top group manager. Can do everything in a tree of groups.', 'role.admin.label' => 'Administrator', 'role.admin.low_case_label' => 'administrator', -'role.admin.description' => 'Site adminsitrator.', +'role.admin.description' => 'Site administrator.', // Timesheet View form. See example at https://timetracker.anuko.com/timesheet_view.php. 'form.timesheet_view.submit_subject' => 'Timesheet approval request', diff --git a/WEB-INF/templates/footer.tpl b/WEB-INF/templates/footer.tpl index 3e0c4c8a..eafc12d4 100644 --- a/WEB-INF/templates/footer.tpl +++ b/WEB-INF/templates/footer.tpl @@ -12,7 +12,7 @@
-
 Anuko Time Tracker 1.19.3.4981 | Copyright © Anuko | +  Anuko Time Tracker 1.19.3.4982 | Copyright © Anuko | {$i18n.footer.credits} | {$i18n.footer.license} | {$i18n.footer.improve} diff --git a/report.php b/report.php index 31cee67a..53c73ee1 100644 --- a/report.php +++ b/report.php @@ -91,7 +91,7 @@ $options = ttReportHelper::getReportOptions($bean); // - We can sssign items to invoices. // - We can assign items to a timesheet. // Determine these conditions separately. -if ($bean->getAttribute('chapproved') && ($user->can('approve_reports') || $user->can('approve_all_eports'))) +if ($bean->getAttribute('chapproved') && ($user->can('approve_reports') || $user->can('approve_all_reports'))) $useMarkApproved = true; if ($bean->getAttribute('chpaid') && $user->can('manage_invoices')) $useMarkPaid = true;