37 lines
965 B
PHP
37 lines
965 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('agents', function (Blueprint $table) {
|
|
$table->id();
|
|
$table->string('first_name');
|
|
$table->string('last_name');
|
|
$table->string('email')->unique();
|
|
$table->string('position');
|
|
$table->string('department');
|
|
$table->date('arrival_date');
|
|
$table->string('integration_status');
|
|
$table->foreignId('created_by')->constrained('users');
|
|
$table->timestamp('validated_by_rh_at')->nullable();
|
|
$table->timestamps();
|
|
});
|
|
}
|
|
|
|
/**
|
|
* Reverse the migrations.
|
|
*/
|
|
public function down(): void
|
|
{
|
|
Schema::dropIfExists('agents');
|
|
}
|
|
};
|