D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
home
/
forge
/
euphoriahub.store
/
database
/
migrations
/
Filename :
2025_03_08_204555_create_attachments_table.php
back
Copy
<?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('attachments', function (Blueprint $table) { $table->id(); $table->morphs('attachable'); $table->string('file_type')->nullable(); $table->string('file_name')->nullable(); $table->string('storage_disk')->default('public'); $table->timestamp('created_at')->useCurrent(); $table->timestamp('updated_at')->useCurrent(); }); } /** * Reverse the migrations. */ public function down(): void { Schema::dropIfExists('attachments'); } };