root/dev/common/admin/admin_menu.php @ 216

Revision 216, 2.2 KB (checked in by ralle030583, 15 years ago)

- new table kb3_navigation
- new Admin Section Navigation - Top Navigation
- removes customable top nav bar changes which came with last revs
- new tablestruct added to autoupgrade.php
- db_cache error when creating new table fixed

Line 
1<?php
2require_once('common/includes/class.options.php');
3
4// include all admin modules
5// this doesnt need to check for itself because its already loaded
6$dir = 'common/admin/';
7if (is_dir($dir))
8{
9    if ($dh = opendir($dir))
10    {
11        while (($file = readdir($dh)) !== false)
12        {
13            // only load auto-option files
14            if (strstr($file, 'option_') && substr($file, -4) == '.php')
15            {
16                require_once($dir.$file);
17            }
18        }
19        closedir($dh);
20    }
21}
22
23// load all auto-options from mods
24$mods_active = explode(',', config::get('mods_active'));
25$modOverrides = false;
26foreach ($mods_active as $mod)
27{
28    if (file_exists('mods/'.$mod.'/auto_settings.php'))
29    {
30        include('mods/'.$mod.'/auto_settings.php');
31    }
32}
33
34// overload the box object to force every admin page to use the new options menu
35class Box2 extends Box
36{
37    function generate()
38    {
39        return options::genAdminMenu();
40    }
41}
42
43$menubox = new Box2();
44
45options::oldMenu('Appearance', "Contracts", "?a=admin_cc&op=view&type=contract");
46options::oldMenu('Appearance', "Campaigns", "?a=admin_cc&op=view&type=campaign");
47options::oldMenu('Appearance', "Standings", "?a=admin_standings");
48options::oldMenu('Appearance', "Map Options", "?a=admin_mapoptions");
49
50options::oldMenu('Advanced', "Ship Values", "?a=admin_shp_val");
51options::oldMenu('Advanced', "Synchronization", "?a=admin_sync");
52options::oldMenu('Advanced', "Post Permissions", "?a=admin_postperm");
53
54options::oldMenu('Modules', "Mods", "?a=admin_mods");
55
56options::oldMenu('Maintenance', "Auditing", "?a=admin_audit");
57options::oldMenu('Maintenance', "Kill Import - files", "?a=admin_kill_import");
58options::oldMenu('Maintenance', "Kill Import - csv", "?a=admin_kill_import_csv");
59options::oldMenu('Maintenance', "Kill Export - files", "?a=admin_kill_export");
60options::oldMenu('Maintenance', "Kill Export - csv", "?a=admin_kill_export_search");
61options::oldMenu('Maintenance', "Logout", "?a=logout");
62
63options::oldMenu('User', 'Roles', '?a=admin_roles');
64#options::oldMenu('User', 'Titles', '?a=admin_titles');
65
66options::oldMenu('Navigation', "Top Navigation", "?a=admin_navmanager");
67?>
Note: See TracBrowser for help on using the browser.