Version 4.3.0
This commit is contained in:
1 parent
96997ddd8e
commit
fe1acf984a
1349 files changed
+116159
-67711
No files matched your search
@@ -55,24 +55,15 @@ class _checkoutsettings extends \IPS\Dispatcher\Controller
|
||||
{
|
||||
$requireBillingOptions['domain'] = 'nexus_require_billing_domain';
|
||||
}
|
||||
|
||||
if ( \IPS\Settings::i()->nexus_subs_enabled and \IPS\Db::i()->select( 'COUNT(*)', 'nexus_member_subscription_packages' )->first() )
|
||||
{
|
||||
$requireBillingOptions['subscriptions'] = 'nexus_require_billing_subscriptions';
|
||||
}
|
||||
$requireBillingOptions['other'] = 'nexus_require_billing_other';
|
||||
|
||||
$form = new \IPS\Helpers\Form;
|
||||
$form->addHeader( 'checkout_settings' );
|
||||
$form->add( new \IPS\Helpers\Form\YesNo( 'nexus_https', \IPS\Settings::i()->nexus_https, FALSE, array(), function( $val )
|
||||
{
|
||||
if ( $val )
|
||||
{
|
||||
try
|
||||
{
|
||||
\IPS\Http\Url::internal( '', 'front', NULL, array(), TRUE )->request()->get();
|
||||
}
|
||||
catch ( \IPS\Http\Request\Exception $e )
|
||||
{
|
||||
throw new \DomainException('nexus_https_err');
|
||||
}
|
||||
}
|
||||
} ) );
|
||||
$form->add( new \IPS\Helpers\Form\CheckboxSet( 'nexus_require_billing', explode( ',', \IPS\Settings::i()->nexus_require_billing ), FALSE, array( 'options' => $requireBillingOptions ) ) );
|
||||
$form->add( new \IPS\Helpers\Form\YesNo( 'nexus_split_payments_on', \IPS\Settings::i()->nexus_split_payments != -1, FALSE, array( 'togglesOn' => array( 'nexus_split_payments' ) ) ) );
|
||||
$form->add( new \IPS\nexus\Form\Money( 'nexus_split_payments', \IPS\Settings::i()->nexus_split_payments ?: '*', FALSE, array( 'unlimitedLang' => 'no_restriction' ), NULL, NULL, NULL, 'nexus_split_payments' ) );
|
||||
|
||||
Reference in new issue
Block a user