BookStackApp_BookStack/database/migrations/2015_08_16_142133_create_ac...

34 lines
795 B
PHP

<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
/**
* Run the migrations.
*/
public function up(): void
{
Schema::create('activities', function (Blueprint $table) {
$table->increments('id');
$table->string('key');
$table->text('extra');
$table->integer('book_id')->indexed();
$table->integer('user_id');
$table->integer('entity_id');
$table->string('entity_type');
$table->nullableTimestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::drop('activities');
}
};