Compare commits
2 Commits
47953a6165
...
27d5fd0b08
Author | SHA1 | Date | |
---|---|---|---|
|
27d5fd0b08 | ||
|
5d00a7e394 |
@ -217,18 +217,6 @@ class QueryBuilder
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function groupBy(string $field, ? string $direction = null) : self
|
||||
{
|
||||
if ( null === $groupBy = $this->getFragment(Query\GroupBy::class) ) {
|
||||
$groupBy = new Query\GroupBy();
|
||||
$this->push($groupBy);
|
||||
}
|
||||
|
||||
$groupBy->add($field, $direction);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function limit(int $value) : self
|
||||
{
|
||||
if ( null === $limit = $this->getFragment(Query\Limit::class) ) {
|
||||
@ -265,6 +253,18 @@ class QueryBuilder
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function groupBy(string $field, ? string $direction = null) : self
|
||||
{
|
||||
if ( null === $groupBy = $this->getFragment(Query\GroupBy::class) ) {
|
||||
$groupBy = new Query\GroupBy();
|
||||
$this->push($groupBy);
|
||||
}
|
||||
|
||||
$groupBy->add($field, $direction);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function join(string $type, /*string | QueryBuilder*/ $table, $field, $value, bool $outer = false, ? string $alias = null) : self
|
||||
{
|
||||
$this->withJoin(...func_get_args());
|
||||
|
Loading…
x
Reference in New Issue
Block a user