<?php
/* @var $this PersonController */
/* @var $model Person */

$this->breadcrumbs = array(
    yii::t('default', 'Persons') => array('/person/index'),
    yii::t('default', 'LDAP Person') => '',
    yii::t('default', 'Search For Person'),

);
 ?>
<div id="flash-msg">
    <br>
<?php $this->widget('bootstrap.widgets.TbAlert'); ?>
</div>
<?php
$form = $this->beginWidget('bootstrap.widgets.TbActiveForm', array(
            'id' => 'ldapSearch-form',
            'enableAjaxValidation' => false,
        ));

$label = Yii::t('default', 'Person Information');
$popover_Content = Yii::t('default', 'tooltip_person_information');

echo Yii::app()->controller->widget('bootstrap.widgets.FTbButton', array(
    'label' => $label,
    'type' => 'link',
    'htmlOptions' => array(
        'data-trigger' => 'hover',
        'data-placement' => 'right',
        'data-animation' => true,
        'data-selector' => true,
        'tooltips' => true,
        'data-content' => $popover_Content,
        'rel' => 'popover'),
        ), true);

$this->widget('bootstrap.widgets.TbAlert');

echo CHtml::textField('person_information',$person_value);
?>

<div class="actions">

<?php echo CHtml::submitButton(Yii::t('default', 'Search'), array('class' => 'btn primary')); ?>

</div>

<?php $this->endWidget(); ?>





<?php
if (isset($arrayDataProvider) && ($arrayDataProvider != null))
{
    $this->widget('ext.bootstrap.widgets.TbGridView', array(
        'id' => 'person-grid',
        'type' => 'striped',
        'dataProvider' => $arrayDataProvider, //$model->search(),
        'columns' => array(
            array('name' => 'id', 'header' => Yii::t('default', 'Full Name')),
            array('name' => 'alias', 'header' => Yii::t('default', 'Alias')),
            array('name' => 'employeenumber', 'header' => Yii::t('default', 'Number')),
            array('name' => 'employeetype', 'header' => Yii::t('default', 'Type')),
            array('name' => 'mobile', 'header' => Yii::t('default', 'Mobile ')),
            array(
                'class' => 'CButtonColumn',
                'viewButtonUrl' => 'Yii::app()->createUrl("/lDAPPerson/create", array("alias" =>$data["alias"]))',
                'template' => '{view}',
                'buttons' => array(
                    'view' => array(
                        'label' => yii::t('default','Select'),
                        'imageUrl'=>Yii::app()->request->baseUrl.'/css/flags/select.png',
                    ),))
        ),
    ));
?>
<br />
<?php echo CHtml::link(Yii::t('default', 'Back'), array('/person/index'), array('class' => 'btn primary')); ?>
<?php
}
?>

