Adding commit message to Build
This commit is contained in:
parent
e888032bdf
commit
eaec52b525
14 changed files with 189 additions and 46 deletions
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
namespace PHPCI\Model\Base;
|
||||
|
||||
use b8\Model;
|
||||
use PHPCI\Model;
|
||||
use b8\Store\Factory;
|
||||
|
||||
/**
|
||||
|
|
@ -82,14 +82,17 @@ class UserBase extends Model
|
|||
'email' => array(
|
||||
'type' => 'varchar',
|
||||
'length' => 250,
|
||||
'default' => null,
|
||||
),
|
||||
'hash' => array(
|
||||
'type' => 'varchar',
|
||||
'length' => 250,
|
||||
'default' => null,
|
||||
),
|
||||
'is_admin' => array(
|
||||
'type' => 'tinyint',
|
||||
'length' => 1,
|
||||
'default' => null,
|
||||
),
|
||||
'name' => array(
|
||||
'type' => 'varchar',
|
||||
|
|
@ -270,4 +273,26 @@ class UserBase extends Model
|
|||
|
||||
$this->_setModified('name');
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public static function getByPrimaryKey($value, $useConnection = 'read')
|
||||
{
|
||||
return Factory::getStore('User', 'PHPCI')->getByPrimaryKey($value, $useConnection);
|
||||
}
|
||||
|
||||
|
||||
public static function getById($value, $useConnection = 'read')
|
||||
{
|
||||
return Factory::getStore('User', 'PHPCI')->getById($value, $useConnection);
|
||||
}
|
||||
|
||||
public static function getByEmail($value, $useConnection = 'read')
|
||||
{
|
||||
return Factory::getStore('User', 'PHPCI')->getByEmail($value, $useConnection);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue