|
@@ -3,10 +3,10 @@ |
|
|
class |
|
|
class |
|
|
User |
|
|
User |
|
|
{ |
|
|
{ |
|
|
var $id; |
|
|
|
|
|
var $name; |
|
|
|
|
|
var $pass; |
|
|
|
|
|
var $inheritance_code; |
|
|
|
|
|
|
|
|
public int $id; |
|
|
|
|
|
public string $name; |
|
|
|
|
|
public string $pass; |
|
|
|
|
|
public string $inheritance_code; |
|
|
|
|
|
|
|
|
public static function |
|
|
public static function |
|
|
find ( |
|
|
find ( |
|
@@ -44,11 +44,13 @@ User |
|
|
name, |
|
|
name, |
|
|
pass, |
|
|
pass, |
|
|
inheritance_code, |
|
|
inheritance_code, |
|
|
created_at) |
|
|
|
|
|
|
|
|
created_at, |
|
|
|
|
|
modified_at) |
|
|
VALUES |
|
|
VALUES |
|
|
('{$this -> name}', |
|
|
('{$this -> name}', |
|
|
'{$this -> pass}', |
|
|
'{$this -> pass}', |
|
|
'{$this -> inheritance_code}', |
|
|
'{$this -> inheritance_code}', |
|
|
|
|
|
NOW(), |
|
|
NOW())"; |
|
|
NOW())"; |
|
|
$GLOBALS['__db_connection'] -> query ($sql) |
|
|
$GLOBALS['__db_connection'] -> query ($sql) |
|
|
or die ("db_insert error $sql"); |
|
|
or die ("db_insert error $sql"); |
|
|