]> git.localhorst.tv Git - alttp.git/blob - database/migrations/2023_02_17_091506_create_events_table.php
sync speedgaming schedule for select events
[alttp.git] / database / migrations / 2023_02_17_091506_create_events_table.php
1 <?php
2
3 use Illuminate\Database\Migrations\Migration;
4 use Illuminate\Database\Schema\Blueprint;
5 use Illuminate\Support\Facades\Schema;
6
7 return new class extends Migration
8 {
9         /**
10          * Run the migrations.
11          *
12          * @return void
13          */
14         public function up()
15         {
16                 Schema::create('events', function (Blueprint $table) {
17                         $table->id();
18                         $table->string('name')->unique();
19                         $table->text('title');
20                         $table->timestamp('start')->nullable()->default(null);
21                         $table->timestamp('end')->nullable()->default(null);
22                         $table->boolean('visible')->default(false);
23                         $table->string('external_schedule')->nullable()->default(null);
24                         $table->timestamps();
25                 });
26         }
27
28         /**
29          * Reverse the migrations.
30          *
31          * @return void
32          */
33         public function down()
34         {
35                 Schema::dropIfExists('events');
36         }
37 };