protected sortModels ( array $models, |
||
$models | array | the models to be sorted |
$sort | the sort definition | |
return | array | the sorted data models |
protected function sortModels($models, $sort)
{
$orders = $sort->getOrders();
if (!empty($orders)) {
ArrayHelper::multisort($models, array_keys($orders), array_values($orders));
}
return $models;
}