diff --git a/CHANGELOG.md b/CHANGELOG.md index 45e8f1f..44873fc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/). ## [unrelease] - +### Fixed + +- Redirect user after escalation if he has no rights to the ticket + ## [2.9.9] - 2024-09-10 ### Fixed diff --git a/front/ticket.form.php b/front/ticket.form.php index c144c55..79f7eef 100644 --- a/front/ticket.form.php +++ b/front/ticket.form.php @@ -86,6 +86,15 @@ ) . $_POST['comment'] ]); } + + if (!$track->can($_POST["tickets_id"], READ)) { + Session::addMessageAfterRedirect( + __('You have been redirected because you no longer have access to this ticket'), + true, + ERROR + ); + Html::redirect($CFG_GLPI["root_doc"] . "/front/ticket.php"); + } } Html::back();