diff options
author | Meik Sievertsen <acydburn@phpbb.com> | 2007-04-27 16:13:03 +0000 |
---|---|---|
committer | Meik Sievertsen <acydburn@phpbb.com> | 2007-04-27 16:13:03 +0000 |
commit | f5e0f060cd50cf3099d6e5cc12d8b390ed3b57ce (patch) | |
tree | 97a7c72b974d13fc5ecf4066eac9fa0096027607 /phpBB/includes/ucp/ucp_pm_viewfolder.php | |
parent | 266797fddf049d89923d9885cfecd022d9875fb3 (diff) | |
download | forums-f5e0f060cd50cf3099d6e5cc12d8b390ed3b57ce.tar forums-f5e0f060cd50cf3099d6e5cc12d8b390ed3b57ce.tar.gz forums-f5e0f060cd50cf3099d6e5cc12d8b390ed3b57ce.tar.bz2 forums-f5e0f060cd50cf3099d6e5cc12d8b390ed3b57ce.tar.xz forums-f5e0f060cd50cf3099d6e5cc12d8b390ed3b57ce.zip |
fixing...
git-svn-id: file:///svn/phpbb/trunk@7412 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/ucp/ucp_pm_viewfolder.php')
-rw-r--r-- | phpBB/includes/ucp/ucp_pm_viewfolder.php | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/phpBB/includes/ucp/ucp_pm_viewfolder.php b/phpBB/includes/ucp/ucp_pm_viewfolder.php index 14bc5afab9..e5fa2903fd 100644 --- a/phpBB/includes/ucp/ucp_pm_viewfolder.php +++ b/phpBB/includes/ucp/ucp_pm_viewfolder.php @@ -442,8 +442,18 @@ function get_pm_from($folder_id, $folder, $user_id) // PM ordering options $limit_days = array(0 => $user->lang['ALL_MESSAGES'], 1 => $user->lang['1_DAY'], 7 => $user->lang['7_DAYS'], 14 => $user->lang['2_WEEKS'], 30 => $user->lang['1_MONTH'], 90 => $user->lang['3_MONTHS'], 180 => $user->lang['6_MONTHS'], 365 => $user->lang['1_YEAR']); - $sort_by_text = array('a' => $user->lang['AUTHOR'], 't' => $user->lang['POST_TIME'], 's' => $user->lang['SUBJECT']); - $sort_by_sql = array('a' => 'u.username_clean', 't' => 'p.message_time', 's' => 'p.message_subject'); + + // No sort by Author for sentbox/outbox (already only author available) + if ($folder_id == PRIVMSGS_OUTBOX || $folder_id == PRIVMSGS_SENTBOX) + { + $sort_by_text = array('t' => $user->lang['POST_TIME'], 's' => $user->lang['SUBJECT']); + $sort_by_sql = array('t' => 'p.message_time', 's' => 'p.message_subject'); + } + else + { + $sort_by_text = array('a' => $user->lang['AUTHOR'], 't' => $user->lang['POST_TIME'], 's' => $user->lang['SUBJECT']); + $sort_by_sql = array('a' => 'u.username_clean', 't' => 'p.message_time', 's' => 'p.message_subject'); + } $s_limit_days = $s_sort_key = $s_sort_dir = $u_sort_param = ''; gen_sort_selects($limit_days, $sort_by_text, $sort_days, $sort_key, $sort_dir, $s_limit_days, $s_sort_key, $s_sort_dir, $u_sort_param); |