Commit db0ca0eb by Scott

Make user navigation on PMs consistent

parent 9b1e7d63
...@@ -1513,6 +1513,7 @@ function qa_user_sub_navigation($handle, $selected, $ismyuser = false) ...@@ -1513,6 +1513,7 @@ function qa_user_sub_navigation($handle, $selected, $ismyuser = false)
/** /**
* Return the sub navigation structure for private message pages * Return the sub navigation structure for private message pages
* @deprecated 1.8.0 This menu is no longer used.
* @param null $selected * @param null $selected
* @return array * @return array
*/ */
......
...@@ -237,7 +237,7 @@ if (qa_opt('show_message_history')) { ...@@ -237,7 +237,7 @@ if (qa_opt('show_message_history')) {
$qa_content['message_list']['messages'][] = qa_message_html_fields($message, $options); $qa_content['message_list']['messages'][] = qa_message_html_fields($message, $options);
} }
$qa_content['navigation']['sub'] = qa_messages_sub_navigation(); $qa_content['navigation']['sub'] = qa_user_sub_navigation($fromhandle, 'messages', true);
} }
......
...@@ -75,6 +75,13 @@ $count = $numMessages['count']; ...@@ -75,6 +75,13 @@ $count = $numMessages['count'];
$qa_content = qa_content_prepare(); $qa_content = qa_content_prepare();
$qa_content['title'] = qa_lang_html($showOutbox ? 'misc/pm_outbox_title' : 'misc/pm_inbox_title'); $qa_content['title'] = qa_lang_html($showOutbox ? 'misc/pm_outbox_title' : 'misc/pm_inbox_title');
$qa_content['custom'] =
'<div style="text-align:center">' .
($showOutbox ? '<a href="' . qa_path_html('messages') . '">' . qa_lang_html('misc/inbox') . '</a>' : qa_lang_html('misc/inbox')) .
' - ' .
($showOutbox ? qa_lang_html('misc/outbox') : '<a href="' . qa_path_html('messages/sent') . '">' . qa_lang_html('misc/outbox') . '</a>') .
'</div>';
$qa_content['message_list'] = array( $qa_content['message_list'] = array(
'tags' => 'id="privatemessages"', 'tags' => 'id="privatemessages"',
'messages' => array(), 'messages' => array(),
...@@ -122,6 +129,6 @@ foreach ($userMessages as $message) { ...@@ -122,6 +129,6 @@ foreach ($userMessages as $message) {
$qa_content['page_links'] = qa_html_page_links(qa_request(), $start, $pagesize, $count, qa_opt('pages_prev_next')); $qa_content['page_links'] = qa_html_page_links(qa_request(), $start, $pagesize, $count, qa_opt('pages_prev_next'));
$qa_content['navigation']['sub'] = qa_messages_sub_navigation($showOutbox ? 'outbox' : 'inbox'); $qa_content['navigation']['sub'] = qa_user_sub_navigation($loginUserHandle, 'messages', true);
return $qa_content; return $qa_content;
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