<?php

use common\models\ShareLevel;
use common\modules\user\models\User;
use yii\helpers\ArrayHelper;

/*
 * This file is part of the Dektrium project.
 *
 * (c) Dektrium project <http://github.com/dektrium>
 *
 * For the full copyright and license information, please view the LICENSE.md
 * file that was distributed with this source code.
 */

/**
 * @var yii\widgets\ActiveForm 		$form
 * @var User 	$user
 */
?>

<?= $form->field($user, 'username')->textInput(['maxlength' => 255, 'readonly' => $user->type == User::TYPE_PERSON])->hint($user->type == User::TYPE_PERSON ? '微信用户不能修改用户名' : '') ?>
<?= $form->field($user, 'nickname')->textInput() ?>
<?= $form->field($user, 'password')->passwordInput() ?>
<?= $form->field($user, 'email')->textInput(['maxlength' => 255]) ?>
<?= $form->field($user, 'tel')->textInput(['maxlength' => 255]) ?>
