2014-09-29 12:29:36 +02:00
<?php
use Icinga\Web\Wizard;
$radioElem = $form->getElement('user_type');
$showRadioBoxes = strpos(strtolower(get_class($radioElem)), 'radio') !== false;
?>
2014-10-27 09:01:00 +01:00
< form id = " <? = $form -> getName (); ?> " name = " <? = $form -> getName (); ?> " enctype = " <? = $form -> getEncType (); ?> " method = " <? = $form -> getMethod (); ?> " action = " <? = $form -> getAction (); ?> " >
2015-03-03 09:53:25 +01:00
< h1 > <? = $this -> translate ( 'Administration' , 'setup.page.title' ); ?> </ h1 >
2015-03-02 18:36:04 +01:00
< ul class = "descriptions" >
< li > <? = $this -> translatePlural (
'Now it\'s time to configure your first administrative account for Icinga Web 2. Please follow the instructions below:',
'Now it\'s time to configure your first administrative account for Icinga Web 2. Below are several options you can choose from. Select one and follow its instructions:',
$showRadioBoxes ? count($radioElem->getMultiOptions()) : 1
); ?>< / li >
< / ul >
2014-11-11 15:27:14 +01:00
<? = $form -> getElement ( 'title' ); ?>
2014-09-29 12:29:36 +02:00
<? = $form -> getElement ( 'description' ); ?>
<?php if (( $byNameElem = $form -> getElement ( 'by_name' )) !== null ) : ?>
< div >
2014-10-01 15:46:58 +02:00
< div class = "instructions" >
2014-09-29 12:29:36 +02:00
<? = $byNameElem ; ?>
< / div >
<?php if ( $showRadioBoxes ) : ?>
2014-10-01 15:46:58 +02:00
< div class = "radiobox" >
2014-09-29 12:29:36 +02:00
< label >
2015-02-05 13:18:21 +01:00
< input type = "radio" name = "user_type" value = "by_name" <? = $radioElem -> getValue () === 'by_name' ? ' checked' : '' ; ?> class = "autosubmit" aria-required = "true" required >
2014-09-29 12:29:36 +02:00
<? = $radioElem -> getMultiOption ( 'by_name' ); ?>
< / label >
< / div >
<?php endif ?>
< / div >
<?php endif ?>
<?php if (( $existingUserElem = $form -> getElement ( 'existing_user' )) !== null ) : ?>
< div >
2014-10-01 15:46:58 +02:00
< div class = "instructions" >
2014-09-29 12:29:36 +02:00
<? = $existingUserElem ; ?>
< / div >
<?php if ( $showRadioBoxes ) : ?>
2014-10-01 15:46:58 +02:00
< div class = "radiobox" >
2014-09-29 12:29:36 +02:00
< label >
2015-02-05 13:18:21 +01:00
< input type = "radio" name = "user_type" value = "existing_user" <? = $radioElem -> getValue () === 'existing_user' ? ' checked' : '' ; ?> class = "autosubmit" aria-required = "true" required >
2014-09-29 12:29:36 +02:00
<? = $radioElem -> getMultiOption ( 'existing_user' ); ?>
< / label >
< / div >
<?php endif ?>
< / div >
<?php endif ?>
<?php if (( $newUserElem = $form -> getElement ( 'new_user' )) !== null ) : ?>
< div >
2014-10-01 15:46:58 +02:00
< div class = "instructions" >
2014-09-29 12:29:36 +02:00
<? = $newUserElem ; ?>
<? = $form -> getElement ( 'new_user_password' ); ?>
<? = $form -> getElement ( 'new_user_2ndpass' ); ?>
< / div >
<?php if ( $showRadioBoxes ) : ?>
2014-10-01 15:46:58 +02:00
< div class = "radiobox" >
2014-09-29 12:29:36 +02:00
< label >
2015-02-05 13:18:21 +01:00
< input type = "radio" name = "user_type" value = "new_user" <? = $radioElem -> getValue () === 'new_user' ? ' checked' : '' ; ?> class = "autosubmit" aria-required = "true" required >
2014-09-29 12:29:36 +02:00
<? = $radioElem -> getMultiOption ( 'new_user' ); ?>
< / label >
< / div >
<?php endif ?>
< / div >
<?php endif ?>
<?php if ( false === $showRadioBoxes ) : ?>
<? = $radioElem ; ?>
<?php endif ?>
<? = $form -> getElement ( $form -> getTokenElementName ()); ?>
<? = $form -> getElement ( $form -> getUidElementName ()); ?>
2014-10-06 11:07:21 +02:00
< div class = "buttons" >
2014-10-09 16:12:36 +02:00
<?php
$btn = clone $form->getElement(Wizard::BTN_NEXT);
$btn->setAttrib('class', 'double');
$btn->setAttrib('tabindex', -1);
echo $btn;
?>
2014-10-06 11:07:21 +02:00
<? = $form -> getElement ( Wizard :: BTN_PREV ); ?>
<? = $form -> getElement ( Wizard :: BTN_NEXT ); ?>
< / div >
2014-09-29 12:29:36 +02:00
< / form >