HoshiAI-be/database/migrations/2025_11_10_200607_create_logs_table.php
2025-11-10 22:47:08 +01:00

30 lines
647 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('logs', function (Blueprint $table) {
$table->id();
$table->string("description", 255);
$table->enum('type', ['error', 'access'])->default('access');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('logs');
}
};