Enhance careers management features: update CareersPageController to fetch and display career listings with additional fields, modify Career model to include relationships and new attributes, and create a new view for the careers index with an application modal. Update database migration to reflect changes in the careers table structure and adjust routes for application submissions.
This commit is contained in:
@@ -14,9 +14,10 @@ return new class extends Migration
|
||||
Schema::create('careers', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('title');
|
||||
$table->text('description');
|
||||
$table->text('title_description')->nullable();
|
||||
$table->string('salary_per_month')->nullable();
|
||||
$table->json('bullets')->nullable();
|
||||
$table->string('location');
|
||||
$table->string('salary')->nullable();
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
<?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('applications', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->foreignId('career_id')->constrained()->onDelete('cascade');
|
||||
$table->string('name');
|
||||
$table->date('birthdate');
|
||||
$table->string('resume_file');
|
||||
$table->string('email');
|
||||
$table->string('phone_number');
|
||||
$table->text('cover_letter')->nullable();
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('applications');
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user