1
0
Fork 0
forked from mirror/pixelfed
pixelfed/database/migrations/2018_09_11_202435_create_activities_table.php
2018-09-11 18:47:25 -06:00

36 lines
896 B
PHP

<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateActivitiesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('activities', function (Blueprint $table) {
$table->bigIncrements('id');
$table->bigInteger('to_id')->unsigned()->nullable();
$table->bigInteger('from_id')->unsigned()->nullable();
$table->string('object_type')->nullable();
$table->json('data')->nullable();
$table->timestamp('processed_at')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('activities');
}
}