completed story 1.1 with QA tests and fixes

This commit is contained in:
Naser Mansour
2025-12-26 13:46:39 +02:00
parent 028ce573b9
commit 84d9c2f66a
57 changed files with 2193 additions and 85 deletions
+34
View File
@@ -0,0 +1,34 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class WorkingHour extends Model
{
use HasFactory;
protected $fillable = [
'day_of_week',
'start_time',
'end_time',
'is_active',
];
protected function casts(): array
{
return [
'day_of_week' => 'integer',
'is_active' => 'boolean',
];
}
/**
* Scope to filter active working hours.
*/
public function scopeActive($query)
{
return $query->where('is_active', true);
}
}