added email change strategies

This commit is contained in:
Antonio Ramirez
2016-12-10 14:14:42 +01:00
parent 3fe09e3eb3
commit e215fd58bf
19 changed files with 626 additions and 119 deletions

View File

@ -24,11 +24,13 @@ use yii\web\IdentityInterface;
* @property integer $id
* @property string $username
* @property string $email
* @property string $unconfirmed_email
* @property string $password_hash
* @property string $auth_key
* @property integer $registration_ip
* @property integer $confirmed_at
* @property integer $blocked_at
* @property integer $flags
* @property integer $created_at
* @property integer $updated_at
*
@ -41,6 +43,10 @@ class User extends ActiveRecord implements IdentityInterface
use ModuleTrait;
use ContainerTrait;
// following constants are used on secured email changing process
const OLD_EMAIL_CONFIRMED = 0b1;
const NEW_EMAIL_CONFIRMED = 0b10;
/**
* @var string default user name regular expression.
*/