|
From: Joas S. <nic...@ph...> - 2009-08-15 10:49:49
|
Author: nickvergessen
Date: Sat Aug 15 11:49:01 2009
New Revision: 9990
Log:
Fix Bug #49615 - Unapproved topic icon has incorrect forum (introduced in r9635 fixing #46865)
Authorised by: ToonArmy
Modified:
branches/phpBB-3_0_0/phpBB/includes/functions_display.php
Modified: branches/phpBB-3_0_0/phpBB/includes/functions_display.php
==============================================================================
*** branches/phpBB-3_0_0/phpBB/includes/functions_display.php (original)
--- branches/phpBB-3_0_0/phpBB/includes/functions_display.php Sat Aug 15 11:49:01 2009
***************
*** 155,161 ****
}
// Count the difference of real to public topics, so we can display an information to moderators
! $row['forum_topics_unapproved'] = ($auth->acl_get('m_approve', $forum_id)) ? $row['forum_topics_real'] - $row['forum_topics'] : 0;
$row['forum_topics'] = ($auth->acl_get('m_approve', $forum_id)) ? $row['forum_topics_real'] : $row['forum_topics'];
// Display active topics from this forum?
--- 155,161 ----
}
// Count the difference of real to public topics, so we can display an information to moderators
! $row['forum_id_unapproved_topics'] = ($auth->acl_get('m_approve', $forum_id) && ($row['forum_topics_real'] - $row['forum_topics'])) ? $forum_id : 0;
$row['forum_topics'] = ($auth->acl_get('m_approve', $forum_id)) ? $row['forum_topics_real'] : $row['forum_topics'];
// Display active topics from this forum?
***************
*** 214,220 ****
$subforums[$parent_id][$row['parent_id']]['children'][] = $forum_id;
}
! $forum_rows[$parent_id]['forum_topics_unapproved'] += $row['forum_topics_unapproved'];
$forum_rows[$parent_id]['forum_topics'] += $row['forum_topics'];
// Do not list redirects in LINK Forums as Posts.
--- 214,224 ----
$subforums[$parent_id][$row['parent_id']]['children'][] = $forum_id;
}
! if (!$forum_rows[$parent_id]['forum_id_unapproved_topics'] && $row['forum_id_unapproved_topics'])
! {
! $forum_rows[$parent_id]['forum_id_unapproved_topics'] = $forum_id;
! }
!
$forum_rows[$parent_id]['forum_topics'] += $row['forum_topics'];
// Do not list redirects in LINK Forums as Posts.
***************
*** 456,462 ****
'L_FORUM_FOLDER_ALT' => $folder_alt,
'L_MODERATOR_STR' => $l_moderator,
! 'U_UNAPPROVED_TOPICS' => ($row['forum_topics_unapproved'] > 0) ? append_sid("{$phpbb_root_path}mcp.$phpEx", 'i=queue&mode=unapproved_topics&f=' . $row['forum_id']) : '',
'U_VIEWFORUM' => $u_viewforum,
'U_LAST_POSTER' => get_username_string('profile', $row['forum_last_poster_id'], $row['forum_last_poster_name'], $row['forum_last_poster_colour']),
'U_LAST_POST' => $last_post_url)
--- 460,466 ----
'L_FORUM_FOLDER_ALT' => $folder_alt,
'L_MODERATOR_STR' => $l_moderator,
! 'U_UNAPPROVED_TOPICS' => ($row['forum_id_unapproved_topics']) ? append_sid("{$phpbb_root_path}mcp.$phpEx", 'i=queue&mode=unapproved_topics&f=' . $row['forum_id_unapproved_topics']) : '',
'U_VIEWFORUM' => $u_viewforum,
'U_LAST_POSTER' => get_username_string('profile', $row['forum_last_poster_id'], $row['forum_last_poster_name'], $row['forum_last_poster_colour']),
'U_LAST_POST' => $last_post_url)
|