@php $defaultAvatar = asset('storage/uploads/user-icon.png'); $punchFlag = fn (int $index, int $total) => match (true) { $index === 0 => __('In Time'), $index === $total - 1 && $total > 1 => __('Out Time'), $index % 2 === 0 => __('In Time'), default => __('Out Time'), }; $punchClass = fn (int $index, int $total) => match (true) { $index === 0, $index % 2 === 0 => 'in', default => 'out', }; @endphp @extends('admin.layouts.app') @section('title', get_setting('site_name').' | Attendance History') @section('content')
Raw punch logs from devices — grouped by day for each employee.
Choose staff and date range, then click Filter to load punch history.
| # | Time | Flag | Device | Location / Remarks |
|---|---|---|---|---|
| {{ date('d M Y, l', strtotime($day)) }} | ||||
| {{ $index + 1 }} | {{ date('h:i A', strtotime($punch->timestamp)) }} | {{ $punchFlag($index, $punches->count()) }} | {{ $punch->devices ?: '—' }} | {{ trim(($punch->location ?: '').' '.($punch->remarks ?: '')) ?: '—' }} |
| No punch records in this range. | ||||