<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class AttendanceEntry extends Model {
    protected $fillable=['attendance_session_id','member_id','full_name','nickname','organization_name','position','whatsapp','device_hash','latitude','longitude','distance_meters','photo_path','status','attended_at','ip_address','user_agent'];
    protected $casts=['attended_at'=>'datetime','latitude'=>'decimal:7','longitude'=>'decimal:7'];
    public function session(){ return $this->belongsTo(AttendanceSession::class,'attendance_session_id'); }
    public function member(){ return $this->belongsTo(Member::class); }
}
