mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-23 00:13:35 +01:00
Fix column sorting
This commit is contained in:
parent
3ff03ca92f
commit
3b73d9bb3d
@ -142,9 +142,12 @@ class etemplate_widget_nextmatch extends etemplate_widget
|
||||
$value = array_merge($value, $filters);
|
||||
$result = array('rows' => array());
|
||||
|
||||
// Parse sort into something that get_rows functions are expecting: db_field ASC/DESC
|
||||
// Parse sort into something that get_rows functions are expecting: db_field in order, ASC/DESC in sort
|
||||
if(is_array($value['sort']))
|
||||
$value['sort'] = $value['sort']['id'] . ' ' . $value['sort']['asc'] ? 'ASC' : 'DESC';
|
||||
{
|
||||
$value['order'] = $value['sort']['id'];
|
||||
$value['sort'] = ($value['sort']['asc'] ? 'ASC' : 'DESC');
|
||||
}
|
||||
|
||||
foreach ($fetchList as $entry)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user