_profile.php 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. <?php
  2. /*
  3. * This file is part of the Dektrium project
  4. *
  5. * (c) Dektrium project <http://github.com/dektrium>
  6. *
  7. * For the full copyright and license information, please view the LICENSE.md
  8. * file that was distributed with this source code.
  9. */
  10. use yii\bootstrap\ActiveForm;
  11. use yii\helpers\Html;
  12. /**
  13. * @var yii\web\View $this
  14. * @var dektrium\user\models\User $user
  15. * @var dektrium\user\models\Profile $profile
  16. */
  17. ?>
  18. <?php $this->beginContent('@dektrium/user/views/admin/update.php', ['user' => $user]) ?>
  19. <?php $form = ActiveForm::begin([
  20. 'layout' => 'horizontal',
  21. 'enableAjaxValidation' => true,
  22. 'enableClientValidation' => false,
  23. 'fieldConfig' => [
  24. 'horizontalCssClasses' => [
  25. 'wrapper' => 'col-sm-9',
  26. ],
  27. ],
  28. ]); ?>
  29. <?= $form->field($profile, 'name') ?>
  30. <?= $form->field($profile, 'public_email') ?>
  31. <?= $form->field($profile, 'website') ?>
  32. <?= $form->field($profile, 'location') ?>
  33. <?= $form->field($profile, 'gravatar_email') ?>
  34. <?= $form->field($profile, 'bio')->textarea() ?>
  35. <div class="form-group">
  36. <div class="col-lg-offset-3 col-lg-9">
  37. <?= Html::submitButton(Yii::t('user', 'Update'), ['class' => 'btn btn-block btn-success']) ?>
  38. </div>
  39. </div>
  40. <?php ActiveForm::end(); ?>
  41. <?php $this->endContent() ?>