<?php

use yii\helpers\Html;
use yii\widgets\ActiveForm;

/* @var $this yii\web\View */
/* @var $model backend\models\EventSearch */
/* @var $form yii\widgets\ActiveForm */
?>

<div class="event-search">

    <?php $form = ActiveForm::begin([
        'action' => ['index'],
        'method' => 'get',
    ]); ?>

    <div class="panel panel-default">
        <div class="panel-heading">
            <h3 class="panel-title">Keresés</h3>
        </div>
        <div class="panel-body">
            <div class="row">
                <div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
                    <?= $form->field($model, 'id') ?>
                </div>
                <div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
                    <?= $form->field($model, 'startDateString')->widget(\kartik\widgets\DateTimePicker::classname(), [
        'pluginOptions' => [
            'autoclose'=>true,
            'format' => 'yyyy.mm.dd hh:ii'
        ],
        'options' => [
            'autocomplete' => 'off'
        ]
    ]); ?>
                </div>
                <div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
                    <?= $form->field($model, 'endDateString')->widget(\kartik\widgets\DateTimePicker::classname(), [
                        'pluginOptions' => [
                            'autoclose'=>true,
                            'format' => 'yyyy.mm.dd hh:ii'
                        ],
                        'options' => [
                            'autocomplete' => 'off'
                        ]
                    ])
                    ?>
                </div>
                <div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
                    <?= $form->field($model, 'roomName')->dropDownList(\common\models\Room::roomOptions(true)) ?>
                </div>
            </div>
            <div class="row">
                <div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
                    <?= $form->field($model, 'trainerName')->dropDownList(\common\models\Trainer::trainerOptions(true)) ?>
                </div>
                <div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
                    <?php  echo $form->field($model, 'eventTypeName')->dropDownList(\common\models\EventType::eventTypeOptions(true)) ?>
                </div>
                <div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
                </div>
                <div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
                </div>
            </div>
        </div>
        <div class="panel-footer">
        <?= Html::submitButton(Yii::t('event', 'Search'), ['class' => 'btn btn-primary']) ?>
        </div>
    </div>

    <?php ActiveForm::end(); ?>

</div>
