소스 검색

Removed duplicate titles from the moderation center

Signed-off-by: emanuele <[email protected]>
emanuele 11 년 전
부모
커밋
651820084e
5개의 변경된 파일22개의 추가작업 그리고 36개의 파일을 삭제
  1. 3 1
      Sources/Groups.php
  2. 5 0
      Sources/ModerationCenter.php
  3. 6 7
      Sources/Modlog.php
  4. 8 1
      Sources/PostModeration.php
  5. 0 27
      Themes/default/ModerationCenter.template.php

+ 3 - 1
Sources/Groups.php

@@ -625,7 +625,6 @@ function GroupRequests()
 	// This is all the information required for a group listing.
 	$listOptions = array(
 		'id' => 'group_request_list',
-		'title' => $txt['mc_group_requests'],
 		'width' => '100%',
 		'items_per_page' => $modSettings['defaultMaxMessages'],
 		'no_items_label' => $txt['mc_groupr_none_found'],
@@ -735,6 +734,9 @@ function GroupRequests()
 	createList($listOptions);
 
 	$context['default_list'] = 'group_request_list';
+	$context[$context['moderation_menu_name']]['tab_data'] = array(
+		'title' => $txt['mc_group_requests'],
+	);
 }
 
 /**

+ 5 - 0
Sources/ModerationCenter.php

@@ -2059,6 +2059,11 @@ function ModerationSettings()
 	loadTemplate('ModerationCenter');
 	$context['page_title'] = $txt['mc_settings'];
 	$context['sub_template'] = 'moderation_settings';
+	$context[$context['moderation_menu_name']]['tab_data'] = array(
+		'title' => $txt['mc_prefs_title'],
+		'help' => '',
+		'description' => $txt['mc_prefs_desc']
+	);
 
 	// What blocks can this user see?
 	$context['homepage_blocks'] = array(

+ 6 - 7
Sources/Modlog.php

@@ -156,7 +156,6 @@ function ViewModlog()
 	// This is all the information required for a watched user listing.
 	$listOptions = array(
 		'id' => 'moderation_log_list',
-		'title' => '<a href="' . $scripturl . '?action=helpadmin;help=' . ($context['log_type'] == 3 ? 'adminlog' : 'modlog') . '" onclick="return reqOverlayDiv(this.href);" class="help"><img src="' . $settings['images_url'] . '/helptopics.png" alt="' . $txt['help'] . '" /></a> ' . $txt['modlog_' . ($context['log_type'] == 3 ? 'admin' : 'moderation') . '_log'],
 		'width' => '100%',
 		'items_per_page' => $context['displaypage'],
 		'no_items_label' => $txt['modlog_' . ($context['log_type'] == 3 ? 'admin_log_' : '') . 'no_entries_found'],
@@ -274,12 +273,6 @@ function ViewModlog()
 			'token' => 'mod-ml',
 		),
 		'additional_rows' => array(
-			array(
-				'position' => 'after_title',
-				'value' => $txt['modlog_' . ($context['log_type'] == 3 ? 'admin' : 'moderation') . '_log_desc'],
-
-				'style' => 'padding: 1ex 2ex;',
-			),
 			array(
 				'position' => 'below_table_data',
 				'value' => '
@@ -301,6 +294,12 @@ function ViewModlog()
 
 	$context['sub_template'] = 'show_list';
 	$context['default_list'] = 'moderation_log_list';
+
+	$context[$context['moderation_menu_name']]['tab_data'] = array(
+		'title' => $txt['modlog_' . ($context['log_type'] == 3 ? 'admin' : 'moderation') . '_log'],
+		'help' => $context['log_type'] == 3 ? 'adminlog' : 'modlog',
+		'description' => $txt['modlog_' . ($context['log_type'] == 3 ? 'admin' : 'moderation') . '_log_desc']
+	);
 }
 
 /**

+ 8 - 1
Sources/PostModeration.php

@@ -517,7 +517,14 @@ function UnapprovedAttachments()
 	createToken('mod-ap');
 	createList($listOptions);
 
-	$context['sub_template'] = 'unapproved_attachments';
+	$context['sub_template'] = 'show_list';
+	$context['default_list'] = 'mc_unapproved_attach';
+
+	$context[$context['moderation_menu_name']]['tab_data'] = array(
+		'title' => $txt['mc_unapproved_attachments'],
+		'help' => '',
+		'description' => $txt['mc_unapproved_attachments_desc']
+	);
 }
 
 /**

+ 0 - 27
Themes/default/ModerationCenter.template.php

@@ -389,27 +389,6 @@ function template_unapproved_posts()
 	</div>';
 }
 
-// List all attachments awaiting approval.
-function template_unapproved_attachments()
-{
-	global $settings, $options, $context, $txt, $scripturl;
-
-	// Show all the attachments still oustanding.
-	echo '
-	<div id="modcenter">
-		<div class="cat_bar">
-			<h3 class="catbg">', $txt['mc_unapproved_attachments'], '</h3>
-		</div>
-		<div class="information">
-			', $txt['mc_unapproved_attachments_desc'], '
-		</div>';
-
-	template_show_list('mc_unapproved_attach');
-
-	echo '
-	</div>';
-}
-
 function template_viewmodreport()
 {
 	global $context, $scripturl, $txt;
@@ -537,12 +516,6 @@ function template_moderation_settings()
 	echo '
 	<div id="modcenter">
 		<form action="', $scripturl, '?action=moderate;area=settings" method="post" accept-charset="', $context['character_set'], '">
-			<div class="cat_bar">
-				<h3 class="catbg">', $txt['mc_prefs_title'], '</h3>
-			</div>
-			<div class="information">
-				', $txt['mc_prefs_desc'], '
-			</div>
 			<div class="windowbg2">
 				<div class="content">
 					<dl class="settings">