From 58531ac7b1ba11a4316efddbacb14b95ce434723 Mon Sep 17 00:00:00 2001 From: Nate Date: Tue, 20 Oct 2020 11:55:16 -0600 Subject: [PATCH] Group Manager - Permissions: Add filter for assigned/unassigned. --- core/groups/app_languages.php | 42 +++++++++++++++ core/groups/group_permissions.php | 86 +++++++++++++++++++------------ 2 files changed, 96 insertions(+), 32 deletions(-) diff --git a/core/groups/app_languages.php b/core/groups/app_languages.php index a703294a8c..f984c6967c 100644 --- a/core/groups/app_languages.php +++ b/core/groups/app_languages.php @@ -1681,6 +1681,48 @@ $text['label-12-hour']['ru-ru'] = "12-часовой"; $text['label-12-hour']['sv-se'] = "12-timmars"; $text['label-12-hour']['uk-ua'] = "12-годинний"; +$text['label-assigned']['en-us'] = "Assigned"; +$text['label-assigned']['en-gb'] = "Assigned"; +$text['label-assigned']['ar-eg'] = "Assigned"; +$text['label-assigned']['de-at'] = "Assigned"; +$text['label-assigned']['de-ch'] = "Assigned"; +$text['label-assigned']['de-de'] = "Assigned"; +$text['label-assigned']['es-cl'] = "Assigned"; +$text['label-assigned']['es-mx'] = "Assigned"; +$text['label-assigned']['fr-ca'] = "Assigned"; +$text['label-assigned']['fr-fr'] = "Assigned"; +$text['label-assigned']['he-il'] = "Assigned"; +$text['label-assigned']['it-it'] = "Assigned"; +$text['label-assigned']['nl-nl'] = "Assigned"; +$text['label-assigned']['pl-pl'] = "Assigned"; +$text['label-assigned']['pt-br'] = "Assigned"; +$text['label-assigned']['pt-pt'] = "Assigned"; +$text['label-assigned']['ro-ro'] = "Assigned"; +$text['label-assigned']['ru-ru'] = "Assigned"; +$text['label-assigned']['sv-se'] = "Assigned"; +$text['label-assigned']['uk-ua'] = "Assigned"; + +$text['label-unassigned']['en-us'] = "Unassigned"; +$text['label-unassigned']['en-gb'] = "Unassigned"; +$text['label-unassigned']['ar-eg'] = "Unassigned"; +$text['label-unassigned']['de-at'] = "Unassigned"; +$text['label-unassigned']['de-ch'] = "Unassigned"; +$text['label-unassigned']['de-de'] = "Unassigned"; +$text['label-unassigned']['es-cl'] = "Unassigned"; +$text['label-unassigned']['es-mx'] = "Unassigned"; +$text['label-unassigned']['fr-ca'] = "Unassigned"; +$text['label-unassigned']['fr-fr'] = "Unassigned"; +$text['label-unassigned']['he-il'] = "Unassigned"; +$text['label-unassigned']['it-it'] = "Unassigned"; +$text['label-unassigned']['nl-nl'] = "Unassigned"; +$text['label-unassigned']['pl-pl'] = "Unassigned"; +$text['label-unassigned']['pt-br'] = "Unassigned"; +$text['label-unassigned']['pt-pt'] = "Unassigned"; +$text['label-unassigned']['ro-ro'] = "Unassigned"; +$text['label-unassigned']['ru-ru'] = "Unassigned"; +$text['label-unassigned']['sv-se'] = "Unassigned"; +$text['label-unassigned']['uk-ua'] = "Unassigned"; + $text['header-user_setting-edit']['en-us'] = "User Setting"; $text['header-user_setting-edit']['en-gb'] = "User Setting"; $text['header-user_setting-edit']['ar-eg'] = ""; diff --git a/core/groups/group_permissions.php b/core/groups/group_permissions.php index b8c92f8729..35a503f975 100644 --- a/core/groups/group_permissions.php +++ b/core/groups/group_permissions.php @@ -94,6 +94,9 @@ } } +//get the view preference + $view = $_REQUEST['view']; + //get the http post data if (is_array($_POST['group_permissions'])) { $action = $_POST['action']; @@ -233,7 +236,7 @@ $token = new token; if (!$token->validate($_SERVER['PHP_SELF'])) { message::add($text['message-invalid_token'],'negative'); - header('Location: group_permissions.php?group_uuid='.urlencode($group_uuid).'&search='.urlencode($search)); + header('Location: group_permissions.php?group_uuid='.urlencode($group_uuid).($view ? '&view='.urlencode($view) : null).($search ? '&search='.urlencode($search) : null)); exit; } @@ -264,10 +267,6 @@ exit; } -//get order and order by - //$order_by = $_GET["order_by"]; - //$order = $_GET["order"]; - //create token $object = new token; $token = $object->create($_SERVER['PHP_SELF']); @@ -287,7 +286,12 @@ } echo "