Changeset 8413 for trunk/admin/batch_manager.php
- Timestamp:
- Dec 31, 2010, 4:06:36 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/admin/batch_manager.php
r8408 r8413 34 34 35 35 include_once(PHPWG_ROOT_PATH.'admin/include/functions.php'); 36 include_once(PHPWG_ROOT_PATH.'admin/include/tabsheet.class.php'); 36 37 37 38 // +-----------------------------------------------------------------------+ … … 269 270 270 271 // +-----------------------------------------------------------------------+ 272 // | Tabs | 273 // +-----------------------------------------------------------------------+ 274 275 $tabs = array( 276 array( 277 'code' => 'global', 278 'label' => l10n('global mode'), 279 ), 280 array( 281 'code' => 'unit', 282 'label' => l10n('unit mode'), 283 ), 284 ); 285 286 $tab_codes = array_map( 287 create_function('$a', 'return $a["code"];'), 288 $tabs 289 ); 290 291 if (isset($_GET['mode']) and in_array($_GET['mode'], $tab_codes)) 292 { 293 $page['tab'] = $_GET['mode']; 294 } 295 else 296 { 297 $page['tab'] = $tabs[0]['code']; 298 } 299 300 $tabsheet = new tabsheet(); 301 foreach ($tabs as $tab) 302 { 303 $tabsheet->add( 304 $tab['code'], 305 $tab['label'], 306 get_root_url().'admin.php?page='.$_GET['page'].'&mode='.$tab['code'] 307 ); 308 } 309 $tabsheet->select($page['tab']); 310 $tabsheet->assign(); 311 312 // +-----------------------------------------------------------------------+ 271 313 // | open specific mode | 272 314 // +-----------------------------------------------------------------------+ 273 315 274 $_GET['mode'] = !empty($_GET['mode']) ? $_GET['mode'] : 'global'; 275 276 switch ($_GET['mode']) 277 { 278 case 'global' : 279 { 280 include(dirname(__FILE__).'/batch_manager_global.php'); 281 break; 282 } 283 case 'unit' : 284 { 285 include(PHPWG_ROOT_PATH.'admin/element_set_unit.php'); 286 break; 287 } 288 } 316 include(PHPWG_ROOT_PATH.'admin/batch_manager_'.$page['tab'].'.php'); 289 317 ?>
Note: See TracChangeset
for help on using the changeset viewer.