Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Feat: permission checks in ticket escalation #249

Open
OCMan2K opened this issue Sep 25, 2024 · 4 comments
Open

Feat: permission checks in ticket escalation #249

OCMan2K opened this issue Sep 25, 2024 · 4 comments

Comments

@OCMan2K
Copy link

OCMan2K commented Sep 25, 2024

Hello, I have a request, is it possible to have a checkbox in the parameters of the plugin to select wich right in the technician profile should be checked for allowing the escalade button to show up?
We would like to have escalade showing up without "assign ticket" right but with "steal ticket" ,
having the choice in the parameters should be a great improvement for us.

PS : when assign ticked is checked, the techician can see the ticket of the other group and change group directly, we want technician to only see their own groups tickets and to be able to escalade to other group thanks to your plugin.

Hope my request is clear.
Thank you very much!

@OCMan2K
Copy link
Author

OCMan2K commented Sep 26, 2024

I am sorry , its not an issue but a request, so I will close this and open it in Pull Request...

@OCMan2K OCMan2K closed this as completed Sep 26, 2024
@OCMan2K OCMan2K reopened this Sep 26, 2024
@OCMan2K
Copy link
Author

OCMan2K commented Sep 26, 2024

sorry i can't find how to complete pull request, so I leave it there. thank you :)

@stonebuzz stonebuzz changed the title fix: permission checks in ticket escalation Feat: permission checks in ticket escalation Sep 26, 2024
@OCMan2K
Copy link
Author

OCMan2K commented Sep 26, 2024

it should be a great improvement to choose the filtering right checked in a checklist, ( delete, purge, assign, steal ) as it shoud make the plugin really configurable to anybody needs.

ps: thanks for having corrected the title to better reflect the request.

@OCMan2K
Copy link
Author

OCMan2K commented Oct 1, 2024

for the time, I found a way to use the right "canPurge", it can also be done with "canDelete" , modified 2 files :
Ticket.class.php in inc subfolder :
public static function addToTimeline($options)
{
if (!($options['item'] instanceof Ticket)) {
return [];
}

    if (!$options['item']->canPurge()) {
        return [];
    }

And ticket.form.php in front subfolder :
// Same right check as in PluginEscaladeTicket::addToTimeline()
if (!$ticket->canPurge()) {
Html::displayRightError();
}

But it would be great to have the option to choose the right in plugin config page.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant