protected function applyOrderBy(array $data, $orderBy)
    {
        if (!empty($orderBy)) {
            ArrayHelper::multisort($data, array_keys($orderBy), array_values($orderBy));
        }

        return $data;
    }
protected function applyOrderBy(array $data, $orderBy)
    {
        if (!empty($orderBy)) {
            ArrayHelper::multisort($data, array_keys($orderBy), array_values($orderBy));
        }

        return $data;
    }
protected function applyOrderBy ( array $ data , $ orderBy ) { if ( ! empty ( $ orderBy ) ) { ArrayHelper :: multisort ( $ data , array_keys ( $ orderBy ) , array_values ( $ orderBy ) ) ; } return $ data ; }
Applies sort for given data.

@param array $data raw data
@param array|null $orderBy order by

@return array sorted data
Applies sort for given data .