예제 #1
0
 public function __construct()
 {
     $table = new DBTable();
     $table->column('key')->string(255)->index()->primary();
     $table->column('value')->longtext();
     parent::__construct($table);
 }
예제 #2
0
 public function __construct($username = null, $password = null)
 {
     parent::__construct();
     $this->username = $username;
     if ($password !== null) {
         $this->password = $this->setPassword($password);
     }
     $this->admin_level = 0;
     $this->deleted = false;
     $this->last_activity = Carbon::now();
 }
예제 #3
0
 public function __construct($file)
 {
     parent::__construct();
     $this->id = Guid::create();
     $this->filename = basename($file);
     $this->path = dirname($file);
     if (is_file($file)) {
         $this->type = mime_content_type($file);
         $this->bytes = filesize($file);
     }
 }
예제 #4
0
 public function __construct()
 {
     $table = new DBTable('source');
     $table->column('id')->bigint()->primary()->increment();
     $table->column('organisation_id')->integer()->index();
     $table->column('name')->string(255);
     $table->column('type')->string(255)->index();
     $table->column('subdomain')->string(255)->index();
     $table->column('require_ssl')->bool();
     $table->column('error_image_url')->string(400);
     $table->column('error_image_parameters')->text();
     $table->column('missing_image_url')->string(400);
     $table->column('missing_image_parameters')->text();
     $table->column('default_parameters')->text();
     $table->column('last_activity')->datetime()->index();
     parent::__construct($table);
     $this->cloudflareIds = array();
     $this->last_activity = Date::toDateTime();
 }