Skip to content

Instantly share code, notes, and snippets.

@clone1018
Created May 28, 2013 14:17
Show Gist options
  • Select an option

  • Save clone1018/5663071 to your computer and use it in GitHub Desktop.

Select an option

Save clone1018/5663071 to your computer and use it in GitHub Desktop.

Revisions

  1. clone1018 created this gist May 28, 2013.
    33 changes: 33 additions & 0 deletions migration.php
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,33 @@
    <?php

    use Illuminate\Database\Migrations\Migration;

    class ImproveCfs extends Migration
    {

    /**
    * Run the migrations.
    *
    * @return void
    */
    public function up()
    {
    Schema::table('cfs', function ($table) {
    $table->enum('type', array('file', 'folder', 'link'))->after('name');
    $table->string('mime')->nullable();

    $table->renameColumn('s3', 'cloud');
    });
    }

    /**
    * Reverse the migrations.
    *
    * @return void
    */
    public function down()
    {
    // Gotta figure out the reverse
    }

    }