49 lines
1.1 KiB
PHP
49 lines
1.1 KiB
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class AttendanceSetting extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
/**
|
|
* The attributes that are mass assignable.
|
|
*
|
|
* @var list<string>
|
|
*/
|
|
protected $fillable = [
|
|
'checkin_start',
|
|
'checkin_end',
|
|
'checkout_start',
|
|
'late_grace_minutes',
|
|
'effective_workdays',
|
|
'timezone',
|
|
'allow_checkin_after_end',
|
|
'require_checkout',
|
|
'office_latitude',
|
|
'office_longitude',
|
|
'attendance_radius_meters',
|
|
];
|
|
|
|
/**
|
|
* Get the attributes that should be cast.
|
|
*
|
|
* @return array<string, string>
|
|
*/
|
|
protected function casts(): array
|
|
{
|
|
return [
|
|
'late_grace_minutes' => 'integer',
|
|
'effective_workdays' => 'array',
|
|
'allow_checkin_after_end' => 'boolean',
|
|
'require_checkout' => 'boolean',
|
|
'office_latitude' => 'float',
|
|
'office_longitude' => 'float',
|
|
'attendance_radius_meters' => 'integer',
|
|
];
|
|
}
|
|
}
|