public function sort(array $sorting)
    {
        foreach ($sorting as $key => $value) {
            $column = isset($this->sortMapping[$key])
                ? $this->sortMapping[$key]
                : current($this->qb->getRootAliases()) . '.' . $key;

            $this->qb->addOrderBy($column, $value);
        }
    }
public function sort(array $sorting)
    {
        foreach ($sorting as $key => $value) {
            $column = isset($this->sortMapping[$key])
                ? $this->sortMapping[$key]
                : current($this->qb->getRootAliases()) . '.' . $key;

            $this->qb->addOrderBy($column, $value);
        }
    }
public function sort ( array $ sorting ) { foreach ( $ sorting as $ key => $ value ) { $ column = isset ( $ this -> sortMapping [ $ key ] ) ? $ this -> sortMapping [ $ key ] : current ( $ this -> qb -> getRootAliases ( ) ) . '.' . $ key ; $ this -> qb -> addOrderBy ( $ column , $ value ) ; } }
Sets sorting.
@param array $sorting
Sets sorting .