From 73175e2b64c85c7a8c528c76452cd82ffa99f925 Mon Sep 17 00:00:00 2001 From: Igor Scheller Date: Mon, 28 Aug 2017 16:21:10 +0200 Subject: #337: Added routing --- includes/pages/admin_active.php | 52 +++++++++++++++++++++++++++++------------ 1 file changed, 37 insertions(+), 15 deletions(-) (limited to 'includes/pages/admin_active.php') diff --git a/includes/pages/admin_active.php b/includes/pages/admin_active.php index 2e06f90d..5b91e413 100644 --- a/includes/pages/admin_active.php +++ b/includes/pages/admin_active.php @@ -82,9 +82,13 @@ function admin_active() $limit = ''; $msg = success(_('Marked angels.'), true); } else { - $set_active = '« ' - . _('back') . ' | ' + $set_active = '« ' + . _('back') + . ' | ' . _('apply') . ''; } @@ -176,28 +180,46 @@ function admin_active() $actions = []; if ($usr['Aktiv'] == 0) { - $actions[] = '' + $parameters = [ + 'active' => $usr['UID'], + 'search' => $search, + ]; + if ($show_all_shifts) { + $parameters['show_all_shifts'] = 1; + } + $actions[] = '' . _('set active') . ''; } if ($usr['Aktiv'] == 1 && $usr['Tshirt'] == 0) { - $actions[] = '' + $parametersRemove = [ + 'not_active' => $usr['UID'], + 'search' => $search, + ]; + $parametersShirt = [ + 'tshirt' => $usr['UID'], + 'search' => $search, + ]; + if ($show_all_shifts) { + $parametersRemove['show_all_shifts'] = 1; + $parametersShirt['show_all_shifts'] = 1; + } + $actions[] = '' . _('remove active') . ''; - $actions[] = '' + $actions[] = '' . _('got t-shirt') . ''; } if ($usr['Tshirt'] == 1) { - $actions[] = '' + $parameters = [ + 'not_tshirt' => $usr['UID'], + 'search' => $search, + ]; + if ($show_all_shifts) { + $parameters['show_all_shifts'] = 1; + } + $actions[] = '' . _('remove t-shirt') . ''; } -- cgit v1.2.3-54-g00ecf