cleanup database migrations
This commit is contained in:
@@ -34,6 +34,32 @@ class CreateStructures extends Migration
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
if(!Schema::hasTable('CorpStructures')) {
|
||||
Schema::create('CorpStructures', function(Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('character_id');
|
||||
$table->integer('corporation_id');
|
||||
$table->string('corporation_name');
|
||||
$table->string('region');
|
||||
$table->string('system');
|
||||
$table->string('structure_name');
|
||||
$table->decimal('tax', 10, 2);
|
||||
$table->string('structure_type');
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
if(!Schema::hasTable('corp_tax_ratios')) {
|
||||
Schema::create('corp_tax_ratios', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('corporation_id');
|
||||
$table->string('corporation_name');
|
||||
$table->string('structure_type');
|
||||
$table->string('ratio');
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -44,5 +70,7 @@ class CreateStructures extends Migration
|
||||
public function down()
|
||||
{
|
||||
Schema::dropIfExists('Structures');
|
||||
Schema::dropIfExists('CorpStructures');
|
||||
Schema::dropIfExists('corp_tax_ratios');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user