feat: admin billing integration + migrate system (replaces clone)

Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/8940e39d-4aaa-4154-874b-74ab24d74da3

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2026-04-30 20:54:08 +00:00 committed by GitHub
parent 4db784a84a
commit 9d1999f374
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 506 additions and 5 deletions

View file

@ -151,6 +151,22 @@ function exec_ogp_module()
}
print_success(get_lang('game_home_added'));
$db->logger(get_lang('game_home_added')." ($server_name)");
// Record the server in the billing tables so it participates in the
// normal lifecycle (renewals, expiration, admin dashboard).
require_once('billing_integration.php');
admin_register_server_in_billing(
$db,
$web_user_id,
$home_cfg_id,
$rserver_id,
$server_name,
0, // max_players — set later via edit_home
$access_rights,
$ftp,
$new_home_id
);
$view->refresh("?m=user_games&amp;p=edit&amp;home_id=$new_home_id", 0);
}else{
print_failure(get_lang_f("failed_to_assign_home_to_user", $new_home_id, $web_user . " " . $db->getError()));