From 0e4fbdd747d5c4db09cebfd7b16b5d4d684b2e1c Mon Sep 17 00:00:00 2001 From: axman Date: Thu, 30 Sep 2021 12:32:30 -0700 Subject: [PATCH 1/5] fixing bugs --- Controller/GrouperGroupsController.php | 6 +- Model/GrouperGroup.php | 163 ++++++++++++++++--------- 2 files changed, 109 insertions(+), 60 deletions(-) diff --git a/Controller/GrouperGroupsController.php b/Controller/GrouperGroupsController.php index 1a03e42..c02afac 100644 --- a/Controller/GrouperGroupsController.php +++ b/Controller/GrouperGroupsController.php @@ -114,8 +114,6 @@ public function index() { public function groupInfo() { $name = urldecode($this->request->query['groupname']); - $this->set('isuserowner', $this->GrouperGroup->isUserOwner($this->userId)); - $this->set('title', _txt('pl.grouperlite.title.groupinfo')); try { @@ -139,6 +137,7 @@ public function groupInfo() { $this->Flash->set(_txt('pl.grouperlite.message.flash.group-detail-members-failed'), array('key' => 'error')); } + $this->set('isuserowner', $this->GrouperGroup->isUserOwner($this->userId)); $this->set('grouperbaseurl', $this->Session->read('Plugin.Grouper.Api.grouperUrl')); } @@ -752,11 +751,10 @@ private function breakoutGroups(array $recordSet, $type = 'basic') { $wgRec['workingDesc'] = $this->hackDescription($rec['description']); //Capturing record for incommon-collab since deleting a few lines below. if ($rec['WGApp'] == 'incommon-collab') { - $recToDelete = $subCount; if ($type == 'basic') { //Removing record with stem of 'incommon-collab' since displaying on groups Member page, // will show on Admin page - unset($wgRec['Groups'][$recToDelete]); + unset($wgRec['Groups'][$subCount]); } } $subCount += 1; diff --git a/Model/GrouperGroup.php b/Model/GrouperGroup.php index dd22c00..86f5e41 100644 --- a/Model/GrouperGroup.php +++ b/Model/GrouperGroup.php @@ -47,7 +47,6 @@ class GrouperGroup extends GrouperLiteAppModel /** @var string Group whose members can create Groups via Template process */ private $templateCreationGroup = 'ref:workinggroupadmins'; - private $wgStemsTopLevel = array( 'ref:incommon-collab' ); @@ -61,9 +60,8 @@ class GrouperGroup extends GrouperLiteAppModel 'ref:incommon-collab' ); - private $emailStem ='app:sympa'; - - + //Stem for email groups, only email groups using this stem are viewable + private $emailStem = 'app:sympa'; // Current listing of stems that are allowed to be viewed in Comanage as AdHoc groups private $stemsAdHocAllowed = array( @@ -109,7 +107,6 @@ public function isUserOwner(string $userId) { } } - /** * Used to instantiate API class * @@ -124,18 +121,33 @@ private function initApi() { } } + /** + * Listing of members in an email group + * + * @param array $conditions Listing of conditions for display of records, including UserId + * @return array List of members that belong to email group + * @throws GrouperLiteException + * + */ public function filteredMemberOfEmails(array $conditions) { + $this->initApi(); - $memberOfEmails = $this->filteredMemberOfGroups($conditions); + try { + $memberOfEmails = $this->filteredMemberOfGroups($conditions); - // Strip out all Groups that are not in app:sympa Stem/Directory - foreach ($memberOfEmails as $key => $value) { - if (strpos(strtolower($value['name']), $this->emailStem) === false) { - unset($memberOfEmails[$key]); + // Strip out all Groups that are not in app:sympa Stem/Directory + foreach ($memberOfEmails as $key => $value) { + if (strpos(strtolower($value['name']), $this->emailStem) === false) { + unset($memberOfEmails[$key]); + } } + return array_values($memberOfEmails); + + } catch (Exception $e) { + CakeLog::write('error', __METHOD__ . ': An error occurred'); + throw $e; } - return array_values($memberOfEmails); } /** @@ -201,7 +213,7 @@ private function memberOfGroups(array $conditions) { * Gets the Grouper Groups params and values as well as its associated attributes. * * @param string $groupName Name of Group, do not confuse with DisplayName field! - * @return array An set of attributes associated to a specific Grouper Group + * @return array A set of attributes associated to a specific Grouper Group * @throws GrouperLiteException */ public function groupDescriptions(string $groupName) { @@ -328,17 +340,34 @@ public function membersInGroup(array $conditions) { } } + /** + * List of Email Groups a user can opt into. + * + * @param array $conditions Listing of conditions for display of records, including UserId + * @return array Listing of Optin email groups available in Groupe + * @throws GrouperLiteException Captured in Controller + * + */ public function optinEmailGroups(array $conditions) { - $allGroups = $this->optinGroups($conditions); + $this->initApi(); + + try { + $allGroups = $this->optinGroups($conditions); - // Strip out all Groups that are not in Sympa Stem/Directory - foreach ($allGroups as $key => $value) { - if (strpos($value['name'], $this->emailStem) === false) { - unset($allGroups[$key]); + // Strip out all Groups that are not in Sympa Stem/Directory + foreach ($allGroups as $key => $value) { + if (strpos($value['name'], $this->emailStem) === false) { + unset($allGroups[$key]); + } } + + return array_values($allGroups); + + } catch (Exception $e) { + CakeLog::write('error', __METHOD__ . ': An error occurred'); + throw $e; } - return array_values($allGroups); } /** @@ -598,23 +627,64 @@ public function getSearchedGroups(array $conditions) { * * @param array $conditions Listing of conditions for display of records with pagination * @return array Records requested by user with pagination support + * @throws Exception Captured in Controller * */ public function paginate($conditions) { + try { + //Pull out the method that should be run. + $method = $conditions['method']; - //Pull out the method that should be run. - $method = $conditions['method']; + $resultSet = $this->$method($conditions); - $resultSet = $this->$method($conditions); + if (isset($conditions['emailonly']) && $conditions['emailonly']) { + if ($method == 'getSearchedGroups' || $method == 'filteredMemberOfEmails') { + $friendlyResults = $this->getFriendlyEmailName($resultSet, 'member'); + } else { + $friendlyResults = $this->getFriendlyEmailName($resultSet, ''); + } - if (isset($conditions['emailonly']) && $conditions['emailonly']) { - $friendlyResults = $this->getFriendlyEmailName($resultSet); - } else { - $friendlyResults = $this->getFriendlyWorkingGroupName($resultSet); + } else { + if ($method == 'getSearchedGroups' || $method == 'filteredMemberOfGroups') { + $friendlyResults = $this->getFriendlyWorkingGroupName($resultSet, 'member'); + } else { + $friendlyResults = $this->getFriendlyWorkingGroupName($resultSet, ''); + } + } + + return $this->paginateRecords($friendlyResults, $conditions); + } catch (Exception $e) { + CakeLog::write('error', __METHOD__ . ': An error occurred'); + throw $e; } + } + + private function getFriendlyEmailName(array $groups, $method) { - return $this->paginateRecords($friendlyResults, $conditions); + $arrayIndex = 0; + foreach ($groups as &$group) { + $appName = ''; + if ($method == 'member') { + if ($group['extension'] == 'admins' || $group['extension'] == 'owners') { + unset($groups[$arrayIndex]); + } + } + $stems = explode(':', $group['name']); + $sectionCount = count($stems) - 2; + $groupName = $stems[$sectionCount]; + $domain = $stems[2]; + if (strtolower($domain) == 'incommon') { + $address = $groupName . '@lists.incommon.org'; + } elseif (strtolower($domain) == 'internet2') { + $address = $groupName . '@lists.internet2.edu'; + } else { + $address = $groupName . '@lists.' . strtolower($domain) . '.org'; + } + $group['friendlyEmail'] = $address; + $arrayIndex += 1; + } + return $groups; } /** @@ -629,7 +699,7 @@ public function paginate($conditions) { * @return array Listing of Groups in WG format for display * */ - private function getFriendlyWorkingGroupName(array $groups) { + private function getFriendlyWorkingGroupName(array $groups, $method) { $arrayIndex = 0; @@ -642,8 +712,8 @@ private function getFriendlyWorkingGroupName(array $groups) { $stemSections = explode(':', $group['name']); //Get second to last stem section $sectionCount = count($stemSections) - 2; - if (in_array($stemSections[$sectionCount], $topLevelWG) === false){ - $topLevelWG[] = $stemSections[$sectionCount]; + if (in_array($stemSections[$sectionCount], $topLevelWG) === false) { + $topLevelWG[] = $stemSections[$sectionCount]; } } } @@ -659,7 +729,7 @@ private function getFriendlyWorkingGroupName(array $groups) { //Get second to last stem section $sectionCount = count($stemSections) - 2; //If group not part of a top level WG, then do not show! - if (in_array($stemSections[$sectionCount], $topLevelWG) === false){ + if (in_array($stemSections[$sectionCount], $topLevelWG) === false) { break; } $group['WGName'] = $stemSections[$sectionCount]; @@ -694,11 +764,13 @@ private function getFriendlyWorkingGroupName(array $groups) { } $group['WGApp'] = $appName; - //TODO - FOR DEMO PURPOSE THAT LEAVES OUT ADMIN GROUPS TO SHOW WHAT AVERAGE USER SEES -// if ($group['WGRole'] !== 'admins' && $group['WGRole'] !== 'owners') { -// $workingGroups[] = $group; -// } - $workingGroups[] = $group; + if ($method == 'member') { + if ($group['WGRole'] !== 'admins' && $group['WGRole'] !== 'owners') { + $workingGroups[] = $group; + } + } else { + $workingGroups[] = $group; + } unset($groups[$arrayIndex]); } } @@ -736,27 +808,6 @@ private function getFriendlyWorkingGroupName(array $groups) { return $finalWorkingGroups; } - private function getFriendlyEmailName(array $groups) { - - foreach($groups as &$group) { - $appCount = 0; - $appName = ''; - $stems = explode(':', $group['name']); - $sectionCount = count($stems) - 2; - $groupName = $stems[$sectionCount]; - $domain = $stems[2]; - if (strtolower($domain) == 'incommon') { - $address = $groupName . '@lists.incommon.org'; - } elseif (strtolower($domain) == 'internet2') { - $address = $groupName . '@lists.internet2.edu'; - } else { - $address = $groupName . '@lists.' . strtolower($domain) . '.org'; - } - $group['friendlyEmail'] = $address; - } - return $groups; - } - /** * Verify that the AdHoc groups are only coming from stems listed in $stemsAdHocAllowed * From 4a3e1fca9eb3828c1edc9e87c43385c66b857511 Mon Sep 17 00:00:00 2001 From: axman Date: Fri, 1 Oct 2021 11:50:05 -0700 Subject: [PATCH 2/5] ICPCO-168 --- Lib/GrouperApiAccess.php | 76 ++++++++++++++++++++++++++++++---------- Model/GrouperGroup.php | 4 +-- 2 files changed, 59 insertions(+), 21 deletions(-) diff --git a/Lib/GrouperApiAccess.php b/Lib/GrouperApiAccess.php index 091e994..00edecf 100644 --- a/Lib/GrouperApiAccess.php +++ b/Lib/GrouperApiAccess.php @@ -192,14 +192,27 @@ public function getOptionalGroups(array $queryData) { * */ public function getOwnedGroups(array $queryData) { - $queryData['groupType'] = 'Owner'; try { - $results = $this->useMembershipUrl($queryData); + $queryData['groupType'] = 'admin'; + $resultsAdmin = $this->useMembershipUrl($queryData); - if (isset($results['WsGetMembershipsResults']['wsGroups']) && $results['WsGetMembershipsResults']['wsGroups'] != NULL) { - return $results['WsGetMembershipsResults']['wsGroups']; + $queryData['groupType'] = 'update'; + $resultsUpdate = $this->useMembershipUrl($queryData); + + if (isset($resultsAdmin['WsGetMembershipsResults']['wsGroups']) && $resultsAdmin['WsGetMembershipsResults']['wsGroups'] != NULL) { + $admins = $resultsAdmin['WsGetMembershipsResults']['wsGroups']; + } else { + $admins = array(); } + + if (isset($resultsUpdate['WsGetMembershipsResults']['wsGroups']) && $resultsUpdate['WsGetMembershipsResults']['wsGroups'] != NULL) { + $updaters = $resultsUpdate['WsGetMembershipsResults']['wsGroups']; + } else { + $updaters = array(); + } + + return $this->removeDuplicates($admins, $updaters); } catch (Exception $e) { CakeLog::write('error', __METHOD__ . ': An error occurred'); throw $e; @@ -208,6 +221,40 @@ public function getOwnedGroups(array $queryData) { } + /** + * Currently not being used, but would be needed if Bill K does not want to show a group where + * the user is the admin and the updater. + * + * @param array $arrOne + * @param array $arrTwo + * @return array + */ + public function removeDuplicates(array $arrOne, array $arrTwo) { + + //Determine which array is bigger and use as base + $countOne = count($arrOne); + $countTwo = count($arrTwo); + if($countOne >= $countTwo) { + $arrL = $arrOne; + $arrS = $arrTwo; + } else { + $arrL = $arrTwo; + $arrS = $arrOne; + } + + foreach ($arrL as $large) { + foreach ($arrS as $key => $val) { + if ($large['uuid'] == $val['uuid']) { + unset($arrS[$key]); + } + } + } + + $results = array_merge_recursive($arrL, $arrS); + return $results; + } + + /** * Get members associated to a specific Grouper Group * @@ -255,7 +302,7 @@ public function getMembersInGroup(array $queryData) { * @throws GrouperLiteException */ public function getOwnedStems(array $queryData) { - $queryData['groupType'] = 'StemOwner'; + $queryData['groupType'] = 'stemAdmin'; try { $results = $this->useMembershipUrl($queryData); @@ -286,28 +333,20 @@ private function useMembershipUrl(array $queryData) { $groupType = $queryData['groupType']; $userId = $queryData['userId']; - if ($groupType == 'Optins') { - $fieldName = "optins"; + if ($groupType == 'optins' || $groupType == 'optouts') { $subjectId = "GrouperAll"; - } elseif ($groupType == 'Optouts') { - $fieldName = "optouts"; - $subjectId = "GrouperAll"; - } elseif ($groupType == 'Owner') { - $fieldName = "admin"; - $subjectId = $userId; - } elseif ($groupType == 'StemOwner') { - $fieldName = "stemAdmin"; + } elseif ($groupType == 'admin' || $groupType == 'update' || $groupType == 'stemAdmin') { $subjectId = $userId; } else { CakeLog::write('error', __METHOD__ . ": Option of $groupType is not supported"); throw new GrouperLiteException("Option of $groupType is not supported"); } - if ($groupType == 'Optins' || $groupType == 'Optouts') { + if ($groupType == 'optins' || $groupType == 'optouts') { //Build request logic, 2 subjectId's, second is for when user in "Secret" Optin/Optout Group $groupsToShow = array( "WsRestGetMembershipsRequest" => array( - "fieldName" => $fieldName, + "fieldName" => $groupType, "wsSubjectLookups" => array( array("subjectId" => $subjectId), array("subjectId" => $userId) @@ -318,7 +357,7 @@ private function useMembershipUrl(array $queryData) { //Build request logic $groupsToShow = array( "WsRestGetMembershipsRequest" => array( - "fieldName" => $fieldName, + "fieldName" => $groupType, "wsSubjectLookups" => array( array("subjectId" => $subjectId) ) @@ -326,7 +365,6 @@ private function useMembershipUrl(array $queryData) { ); } - $this->http->setHeader(array('Content-Type' => 'application/json', 'Accept' => 'application/json')); $connectionUrl = "{$this->config['fullUrl']}/memberships"; diff --git a/Model/GrouperGroup.php b/Model/GrouperGroup.php index 86f5e41..52bd180 100644 --- a/Model/GrouperGroup.php +++ b/Model/GrouperGroup.php @@ -163,7 +163,7 @@ public function filteredMemberOfGroups(array $conditions) { $this->initApi(); try { - $conditions['groupType'] = 'Optouts'; + $conditions['groupType'] = 'optouts'; $memberOfGroups = $this->memberOfGroups($conditions); // Determine which groups can be left by user, if want. @@ -383,7 +383,7 @@ public function optinGroups(array $conditions) { $this->initApi(); try { - $conditions['groupType'] = 'Optins'; + $conditions['groupType'] = 'optins'; $joinOrLeave = $this->grouperAPI->getOptionalGroups($conditions); $userGroups = $this->memberOfGroups($conditions); From d3fe3fb987b157bd95c16266dd9f6603b8bd522b Mon Sep 17 00:00:00 2001 From: axman Date: Fri, 8 Oct 2021 10:31:24 -0700 Subject: [PATCH 3/5] fixes for ICPCO-169,170 and 172 --- Controller/GrouperGroupsController.php | 78 +++++++------------------ Lib/GrouperApiAccess.php | 43 ++++++++++++++ Lib/GrouperHTTPWrapper.php | 3 +- Model/GrouperGroup.php | 9 ++- View/CoGrouperLites/display.ctp | 4 +- View/GrouperGroups/emaillistsmanage.ctp | 11 +--- View/GrouperGroups/emaillistsmember.ctp | 12 +--- View/GrouperGroups/emaillistsoptin.ctp | 11 +--- 8 files changed, 86 insertions(+), 85 deletions(-) diff --git a/Controller/GrouperGroupsController.php b/Controller/GrouperGroupsController.php index c02afac..e9baa80 100644 --- a/Controller/GrouperGroupsController.php +++ b/Controller/GrouperGroupsController.php @@ -107,66 +107,32 @@ public function index() { ); } - /** - * Display of Grouper Group Information, such as Group Properties, Members and Attributes - * - */ - public function groupInfo() { - $name = urldecode($this->request->query['groupname']); - - $this->set('title', _txt('pl.grouperlite.title.groupinfo')); - - try { - $details = $this->GrouperGroup->groupDescriptions($name); - $this->set('groupergroupsdetail', $details[0]); - - } catch (Exception $e) { - CakeLog::write('error', __METHOD__ . ': ' . var_export($e->getMessage(), true)); - - $this->set('groupergroupsdetail', array()); - $this->Flash->set(_txt('pl.grouperlite.message.flash.info-group-failed'), array('key' => 'error')); - } - - try { - $groupMembers = $this->membersInGroup(); - $this->set('groupergroupssubscribers', $groupMembers); - } catch (Exception $e) { - CakeLog::write('error', __METHOD__ . ': ' . var_export($e->getMessage(), true)); - - $this->set('groupergroupssubscribers', array()); - $this->Flash->set(_txt('pl.grouperlite.message.flash.group-detail-members-failed'), array('key' => 'error')); - } - - $this->set('isuserowner', $this->GrouperGroup->isUserOwner($this->userId)); - $this->set('grouperbaseurl', $this->Session->read('Plugin.Grouper.Api.grouperUrl')); - } - /** * Show all members of group in Grouper Group detail page * Called from method GroupInfo * */ - public function membersInGroup() { - $groupName = urldecode($this->request->query['groupname']); - - //Set initial - $scope = [ - 'groupName' => $groupName - ]; - - $details = []; - - try { - $details = $this->GrouperGroup->membersInGroup($scope); - - } catch (Exception $e) { - CakeLog::write('error', __METHOD__ . ': ' . var_export($e->getMessage(), true)); - - $this->Flash->set(_txt('pl.grouperlite.message.flash.group-detail-members-failed'), array('key' => 'error')); - } - - return $details; - } +// public function membersInGroup() { +// $groupName = urldecode($this->request->query['groupname']); +// +// //Set initial +// $scope = [ +// 'groupName' => $groupName +// ]; +// +// $details = []; +// +// try { +// $details = $this->GrouperGroup->membersInGroup($scope, $this->userId); +// +// } catch (Exception $e) { +// CakeLog::write('error', __METHOD__ . ': ' . var_export($e->getMessage(), true)); +// +// $this->Flash->set(_txt('pl.grouperlite.message.flash.group-detail-members-failed'), array('key' => 'error')); +// } +// +// return $details; +// } /** * Show all members of group in Grouper Group detail page @@ -193,7 +159,7 @@ public function groupSubscribers() { ]; try { - $subscribers = $this->GrouperGroup->membersInGroup($scope); + $subscribers = $this->GrouperGroup->membersInGroup($scope, $this->userId); } catch (Exception $e) { CakeLog::write('error', __METHOD__ . ': ' . var_export($e->getMessage(), true)); diff --git a/Lib/GrouperApiAccess.php b/Lib/GrouperApiAccess.php index 00edecf..33466a6 100644 --- a/Lib/GrouperApiAccess.php +++ b/Lib/GrouperApiAccess.php @@ -264,6 +264,16 @@ public function removeDuplicates(array $arrOne, array $arrTwo) { */ public function getMembersInGroup(array $queryData) { + // First verify that user has read access to group + if ($this->verifyPrivileges($queryData, 'read') === false) { + return array( + array( + "sourceId" => "ldap", + "name" => "You do not have access to memberships" + ) + ); + } + //Build request logic $usersToShow = array( "WsRestGetMembersRequest" => array( @@ -294,6 +304,39 @@ public function getMembersInGroup(array $queryData) { return array(); } + public function verifyPrivileges(array $queryData, string $privilege) { + //Build request logic + $verifyPrivs = array( + "WsRestGetGrouperPrivilegesLiteRequest" => array( + "privilegeName" => $privilege, + "groupName" => $queryData['groupName'], + "subjectId" => $queryData['userId'] + ) + ); + + $this->http->setHeader(array('Content-Type' => 'application/json', 'Accept' => 'application/json')); + $connectionUrl = "{$this->config['fullUrl']}/grouperPrivileges"; + + try { + $results = $this->http->sendRequest('POST', $connectionUrl, json_encode($verifyPrivs)); + + // Parse out relevant records to send front end + if (isset($results['WsGetGrouperPrivilegesLiteResult']['resultMetadata']['resultCode']) && $results['WsGetGrouperPrivilegesLiteResult']['resultMetadata']['resultCode'] != NULL) { + if ($results['WsGetGrouperPrivilegesLiteResult']['resultMetadata']['resultCode'] == 'SUCCESS_ALLOWED') { + return true; + } else { + return false; + } + } + } catch (Exception $e) { + CakeLog::write('error', __METHOD__ . ': An error occurred'); + throw $e; + } + + return array(); + + } + /** * Gets all Stems/Folders where User is admin/owner * diff --git a/Lib/GrouperHTTPWrapper.php b/Lib/GrouperHTTPWrapper.php index 625d96c..3439d50 100644 --- a/Lib/GrouperHTTPWrapper.php +++ b/Lib/GrouperHTTPWrapper.php @@ -137,7 +137,8 @@ private function _verifyResults(HttpSocketResponse $apiResults): array { $mainKey = key($resBody); $apiSuccess = $resBody[$mainKey]['resultMetadata']['resultCode']; - if ($apiSuccess != 'SUCCESS') { + // Had to add SUCCESS_NOT_ALLOWED and SUCCESS_ALLOWED for checking privs on a group for a user + if ($apiSuccess != 'SUCCESS' && $apiSuccess != 'SUCCESS_NOT_ALLOWED' && $apiSuccess != 'SUCCESS_ALLOWED') { CakeLog::write('error', __METHOD__ . ': Result Code was ' . var_export($apiSuccess, true)); CakeLog::write('error', __METHOD__ . ': Error of ' . var_export($apiResults->body(), true)); throw new GrouperLiteException('Result from Grouper WS was' . var_export($apiSuccess, true)); diff --git a/Model/GrouperGroup.php b/Model/GrouperGroup.php index 52bd180..f566cd7 100644 --- a/Model/GrouperGroup.php +++ b/Model/GrouperGroup.php @@ -315,16 +315,23 @@ public function ownerGroups(array $conditions) { * members * * @param array $conditions Listing of conditions for display of records + * @param string $userId Id of User * @return array Listing of members in requested Grouper Group * @throws GrouperLiteException Captured in Controller * */ - public function membersInGroup(array $conditions) { + public function membersInGroup(array $conditions, string $userId) { $this->initApi(); + $conditions['userId'] = $userId; + try { $groupMembers = $this->grouperAPI->getMembersInGroup($conditions); + if (count($groupMembers) < 1){ + return $groupMembers; + } + $finalMembers = array(); foreach ($groupMembers as $member) { if ($member['sourceId'] !== 'g:gsa') { diff --git a/View/CoGrouperLites/display.ctp b/View/CoGrouperLites/display.ctp index c79eb73..f112905 100644 --- a/View/CoGrouperLites/display.ctp +++ b/View/CoGrouperLites/display.ctp @@ -94,7 +94,7 @@ echo $this->element('GrouperLite.base-styles'); array( 'plugin' => "grouper_lite", 'controller' => 'grouper_groups', - 'action' => 'emaillistsMember', + 'action' => 'emaillistsmember', 'co' => $coid, 'glid' => $glid ) @@ -117,7 +117,7 @@ echo $this->element('GrouperLite.base-styles'); array( 'plugin' => "grouper_lite", 'controller' => 'grouper_groups', - 'action' => 'emaillistsManage', + 'action' => 'emaillistsmanage', 'co' => $coid, 'glid' => $glid ) diff --git a/View/GrouperGroups/emaillistsmanage.ctp b/View/GrouperGroups/emaillistsmanage.ctp index 09793f6..7657544 100644 --- a/View/GrouperGroups/emaillistsmanage.ctp +++ b/View/GrouperGroups/emaillistsmanage.ctp @@ -17,14 +17,9 @@ - Html->link( - isset($group['name']) ? $group['domain'] . ':' . $group['name'] : "--", - array( - 'controller' => 'grouper_groups', - 'action' => 'emaillistinfo', - '?' => array('groupname' => urlencode($group['name'])) - ) - ) ?> + + + (10) | diff --git a/View/GrouperGroups/emaillistsmember.ctp b/View/GrouperGroups/emaillistsmember.ctp index d6952ec..c26d517 100644 --- a/View/GrouperGroups/emaillistsmember.ctp +++ b/View/GrouperGroups/emaillistsmember.ctp @@ -16,15 +16,9 @@ $group) : ?> - Html->link( - - $group['friendlyEmail'] ?? "No Name", - array( - 'controller' => 'grouper_groups', - 'action' => 'emaillistinfo', - '?' => array('groupname' => urlencode($group['name'])) - ) - ) ?> + + + element('GrouperLite.Components/optAction', array( diff --git a/View/GrouperGroups/emaillistsoptin.ctp b/View/GrouperGroups/emaillistsoptin.ctp index bfb2399..391109c 100644 --- a/View/GrouperGroups/emaillistsoptin.ctp +++ b/View/GrouperGroups/emaillistsoptin.ctp @@ -15,14 +15,9 @@ - Html->link( - $group['friendlyEmail'] ?? "No Name", - array( - 'controller' => 'grouper_groups', - 'action' => 'emaillistinfo', - '?' => array('groupname' => urlencode($group['name'])) - ) - ) ?> + + +