mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 12:54:05 +00:00
Remove timestamps
This commit is contained in:
parent
dcc9bda758
commit
33f5f0e316
5 changed files with 3 additions and 3 deletions
|
|
@ -21,7 +21,6 @@ class CreateTenantsTable extends Migration
|
||||||
// (optional) your custom, indexed columns may go here
|
// (optional) your custom, indexed columns may go here
|
||||||
|
|
||||||
$table->json('data');
|
$table->json('data');
|
||||||
$table->timestamps();
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,6 @@ class CreateDomainsTable extends Migration
|
||||||
Schema::create('domains', function (Blueprint $table) {
|
Schema::create('domains', function (Blueprint $table) {
|
||||||
$table->string('domain', 255)->primary();
|
$table->string('domain', 255)->primary();
|
||||||
$table->string('tenant_id', 36);
|
$table->string('tenant_id', 36);
|
||||||
$table->timestamps();
|
|
||||||
|
|
||||||
$table->foreign('tenant_id')->references('id')->on('tenants')->onUpdate('cascade')->onDelete('cascade');
|
$table->foreign('tenant_id')->references('id')->on('tenants')->onUpdate('cascade')->onDelete('cascade');
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -85,7 +85,7 @@ class DatabaseStorageDriver implements StorageDriver
|
||||||
|
|
||||||
$domainData = [];
|
$domainData = [];
|
||||||
foreach ($tenant->domains as $domain) {
|
foreach ($tenant->domains as $domain) {
|
||||||
$domainData[] = ['domain' => $domain, 'tenant_id' => $tenant->id, 'created_at' => Carbon::now()];
|
$domainData[] = ['domain' => $domain, 'tenant_id' => $tenant->id];
|
||||||
}
|
}
|
||||||
|
|
||||||
Domains::insert($domainData);
|
Domains::insert($domainData);
|
||||||
|
|
|
||||||
|
|
@ -16,6 +16,7 @@ class DomainModel extends Model
|
||||||
protected $guarded = [];
|
protected $guarded = [];
|
||||||
protected $primaryKey = 'domain';
|
protected $primaryKey = 'domain';
|
||||||
public $incrementing = false;
|
public $incrementing = false;
|
||||||
|
public $timestamps = false;
|
||||||
|
|
||||||
public function getTable()
|
public function getTable()
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -16,6 +16,7 @@ class TenantModel extends Model
|
||||||
protected $guarded = [];
|
protected $guarded = [];
|
||||||
protected $primaryKey = 'id';
|
protected $primaryKey = 'id';
|
||||||
public $incrementing = false;
|
public $incrementing = false;
|
||||||
|
public $timestamps = false;
|
||||||
|
|
||||||
public function getTable()
|
public function getTable()
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue