Added week start

This commit is contained in:
Constantin Graf
2024-03-21 13:53:05 +01:00
parent fb04cff7c1
commit fc5b35661d
15 changed files with 364 additions and 67 deletions

View File

@@ -4,6 +4,7 @@ declare(strict_types=1);
namespace App\Models;
use App\Enums\Weekday;
use Database\Factories\UserFactory;
use Filament\Panel;
use Illuminate\Database\Eloquent\Builder;
@@ -27,6 +28,7 @@ use Laravel\Passport\HasApiTokens;
* @property string|null $password
* @property string $timezone
* @property bool $is_placeholder
* @property Weekday $week_start
* @property Collection<Organization> $organizations
* @property Collection<TimeEntry> $timeEntries
*
@@ -79,6 +81,16 @@ class User extends Authenticatable
'email_verified_at' => 'datetime',
'is_admin' => 'boolean',
'is_placeholder' => 'boolean',
'week_start' => Weekday::class,
];
/**
* The model's default values for attributes.
*
* @var array<string, mixed>
*/
protected $attributes = [
'week_start' => Weekday::Monday,
];
/**