_form.php 822 B

1234567891011121314151617181920212223242526272829
  1. <?php
  2. use yii\helpers\Html;
  3. use yii\widgets\ActiveForm;
  4. /* @var $this yii\web\View */
  5. /* @var $model plugins\donation\models\Donation */
  6. /* @var $form yii\widgets\ActiveForm */
  7. ?>
  8. <div class="donation-form">
  9. <?php $form = ActiveForm::begin(); ?>
  10. <?= $form->field($model, 'name')->textInput(['maxlength' => true]) ?>
  11. <?= $form->field($model, 'source')->textInput(['maxlength' => true]) ?>
  12. <?= $form->field($model, 'money')->textInput(['maxlength' => true]) ?>
  13. <?= $form->field($model, 'remark')->textInput(['maxlength' => true]) ?>
  14. <div class="form-group">
  15. <?= Html::submitButton($model->isNewRecord ? Yii::t('app', 'Create') : Yii::t('app', 'Update'), ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-primary']) ?>
  16. </div>
  17. <?php ActiveForm::end(); ?>
  18. </div>