예제 #1
0
파일: DateEquals.php 프로젝트: pr-of-it/t4
 public function modifyQuery(Query $query) : Query
 {
     if ('' === $this->value || null === $this->value) {
         return $query;
     }
     if (empty($query->where)) {
         $query->where('TRUE');
     }
     $query->where($query->where . ' AND CAST(' . $this->name . ' AS DATE) = :' . $this->name)->param(':' . $this->name, $this->value);
     return $query;
 }
예제 #2
0
파일: Contains.php 프로젝트: pr-of-it/t4
 public function modifyQuery(Query $query) : Query
 {
     if ('' === $this->value || null === $this->value) {
         return $query;
     }
     if (empty($query->where)) {
         $query->where('TRUE');
     }
     $query->where($query->where . ' AND ' . $this->name . ' LIKE ' . $this->getConnection()->quote('%' . $this->value . '%'));
     return $query;
 }