示例#1
0
?>
    </div>
</div>

<div style="clear: both;">
    <div class="row">
        <span style="line-height: 32px;">Дата выхода книги</span>
    </div>
    <div class="row">
        <?php 
echo $form->field($model, 'fromDate')->widget(Datepicker::className(), ['format' => 'dd/mm/yyyy', 'options' => ['class' => 'field-datepicker'], 'placeholder' => $model->getAttributeLabel('fromDate')]);
?>
    </div>

    <div class="row">
        <?php 
echo $form->field($model, 'toDate')->widget(Datepicker::className(), ['format' => 'dd/mm/yyyy', 'options' => ['class' => 'field-datepicker'], 'placeholder' => $model->getAttributeLabel('toDate')]);
?>
    </div>

    <div class="form-group">
        <?php 
echo Html::submitButton('Искать', ['class' => 'btn btn-primary']);
?>
    </div>

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

</div>
示例#2
0
文件: _form.php 项目: kbulaeva/books
    <?php 
$form = ActiveForm::begin(['validateOnChange' => false, 'validateOnBlur' => false]);
?>

    <?php 
echo $form->field($model, 'name')->textInput(['maxlength' => 120]);
?>

    <?php 
echo $form->field($model, 'author_id')->dropDownList($authors);
?>

    <?php 
echo $form->field($model, 'preview')->textInput(['maxlength' => 255]);
?>

    <?php 
echo $form->field($model, 'date')->widget(Datepicker::className(), ['format' => 'yyyy-mm-dd', 'options' => ['class' => 'field-datepicker']]);
?>

    <div class="form-group">
        <?php 
echo Html::submitButton($model->isNewRecord ? 'Добавить' : 'Сохранить', ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-primary']);
?>
    </div>

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

</div>