File: /var/www/html/owlcrm/database/migrations/2024_05_14_060156_create_customers_table.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('customers', function (Blueprint $table) {
$table->id();
$table->unsignedBigInteger('created_by')->nullable();
$table->string('Salutation')->nullable();
$table->string('first_name');
$table->string('last_name');
$table->string('gender');
$table->string('company')->nullable();
$table->string('position')->nullable();
$table->string('email_address')->nullable();
$table->string('website')->nullable();
$table->string('phone')->nullable();
$table->string('mobile_number')->nullable();
$table->text('description')->nullable();
$table->string('address_line_1')->nullable();
$table->string('address_line_2')->nullable();
$table->unsignedBigInteger('city');
$table->unsignedBigInteger('state');
$table->string('postal_code')->nullable();
$table->unsignedBigInteger('country');
$table->string('status')->default('0');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('customers');
}
};