simedkom/database/migrations/2025_06_02_142649_create_contacts_table.php
2025-06-23 14:33:55 +07:00

36 lines
881 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('contacts', function (Blueprint $table) {
$table->id();
$table->string('name');
$table->string('email');
$table->string('phone_number');
$table->text('message');
$table->text('reply_message')->nullable();
$table->string('ip_address');
$table->enum('status', ['0', '1'])->default('0');
$table->timestamps();
$table->softDeletes();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('contacts');
}
};