Initial commit - Physiotherapy Clinic Management System
This commit is contained in:
commit
dbb326f2cc
300 files changed
+144285
No files matched your search
@@ -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
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('wages', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->foreignId('user_id')->constrained('users'); // therapist/staff
|
||||
$table->date('period_start');
|
||||
$table->date('period_end');
|
||||
$table->integer('sessions_count')->default(0);
|
||||
$table->integer('hours_worked')->default(0);
|
||||
$table->decimal('base_amount', 15, 2);
|
||||
$table->decimal('bonus', 15, 2)->default(0);
|
||||
$table->decimal('deductions', 15, 2)->default(0);
|
||||
$table->decimal('total_amount', 15, 2);
|
||||
$table->foreignId('currency_id')->constrained('currencies');
|
||||
$table->enum('status', ['draft', 'approved', 'paid'])->default('draft');
|
||||
$table->text('notes')->nullable();
|
||||
$table->foreignId('created_by')->constrained('users');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
});
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('wages');
|
||||
}
|
||||
};
|
||||
Reference in new issue
Block a user