33 lines
778 B
PHP
33 lines
778 B
PHP
<?php
|
|
namespace app\core\auth;
|
|
|
|
class Session {
|
|
|
|
public $_attributes = [
|
|
'session_id' => null,
|
|
'login_id' => null,
|
|
'user_id' => null,
|
|
'role_id' => null,
|
|
'email_address' => null,
|
|
'first_name' => null,
|
|
'last_name' => null,
|
|
'remember_me' => false,
|
|
'isBOUser' => false,
|
|
'isFirstLogin' => false,
|
|
'isPremium' => false,
|
|
'sso' => [],
|
|
'token_id' => null
|
|
];
|
|
|
|
public function __construct($attributes) {
|
|
$this->_attributes = array_merge($this->_attributes, $attributes);
|
|
}
|
|
|
|
public function __set($property, $value) {
|
|
$this->_attributes[$property] = $value;
|
|
}
|
|
|
|
public function toArray() {
|
|
return (array) $this->_attributes;
|
|
}
|
|
} |