ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
class.ilDclTextRecordQueryObject.php
Go to the documentation of this file.
1<?php
2
10{
11 public function applyCustomSorting(ilDclBaseFieldModel $field, array $all_records_ids, $direction = 'asc')
12 {
13 $sort_array = array();
14 foreach ($all_records_ids as $id) {
16 $sort_array[$id] = $url_field->getSortingValue();
17 }
18 switch (strtolower($direction)) {
19 case 'asc':
20 asort($sort_array);
21 break;
22 case 'desc':
23 arsort($sort_array);
24 break;
25 }
26 return array_keys($sort_array);
27 }
28}
An exception for terminatinating execution or to throw for unit testing.
Class ilDclBaseFieldModel.
Class ilDclBaseRecordModel.
static getRecordFieldCache($record, $field)
Class ilDclRecordQueryObject.
Class ilDclTextRecordQueryObject.
applyCustomSorting(ilDclBaseFieldModel $field, array $all_records_ids, $direction='asc')
Apply custom sorting.
if(!array_key_exists('StateId', $_REQUEST)) $id