d2d.emegrendeles.hu/database/migrations/2021_10_15_180023_create_attachments_table.php
E98Developer 68b7c35bef git init
2026-02-28 06:53:05 +01:00

37 lines
918 B
PHP

<?php
use App\Database\Blueprint;
use Illuminate\Database\Migrations\Migration;
return new class extends Migration
{
/**
* Run the migrations.
*/
public function up(): void
{
Schema::create('attachments', function (Blueprint $table) {
$table->bigIncrements('id');
$table->integer('attachable_id')->nullable();
$table->string('attachable_type')->nullable();
$table->string('path')->nullable();
$table->string('filename')->nullable();
$table->string('mimetype')->nullable();
$table->integer('size')->nullable();
$table->string('original_filename')->nullable();
$table->timestamps();
$table->userIdFields();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('attachments');
}
};