src/Repository/AbstractRepository.php
public function orderBy(?string $name, string $type = self::ORDER_ASC): AbstractRepository
    {
        $this->sorter['name'] = $name;
        $this->sorter['type'] = $type;

        return $this;
    }
public function orderBy(?string $name, string $type = self::ORDER_ASC): AbstractRepository
    {
        $this->sorter['name'] = $name;
        $this->sorter['type'] = $type;

        return $this;
    }
public function orderBy ( ? string $ name , string $ type = self :: ORDER_ASC ) : AbstractRepository { $ this -> sorter [ 'name' ] = $ name ; $ this -> sorter [ 'type' ] = $ type ; return $ this ; }
Set list ordering.

@param string|null $name sorter name or null to disable
@param string      $type `asc` or `desc`

@return AbstractRepository self
Set list ordering .