Exemplo n.º 1
0
 /**
  * @return TCVM_Admin_Model_Admin
  */
 public static function GetInstance()
 {
     if (!self::$_instance) {
         self::$_instance = new self();
     }
     return self::$_instance;
 }
Exemplo n.º 2
0
 private function _getAdminByUsername($username)
 {
     $model = TCVM_Admin_Model_Admin::GetInstance();
     $admin = $model->getOneByConditions(array("username" => $username));
     if ($admin) {
         return new TCVM_Admin_Entity_Admin($admin);
     } else {
         return null;
     }
 }