<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateContentsTable extends Migration
{
    public function up()
    {
        Schema::create('contents', function (Blueprint $table) {
            $table->id(); // Auto-incrementing ID
            $table->string('content_name'); // Content name column
            $table->longText('content'); // Content column in HTML format
            $table->enum('role', ['user', 'vendor', 'driver', 'all']); // Role column with options
            $table->timestamps(); // Created at and updated at timestamps
        });
    }

    public function down()
    {
        Schema::dropIfExists('contents');
    }
}
