Example #1
0
 /**
  * Sets the group by fields for the query.
  *
  * @param string|array $fields
  * @param string       $direction
  *
  * @return self
  */
 public function groupBy($fields, $direction = false)
 {
     $this->groupBy->addFields($fields, $direction);
     return $this;
 }
Example #2
0
 /**
  * Sets the order for the query.
  *
  * @param string|array $fields
  * @param string       $direction
  *
  * @return self
  */
 public function orderBy($fields, $direction = false)
 {
     $this->orderBy->addFields($fields, $direction);
     return $this;
 }