Refactor promoteur back URL logic to prioritize new hub structure, enabling event focus functionality. Introduce fxPromoteurHubOrLegacyBackUrl for streamlined navigation based on event ID availability. Update related functions for consistency and clarity. This change enhances user experience by ensuring proper redirection based on session and event context.
This commit is contained in:
@ -32,10 +32,8 @@ if (isset($_GET['promoteur_eve_id'])) {
|
||||
if ($intEveId <= 0 || (empty($_SESSION['com_id']) && empty($_SESSION['usa_id']))
|
||||
|| (empty($_SESSION['usa_id'])
|
||||
&& !fxEveAccesHasAnyPermission($_SESSION['com_id'] ?? 0, $intEveId, array('dossards.manage', 'epreuves.edit_qte')))) {
|
||||
$strRedirect = $vDomaine . '/compte/inc_tableau_promoteur';
|
||||
if (!empty($_GET['promoteur_eve_id'])) {
|
||||
$strRedirect .= '?promoteur_eve_id=' . urlencode($_GET['promoteur_eve_id']);
|
||||
}
|
||||
// MSIN-4399 — même retour que le bouton back (hub + focus si dispo).
|
||||
$strRedirect = fxGetPromoteurBackUrl($intEveId > 0 ? $intEveId : 0, $strPage);
|
||||
header('Location: ' . $strRedirect);
|
||||
exit;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user