Added Add Admin

This commit is contained in:
Deon George
2014-10-28 16:56:56 +11:00
parent 80c8971a46
commit 43bd45d43e
7 changed files with 108 additions and 12 deletions

View File

@@ -24,6 +24,10 @@ abstract class lnApp_Database_Query_Builder_Insert extends Kohana_Database_Query
}
switch ($this->_table) {
case 'ADMINS':
$query = sprintf('REGISTER ADMIN %s %s %s',$this->pop_value('ADMIN_NAME'),$this->pop_value('PASSWORD'),$this->insert_values());
break;
case 'NODES':
$query = sprintf('REGISTER NODE %s %s %s',$this->pop_value('NODE_NAME'),$this->pop_value('PASSWORD'),$this->insert_values());

View File

@@ -25,6 +25,13 @@ abstract class lnApp_Model_ADMIN extends ORM_TSM {
),
);
protected $_custom_cols = array(
'EMAILADDRESS',
'FORCEPWRESET',
'PASSWORD',
'SSL',
);
public function name() {
return $this->ADMIN_NAME;
}