From f39ef3d5c7e57d656a3c1076cc051fdbdda0566d Mon Sep 17 00:00:00 2001 From: splohmer <113967431+splohmer@users.noreply.github.com> Date: Wed, 21 Jan 2026 14:25:24 +0100 Subject: [PATCH] FIX missmatch of permission check of button and action of cancel delivery note (expedition) (#36943) In expedition/card.php there is the action "confirm_cancel" which checks for the right supprimer of expedition. The corresponding UI Button checks for creer of expedition. This means some people can see the button, but nothing happens when clicking on it (also no error message). --- htdocs/expedition/card.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/expedition/card.php b/htdocs/expedition/card.php index febaff2c9bb..e5d31de915d 100644 --- a/htdocs/expedition/card.php +++ b/htdocs/expedition/card.php @@ -648,7 +648,7 @@ if (empty($reshook)) { } } } - } elseif ($action == 'confirm_cancel' && $confirm == 'yes' && $user->hasRight('expedition', 'supprimer')) { + } elseif ($action == 'confirm_cancel' && $confirm == 'yes' && $user->hasRight('expedition', 'creer')) { $also_update_stock = (GETPOST('alsoUpdateStock', 'alpha') ? 1 : 0); $result = $object->cancel($user, 0, (bool) $also_update_stock); if ($result > 0) {