root/dev/common/admin/option_db.php @ 190

Revision 190, 0.9 KB (checked in by exi, 15 years ago)

This is a big update...
Moved all admin scripts to common/admin.
Moved all includes and classes to common/includes.
Edited all include-paths to reflect the movement.
Fixed a bug with the session system allowing every registered user to access admin pages.
Replaced calls to date() to use a wrapper so gmdate can be used.
Replaced some calls to $config with calls to the static object.
Fixed a big which caused the portrait_grab to not download a new picute.
Added a classified-state to kills.
Removed the sync_server server script in this tree.
Added code to help modules find the includes to index.php.

Line 
1<?php
2options::cat('Maintenance', 'Database', 'Table checks');
3options::fadd('This checks automatically your database', 'none', 'custom', array('admin_db', 'checkDatabase'), array('admin_db', 'none'));
4
5class admin_db
6{
7    function checkDatabase()
8    {
9        require_once('common/includes/autoupgrade.php');
10
11        // todo: write functions to take care of this
12        // based on a database description file
13        check_pilots();
14        check_invdetail();
15        check_contracts();
16        check_index();
17        check_tblstrct1();
18        check_tblstrct2();
19        check_tblstrct3();
20        check_tblstrct4();
21        check_tblstrct5();
22        chk_kb3_items();
23        chk_kb3_items2();
24        check_tblstrct6();
25
26        return 'Maintenance complete.<br/>';
27    }
28
29    function none()
30    {
31        // do nothing on submit
32    }
33}
34?>
Note: See TracBrowser for help on using the browser.