Beispiel #1
0
 /**
  * 
  * {@inheritDoc}
  */
 public function findSiteMembers($siteId, $types = UserType::ANY, $active = false, \DateTime $joinedAfter = null, \DateTime $joinedBefore = null, $order = null, $paginated = false)
 {
     $lastActive = null;
     if ($active) {
         $lastActive = $this->getActiveDate();
     }
     return $this->membershipMapper->findSiteMembers($siteId, $types, $lastActive, $joinedAfter, $joinedBefore, $order, $paginated);
 }
Beispiel #2
0
 /**     
  * {@inheritDoc}
  */
 public function getMemberships()
 {
     if (!isset($this->memberships)) {
         $this->memberships = $this->membershipMapper->findUserMemberships($this->getId());
         $this->memberships = iterator_to_array($this->memberships);
         foreach ($this->memberships as $membership) {
             $this->membershipsBySite[$membership->getSiteId()] = $membership;
         }
     }
     return $this->memberships;
 }