Ejemplo n.º 1
0
 /**
  * 构造方法
  * @author Colin <*****@*****.**>
  */
 public function __construct($tables = null)
 {
     //设置类成员
     self::setClassMember();
     //数据库信息是否填写
     self::CheckConnectInfo();
     //获取数据库对象
     $this->db = ObjFactory::getIns();
     if (empty($tables)) {
         return $this;
     }
     //执行判断表方法
     $this->TablesType($tables);
     //确认表是否存在
     $this->db->CheckTables($this->db_prefix . $this->DataName, $this->db_tabs);
     //初始化回调函数的句柄
     $this->callback = $tables;
 }
Ejemplo n.º 2
0
 /**
  * 初始化成员信息
  * @param type 类型
  * @author Colin <*****@*****.**>
  */
 public static function init($type, $config = array())
 {
     self::$view = ObjFactory::CreateTemplates($type, $config);
 }