31 lines
587 B
PHP
31 lines
587 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
|
|
|
class Attendance extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
protected $fillable = [
|
|
'employee_id',
|
|
'date',
|
|
'check_in',
|
|
'check_out',
|
|
'latitude_in',
|
|
'longitude_in',
|
|
'latitude_out',
|
|
'longitude_out',
|
|
'status',
|
|
'notes',
|
|
];
|
|
|
|
public function employee(): BelongsTo
|
|
{
|
|
return $this->belongsTo(Employee::class);
|
|
}
|
|
}
|