<?php
namespace app\models;
use yii\db\ActiveRecord;
class RegistrationModel extends ActiveRecord
{
public $login;
public $password;
public $role;
public static function tableName()
{
return 'users';
}
public function rules()
{
return [
[['login', 'password', 'role'], 'required'],
];
}
public function attributeLabels()
{
return [
'login' => 'Логин',
'password' => 'Пароль',
'role' => 'Роль пользователя',
];
}
}