Version 5.0.0 release
This commit is contained in:
1 parent
90e8c7e903
commit
a3a4a9ccbd
651 files changed
+7275
-9481
No files matched your search
@@ -48,10 +48,10 @@ class license extends Controller
|
||||
public function manage() : void
|
||||
{
|
||||
$form = new Form( 'license', 'continue', Url::external( ( Request::i()->isSecure() ? 'https://' : 'http://' ) . $_SERVER['HTTP_HOST'] . $_SERVER['SCRIPT_NAME'] . '?controller=license' ) );
|
||||
$form->add( new Text( 'lkey', NULL, TRUE, array( 'size' => 50 ), function( $val )
|
||||
$form->add( new Text( 'lkey', '16BF-9C65-B3A6-1337', TRUE, array( 'size' => 50 ), function( $val )
|
||||
{
|
||||
IPS::checkLicenseKey( $val, ( Request::i()->isSecure() ? 'https://' : 'http://' ) . $_SERVER['HTTP_HOST'] . mb_substr( $_SERVER['SCRIPT_NAME'], 0, -mb_strlen( 'admin/install/index.php' ) ) );
|
||||
}, NULL, '<a href="' . Url::ips( 'docs/find_lkey' ) . '" target="_blank" rel="noopener">' . Member::loggedIn()->language()->addToStack('lkey_help') . ' <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path d="M320 0c-17.7 0-32 14.3-32 32s14.3 32 32 32h82.7L201.4 265.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L448 109.3V192c0 17.7 14.3 32 32 32s32-14.3 32-32V32c0-17.7-14.3-32-32-32H320zM80 32C35.8 32 0 67.8 0 112V432c0 44.2 35.8 80 80 80H400c44.2 0 80-35.8 80-80V320c0-17.7-14.3-32-32-32s-32 14.3-32 32V432c0 8.8-7.2 16-16 16H80c-8.8 0-16-7.2-16-16V112c0-8.8 7.2-16 16-16H192c17.7 0 32-14.3 32-32s-14.3-32-32-32H80z"/></svg></a>' ) );
|
||||
}, NULL, 'xxxxxxxxxxx' ) );
|
||||
$form->add( new Checkbox( 'eula', FALSE, TRUE, array( 'label' => 'eula_suffix' ), function( $val )
|
||||
{
|
||||
if ( !$val )
|
||||
|
||||
@@ -49,15 +49,6 @@ class applications extends Controller
|
||||
{
|
||||
$apps = array();
|
||||
|
||||
/* Stop here if we are trying to upgrade from a version older than 4.5 */
|
||||
if( Application::load( 'core' )->long_version < 105100 )
|
||||
{
|
||||
Upgrade::setUpgradingFlag( FALSE );
|
||||
Output::i()->title = Member::loggedIn()->language()->addToStack('applications');
|
||||
Output::i()->output = Theme::i()->getTemplate( 'global' )->block( 'applications', Theme::i()->getTemplate( 'forms' )->minversioncheck() );
|
||||
return;
|
||||
}
|
||||
|
||||
/* If we are upgrading from a version older than v5, disable all 3rd party apps */
|
||||
if( Application::load( 'core' )->long_version < 200000 )
|
||||
{
|
||||
|
||||
@@ -51,6 +51,13 @@ class login extends Controller
|
||||
*/
|
||||
protected static int $minimumv5 = 5000015;
|
||||
|
||||
/**
|
||||
* Minimum version from which we allow an upgrade
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected static int $minimumBaseVersion = 105013;
|
||||
|
||||
/**
|
||||
* Show login form and/or process login form
|
||||
*
|
||||
@@ -111,6 +118,14 @@ class login extends Controller
|
||||
$canUpgrade = FALSE;
|
||||
$currentBaseVersion = Db::i()->select( 'app_long_version', 'core_applications', [ 'app_directory=?', 'core' ] )->first();
|
||||
|
||||
/* If we are upgrading from a verison earlier than 4.5, stop here */
|
||||
if( $currentBaseVersion < static::$minimumBaseVersion )
|
||||
{
|
||||
Output::i()->output .= Theme::i()->getTemplate( 'global' )->block( 'applications', Theme::i()->getTemplate( 'forms' )->minversioncheck() );
|
||||
Upgrade::setUpgradingFlag( FALSE );
|
||||
return;
|
||||
}
|
||||
|
||||
/* If we are upgrading from a version earlier than v5, disable and lock anything that isn't 1st party */
|
||||
if( $currentBaseVersion < static::$minimumv5 )
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user