diff options
| author | thomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2012-02-02 22:18:10 +0000 |
|---|---|---|
| committer | thomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2012-02-02 22:18:10 +0000 |
| commit | 4f19c51b60bfb40122ff577883c613741572b5d5 (patch) | |
| tree | 7223a68e6c57e49c42dc3aac7f13107668303496 /roundcubemail/program/steps/addressbook | |
| parent | db8183565ca9b5cb1e1b534efa94f77345781599 (diff) | |
Allow users to choose cols for contacts list sorting
git-svn-id: https://svn.roundcube.net/trunk@5850 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/steps/addressbook')
| -rw-r--r-- | roundcubemail/program/steps/addressbook/list.inc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/roundcubemail/program/steps/addressbook/list.inc b/roundcubemail/program/steps/addressbook/list.inc index 46651853c..de7149bce 100644 --- a/roundcubemail/program/steps/addressbook/list.inc +++ b/roundcubemail/program/steps/addressbook/list.inc @@ -5,7 +5,7 @@ | program/steps/addressbook/list.inc | | | | This file is part of the Roundcube Webmail client | - | Copyright (C) 2005-2007, The Roundcube Dev Team | + | Copyright (C) 2005-2012, The Roundcube Dev Team | | | | Licensed under the GNU General Public License version 3 or | | any later version with exceptions for skins & plugins. | @@ -34,6 +34,7 @@ if (!empty($_REQUEST['_search']) && isset($_SESSION['search'][$_REQUEST['_search $page = isset($_SESSION['page']) ? $_SESSION['page'] : 1; $_SESSION['page'] = $page; + $sort_col = $this->config->get('addressbook_sort_col', 'name'); // Get records from all sources foreach ($search as $s => $set) { @@ -49,7 +50,7 @@ if (!empty($_REQUEST['_search']) && isset($_SESSION['search'][$_REQUEST['_search while ($row = $result->next()) { $row['sourceid'] = $s; - $key = $row['name'] . ':' . $row['sourceid']; + $key = $row[$sort_col] . ':' . $row['sourceid']; $records[$key] = $row; } unset($result); |
