Пример #1
0
 private function getUserByIdentifier()
 {
     $mapper = $this->getMapper();
     if (empty($this->constraints)) {
         $user = $mapper::findOne(Filter::set($this->getIdentifierField(), Filter::EQUAL, $this->getIdentifierValue()));
     } else {
         $user = $mapper::findOne(Group::set(Filter::set($this->getIdentifierField(), Filter::EQUAL, $this->getIdentifierValue()), Group::OPERATOR_AND, $this->constraints));
     }
     return $user;
 }
Пример #2
0
 public static function getGroup(FilterInterface $firstCondition, $operator, FilterInterface $secondCondition)
 {
     return Group::set($firstCondition, $operator, $secondCondition);
 }