2020_01_10_080414_create_groups_table.php 743 Bytes
Newer Older
Jacob Priddy's avatar
Jacob Priddy committed
1
2
3
<?php

use Illuminate\Support\Facades\Schema;
Jacob Priddy's avatar
Jacob Priddy committed
4
5
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
Jacob Priddy's avatar
Jacob Priddy committed
6
7
8
9
10
11
12
13
14
15
16

class CreateGroupsTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        // This table stores the groups objects stored in the system
17
18
        Schema::create('groups', static function (Blueprint $table) {
            $table->id();
19
            $table->string('title')->unique();
Jacob Priddy's avatar
Jacob Priddy committed
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
            $table->string('description');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('groups');
    }
}