_form_custom.php 815 B

1234567891011121314151617181920212223242526
  1. <?php
  2. /**
  3. * Author: lf
  4. * Blog: https://blog.feehi.com
  5. * Email: job@feehi.com
  6. * Created at: 2018-09-16 20:32
  7. */
  8. use backend\widgets\ActiveForm;
  9. use common\libs\Constants;
  10. /**
  11. * @var $formType string
  12. * @var $model common\models\Options
  13. */
  14. ?>
  15. <div class="ibox-content">
  16. <?php $form = ActiveForm::begin(['options' => ['name' => 'custom']]);?>
  17. <?= $form->field($model, 'name')->textInput();?>
  18. <?= $form->field($model, 'input_type')->dropDownList(Constants::getInputTypeItems());?>
  19. <?= $form->field($model, 'tips')->textInput();?>
  20. <?= $form->field($model, 'autoload')->dropDownList(Constants::getYesNoItems());?>
  21. <?= $form->field($model, 'value')->textInput();?>
  22. <?= $form->field($model, 'sort')->textInput();?>
  23. <?= $form->defaultButtons();?>
  24. <?php ActiveForm::end();?>
  25. </div>