firstcommit

This commit is contained in:
2025-08-17 16:23:14 +05:45
commit 76bf4c0a18
2648 changed files with 362795 additions and 0 deletions

View File

@@ -0,0 +1,35 @@
<?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('appointments', function (Blueprint $table) {
$table->id();
$table->uuid();
$table->unsignedBigInteger('team_member_id');
$table->string('full_name');
$table->string('email');
$table->string('contact_no');
$table->text('subject');
$table->text('feedback');
$table->softDeletes();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('appointments');
}
};

View File

@@ -0,0 +1,59 @@
<?php
namespace Modules\Appointment\database\seeders;
use Illuminate\Support\Str;
use Illuminate\Database\Seeder;
use Modules\Appointment\app\Models\Appointment;
class AppointmentDatabaseSeeder extends Seeder
{
/**
* Run the database seeds.
*/
public function run(): void
{
$appointments = [
[
'team_member_id' => '1',
'full_name' => 'Jhon Doe',
'email' => 'jhondoe@xyz.com',
'contact_no' => '+9779800236532',
'subject' => 'Appointment Request For Follow-up',
'feedback' => "Dear Dr. Johnson,I hope this email finds you in good health. I am writing to request an appointment with you for my annual check-up.
Preferred Date: April 10th, 2024
Preferred Time: Anytime between 10:00 AM and 2:00 PM
Please let me know if any of the mentioned time slots are available or suggest an alternative that suits your schedule. Additionally, if there are any specific preparations I need to make before the appointment, kindly inform me.
Thank you for your attention to this matter. I appreciate your prompt response.
Warm regards,
Jhon Doe",
],
[
'team_member_id' => '2',
'full_name' => 'Sudarshan Shrestha',
'email' => 'sudarshansth@xyz.com',
'contact_no' => '+9779800236533',
'subject' => 'Appointment Request To Consult About Brain Tumor',
'feedback' => "Dear Dr. Sita Sakya,I hope this email finds you in good health. I am writing to request an appointment with you for my annual check-up.
Preferred Date: December 10th, 2024
Preferred Time: Anytime between 10:00 AM and 2:00 PM
Please let me know if any of the mentioned time slots are available or suggest an alternative that suits your schedule. Additionally, if there are any specific preparations I need to make before the appointment, kindly inform me.
Thank you for your attention to this matter. I appreciate your prompt response.
Warm regards,
Sudarshan Shrestha",
],
];
foreach ($appointments as $appointment) {
$appointment = Appointment::create([
'uuid' => Str::uuid(),
'team_member_id' => $appointment['team_member_id'],
'full_name' => $appointment['full_name'],
'email' => $appointment['email'],
'contact_no' => $appointment['contact_no'],
'subject' => $appointment['subject'],
'feedback' => $appointment['feedback'],
]);
}
}
}