mirror of
https://github.com/itflow-org/itflow
synced 2026-02-28 19:04:52 +00:00
Bugfix: Client Access Permissions
Fix bug that allows users to view recurring tickets and projects they shouldn't have access to
This commit is contained in:
@@ -6,6 +6,11 @@ $order = "ASC";
|
||||
|
||||
require_once "inc_all.php";
|
||||
|
||||
// Ticket client access snippet
|
||||
$rec_ticket_permission_snippet = '';
|
||||
if (!empty($client_access_string)) {
|
||||
$rec_ticket_permission_snippet = "AND scheduled_ticket_client_id IN ($client_access_string)";
|
||||
}
|
||||
|
||||
//Rebuild URL
|
||||
$url_query_strings_sort = http_build_query($get_copy);
|
||||
@@ -16,6 +21,7 @@ $sql = mysqli_query(
|
||||
"SELECT SQL_CALC_FOUND_ROWS * FROM scheduled_tickets
|
||||
LEFT JOIN clients on scheduled_ticket_client_id = client_id
|
||||
WHERE scheduled_tickets.scheduled_ticket_subject LIKE '%$q%'
|
||||
$rec_ticket_permission_snippet
|
||||
ORDER BY $sort $order LIMIT $record_from, $record_to"
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user