Add missing keys
This commit is contained in:
parent
2229586b58
commit
ca0fae7bdb
4 changed files with 27 additions and 2 deletions
|
@ -9,10 +9,17 @@ class CreateGeneralSettings extends SettingsMigration
|
||||||
{
|
{
|
||||||
// Get the user-set configuration values from the old table.
|
// Get the user-set configuration values from the old table.
|
||||||
$this->migrator->add('general.credits_display_name', ($this->getOldValue('SETTINGS::SYSTEM:CREDITS_DISPLAY_NAME') != null) ?: 'Credits');
|
$this->migrator->add('general.credits_display_name', ($this->getOldValue('SETTINGS::SYSTEM:CREDITS_DISPLAY_NAME') != null) ?: 'Credits');
|
||||||
$this->migrator->add('general.register_ip_check', ($this->getOldValue("SETTINGS::SYSTEM:REGISTER_IP_CHECK") != null) ?: true);
|
|
||||||
$this->migrator->add('general.initial_user_credits', ($this->getOldValue("SETTINGS::USER:INITIAL_CREDITS") != null) ?: 250);
|
$this->migrator->add('general.initial_user_credits', ($this->getOldValue("SETTINGS::USER:INITIAL_CREDITS") != null) ?: 250);
|
||||||
$this->migrator->add('general.initial_server_limit', ($this->getOldValue("SETTINGS::USER:INITIAL_SERVER_LIMIT") != null) ?: 1);
|
$this->migrator->add('general.initial_server_limit', ($this->getOldValue("SETTINGS::USER:INITIAL_SERVER_LIMIT") != null) ?: 1);
|
||||||
$this->migrator->add('general.main_site', "");
|
$this->migrator->add('general.recaptcha_site_key', ($this->getOldValue("SETTINGS::RECAPTCHA:SITE_KEY") != null) ?: env('RECAPTCHA_SITE_KEY', '6LeIxAcTAAAAAJcZVRqyHh71UMIEGNQ_MXjiZKhI'));
|
||||||
|
$this->migrator->add('general.recaptcha_secret_key', ($this->getOldValue("SETTINGS::RECAPTCHA:SECRET_KEY") != null) ?: env('RECAPTCHA_SECRET_KEY', '6LeIxAcTAAAAAGG-vFI1TnRWxMZNFuojJ4WifJWe'));
|
||||||
|
$this->migrator->add('general.recaptcha_enabled', ($this->getOldValue("SETTINGS::RECAPTCHA:ENABLED") != null) ?: true);
|
||||||
|
$this->migrator->add('general.phpmyadmin_url', ($this->getOldValue("SETTINGS::MISC:PHPMYADMIN:URL") != null) ?: env('PHPMYADMIN_URL', ''));
|
||||||
|
$this->migrator->add('general.alert_enabled', ($this->getOldValue("SETTINGS::SYSTEM:ALERT_ENABLED") != null) ?: false);
|
||||||
|
$this->migrator->add('general.alert_type', ($this->getOldValue("SETTINGS::SYSTEM:ALERT_TYPE") != null) ?: 'dark');
|
||||||
|
$this->migrator->add('general.alert_message', ($this->getOldValue("SETTINGS::SYSTEM:ALERT_MESSAGE") != null) ?: '');
|
||||||
|
$this->migrator->add('general.theme', ($this->getOldValue("SETTINGS::SYSTEM:THEME") != null) ?: 'default');
|
||||||
|
$this->migrator->add('general.main_site', '');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getOldValue(string $key)
|
public function getOldValue(string $key)
|
||||||
|
|
|
@ -18,6 +18,8 @@ class CreateUserSettings extends SettingsMigration
|
||||||
$this->migrator->add('user.server_limit_after_irl_purchase', ($this->getOldValue('SETTINGS::USER:SERVER_LIMIT_AFTER_IRL_PURCHASE') != null) ?: 10);
|
$this->migrator->add('user.server_limit_after_irl_purchase', ($this->getOldValue('SETTINGS::USER:SERVER_LIMIT_AFTER_IRL_PURCHASE') != null) ?: 10);
|
||||||
$this->migrator->add('user.server_limit_after_verify_discord', ($this->getOldValue('SETTINGS::USER:SERVER_LIMIT_REWARD_AFTER_VERIFY_DISCORD') != null) ?: 2);
|
$this->migrator->add('user.server_limit_after_verify_discord', ($this->getOldValue('SETTINGS::USER:SERVER_LIMIT_REWARD_AFTER_VERIFY_DISCORD') != null) ?: 2);
|
||||||
$this->migrator->add('user.server_limit_after_verify_email', ($this->getOldValue('SETTINGS::USER:SERVER_LIMIT_REWARD_AFTER_VERIFY_EMAIL') != null) ?: 2);
|
$this->migrator->add('user.server_limit_after_verify_email', ($this->getOldValue('SETTINGS::USER:SERVER_LIMIT_REWARD_AFTER_VERIFY_EMAIL') != null) ?: 2);
|
||||||
|
$this->migrator->add('user.register_ip_check', ($this->getOldValue("SETTINGS::SYSTEM:REGISTER_IP_CHECK") != null) ?: true);
|
||||||
|
$this->migrator->add('user.creation_enabled', ($this->getOldValue("SETTINGS::SYSTEM:CREATION_OF_NEW_USERS") != null) ?: true);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getOldValue(string $key)
|
public function getOldValue(string $key)
|
||||||
|
|
|
@ -9,6 +9,8 @@ class CreateServerSettings extends SettingsMigration
|
||||||
{
|
{
|
||||||
// Get the user-set configuration values from the old table.
|
// Get the user-set configuration values from the old table.
|
||||||
$this->migrator->add('server.allocation_limit', ($this->getOldValue('SETTINGS::SERVER:ALLOCATION_LIMIT') != null) ?: 200);
|
$this->migrator->add('server.allocation_limit', ($this->getOldValue('SETTINGS::SERVER:ALLOCATION_LIMIT') != null) ?: 200);
|
||||||
|
$this->migrator->add('server.creation_enabled', ($this->getOldValue('SETTINGS::SYSTEM:CREATION_OF_NEW_SERVERS') != null) ?: true);
|
||||||
|
$this->migrator->add('server.enable_upgrade', ($this->getOldValue('SETTINGS::SYSTEM:ENABLE_UPGRADE') != null) ?: false);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getOldValue(string $key)
|
public function getOldValue(string $key)
|
||||||
|
|
|
@ -9,6 +9,20 @@ class CreateWebsiteSettings extends SettingsMigration
|
||||||
{
|
{
|
||||||
// Get the user-set configuration values from the old table.
|
// Get the user-set configuration values from the old table.
|
||||||
$this->migrator->add('website.', ($this->getOldValue('SETTINGS::') != null) ?: '');
|
$this->migrator->add('website.', ($this->getOldValue('SETTINGS::') != null) ?: '');
|
||||||
|
$this->migrator->add('website.motd_enabled', ($this->getOldValue("SETTINGS::SYSTEM:MOTD_ENABLED") != null) ?: true);
|
||||||
|
$this->migrator->add('website.motd_message', ($this->getOldValue("SETTINGS::SYSTEM:MOTD_MESSAGE") != null) ?:
|
||||||
|
'<h1 style="text-align: center;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://controlpanel.gg/img/controlpanel.png" alt="" width="200" height="200"><span style="font-size: 36pt;">Controlpanel.gg</span></h1>
|
||||||
|
<p><span style="font-size: 18pt;">Thank you for using our Software</span></p>
|
||||||
|
<p><span style="font-size: 18pt;">If you have any questions, make sure to join our <a href="https://discord.com/invite/4Y6HjD2uyU" target="_blank" rel="noopener">Discord</a></span></p>
|
||||||
|
<p><span style="font-size: 10pt;">(you can change this message in the <a href="admin/settings#system">Settings</a> )</span></p>'
|
||||||
|
);
|
||||||
|
$this->migrator->add('website.show_imprint', ($this->getOldValue("SETTINGS::SYSTEM:SHOW_IMPRINT") != null) ?: false);
|
||||||
|
$this->migrator->add('website.show_privacy', ($this->getOldValue("SETTINGS::SYSTEM:SHOW_PRIVACY") != null) ?: false);
|
||||||
|
$this->migrator->add('website.show_tos', ($this->getOldValue("SETTINGS::SYSTEM:SHOW_TOS") != null) ?: false);
|
||||||
|
$this->migrator->add('website.useful_links_enabled', ($this->getOldValue("SETTINGS::SYSTEM:USEFULLINKS_ENABLED") != null) ?: true);
|
||||||
|
$this->migrator->add('website.seo_title', ($this->getOldValue("SETTINGS::SYSTEM:SEO_TITLE") != null) ?: 'ControlPanel.gg');
|
||||||
|
$this->migrator->add('website.seo_description', ($this->getOldValue("SETTINGS::SYSTEM:SEO_DESCRIPTION") != null) ?: 'Billing software for Pterodactyl Panel.');
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getOldValue(string $key)
|
public function getOldValue(string $key)
|
||||||
|
|
Loading…
Reference in a new issue