fix: consolidate module schemas to db_version=1, fix billing admin undefined vars and prefix

Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/35af6b7c-2518-4105-b4d2-ba1f3fe754cd

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2026-05-02 19:41:22 +00:00 committed by GitHub
parent 95e3f40021
commit d8972fee16
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 284 additions and 344 deletions

View file

@ -25,24 +25,21 @@
// Module general information
$module_title = "Addons Manager";
$module_version = "1.2";
$db_version = 2;
$db_version = 1;
$module_required = TRUE;
$module_menus = array( array( 'subpage' => 'addons_manager', 'name'=>'Addons Manager', 'group'=>'admin' ) );
$install_queries = array();
$install_queries[0] = array(
"DROP TABLE IF EXISTS `".OGP_DB_PREFIX."addons`;",
"CREATE TABLE IF NOT EXISTS ".OGP_DB_PREFIX."addons
(addon_id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
name VARCHAR(80) NOT NULL,
url VARCHAR(200) NOT NULL,
path VARCHAR(80) NOT NULL,
addon_type VARCHAR(7) NOT NULL,
home_cfg_id VARCHAR(7) NOT NULL) ENGINE=MyISAM;");
$install_queries[1] = array(
"ALTER TABLE `".OGP_DB_PREFIX."addons` ADD `post_script` longtext NOT NULL;");
$install_queries[2] = array(
"ALTER TABLE `".OGP_DB_PREFIX."addons` ADD `group_id` int(11) NULL;");
?>
"CREATE TABLE IF NOT EXISTS `".OGP_DB_PREFIX."addons` (
`addon_id` INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
`name` VARCHAR(80) NOT NULL,
`url` VARCHAR(200) NOT NULL,
`path` VARCHAR(80) NOT NULL,
`addon_type` VARCHAR(7) NOT NULL,
`home_cfg_id` VARCHAR(7) NOT NULL,
`post_script` longtext NOT NULL,
`group_id` int(11) NULL
) ENGINE=MyISAM;"
);
?>