Browse Source

add database migrations for #6

pull/13/head
Aaron Parecki 7 years ago
parent
commit
4e8d9729b7
No known key found for this signature in database GPG Key ID: 276C2817346D6056
1 changed files with 33 additions and 0 deletions
  1. +33
    -0
      compass/database/migrations/2017_07_10_231240_database_settings.php

+ 33
- 0
compass/database/migrations/2017_07_10_231240_database_settings.php View File

@ -0,0 +1,33 @@
<?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class DatabaseSettings extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('databases', function (Blueprint $table) {
$table->string('timezone', 100)->default('UTC');
$table->boolean('metric')->default(true);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('databases', function (Blueprint $table) {
$table->dropColumn('timezone');
$table->dropColumn('metric');
});
}
}

Loading…
Cancel
Save