Преглед изворни кода

CSV import: added a flag to disable the history tab (too long to display, when the feature is heavily used)

git-svn-id: http://svn.code.sf.net/p/itop/code/trunk@2263 a333f486-631f-4898-b8df-5754b55c2be0
romainq пре 12 година
родитељ
комит
9532a67f29
2 измењених фајлова са 12 додато и 0 уклоњено
  1. 8 0
      core/config.class.inc.php
  2. 4 0
      pages/csvimport.php

+ 8 - 0
core/config.class.inc.php

@@ -205,6 +205,14 @@ class Config
 			'source_of_value' => '',
 			'show_in_conf_sample' => false,
 		),
+		'csv_import_history_display' => array(
+			'type' => 'bool',
+			'description' => 'Display the history tab in the import wizard',
+			'default' => true,
+			'value' => true,
+			'source_of_value' => '',
+			'show_in_conf_sample' => false,
+		),
 		'access_mode' => array(
 			'type' => 'integer',
 			'description' => 'Combination of flags (ACCESS_USER_WRITE | ACCESS_ADMIN_WRITE, or ACCESS_FULL)',

+ 4 - 0
pages/csvimport.php

@@ -1462,14 +1462,18 @@ $('#select_template_class').change( function() {
 EOF
 	);
 
+		if (Utils::GetConfig()->Get('csv_import_history_display'))
+		{
 		$oPage->SetCurrentTabContainer('tabs1');
 		$oPage->SetCurrentTab(Dict::S('UI:History:BulkImports'));
 		BulkChange::DisplayImportHistory($oPage);
+		}
 	}
 			
 	switch($iStep)
 	{
 		case 10:
+			// Case generated by BulkChange::DisplayImportHistory
 			$iChange = (int)utils::ReadParam('changeid', 0);
 			BulkChange::DisplayImportHistoryDetails($oPage, $iChange);
 			break;