Commit 20c4fca5 authored by Jonny Bradley's avatar Jonny Bradley

[FIX] search: Add sort mode handling to object organizer

parent 57cdae74
......@@ -8,6 +8,7 @@
$inputConfiguration = array(array(
'staticKeyFiltersForArrays' => array(
'filter' => 'text',
'sort_mode' => 'text',
),
'catchAllUnset' => null,
));
......@@ -69,6 +70,9 @@ $smarty->assign('filter', $filter);
if (count($filter)) {
$unifiedsearchlib = TikiLib::lib('unifiedsearch');
$query = $unifiedsearchlib->buildQuery($filter);
if (isset($_REQUEST['sort_mode']) && $order = Search_Query_Order::parse($_REQUEST['sort_mode'])) {
$query->setOrder($order);
}
$result = $query->search($unifiedsearchlib->getIndex());
$smarty->assign('result', $result);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment