
<form method="post" name="user" class="form-base" enctype="multipart/form-data">
    <div class="grid">
        <div class="grid_cell form-base_lbl">ФИО пользователя:</div>
        <div class="grid_cell form-base_inp"><input class="inp-base" required type="text" name="fio" value="<?=$this->row['fio']?>"></div>
    </div>
    <div class="grid">
        <div class="grid_cell form-base_lbl">E-Mail:</div>
        <div class="grid_cell form-base_inp"><input class="inp-base" required type="email" name="email" value="<?=$this->row['email']?>"></div>
    </div>
    <div class="grid">
        <div class="grid_cell form-base_lbl">Пароль:</div>
        <div class="grid_cell form-base_inp"><input class="inp-base" <?=!$this->editUser ? 'required' : ''?> type="password" name="password" value=""></div>
    </div>
    <div class="grid">
        <div class="grid_cell form-base_lbl">Повторите пароль:</div>
        <div class="grid_cell form-base_inp"><input class="inp-base" <?=!$this->editUser ? 'required' : ''?> type="password" name="password2" value=""></div>
    </div>
    <?if(!$this->editUser || $this->row['id']!=Serval::call('Auth')->ID ){?>
    <div class="grid">
        <div class="grid_cell form-base_lbl">Статус пользователя:</div>
        <div class="grid_cell form-base_inp">
            <select name="type">
                <option <?=$this->row['type']=="admin" ? 'selected ' : ''?>value="admin">Администратор</option>
                <option <?=$this->row['type']=="user" ? 'selected ' : ''?>value="user">Пользователь</option>
            </select>
        </div>
    </div>
    <?}?>
    <div class="form-base_bttns">
    	<?if($this->editUser){?>
    		<input type="hidden" name="id" value="<?=$this->row['id']?>">
    		<button name="save_user" class="btn __primary ic_edit">Сохранить</button>
    	<?}else{?>
        <button name="create_user" class="btn __primary ic_edit">Создать</button>
      <?}?>
    </div>
</form>
