2015-01-29 09:32:24 +00:00
|
|
|
<?php if (!$field->hidden): ?>
|
2014-05-14 13:24:20 +00:00
|
|
|
|
2015-03-15 19:52:03 +00:00
|
|
|
<?php if (in_array($field->type, ['checkbox', 'switch', 'section'])): ?>
|
2014-05-14 13:24:20 +00:00
|
|
|
|
2015-01-29 09:32:24 +00:00
|
|
|
<?= $this->makePartial('field_'.$field->type, ['field' => $field]) ?>
|
2014-05-14 13:24:20 +00:00
|
|
|
|
2015-01-29 09:32:24 +00:00
|
|
|
<?php else: ?>
|
2014-05-14 13:24:20 +00:00
|
|
|
|
2015-01-29 09:32:24 +00:00
|
|
|
<?php if ($field->label): ?>
|
|
|
|
|
<label for="<?= $field->getId() ?>">
|
|
|
|
|
<?= e(trans($field->label)) ?>
|
|
|
|
|
</label>
|
|
|
|
|
<?php endif ?>
|
|
|
|
|
|
|
|
|
|
<?php if ($field->comment && $field->commentPosition == 'above'): ?>
|
|
|
|
|
<p class="help-block before-field"><?= e(trans($field->comment)) ?></p>
|
|
|
|
|
<?php endif ?>
|
|
|
|
|
|
|
|
|
|
<?= $this->renderFieldElement($field) ?>
|
2014-05-14 13:24:20 +00:00
|
|
|
|
2015-01-29 09:32:24 +00:00
|
|
|
<?php if ($field->comment && $field->commentPosition == 'below'): ?>
|
|
|
|
|
<p class="help-block"><?= e(trans($field->comment)) ?></p>
|
|
|
|
|
<?php endif ?>
|
2014-05-14 13:24:20 +00:00
|
|
|
|
|
|
|
|
<?php endif ?>
|
2014-06-29 03:35:47 +00:00
|
|
|
|
|
|
|
|
<?php endif ?>
|