make(Illuminate\Contracts\Console\Kernel::class); $kernel->bootstrap(); use App\Models\User; use App\Models\AttendanceRecord; use App\Models\OvertimeApplication; // Find Dinh Chavez $user = User::where('name', 'like', '%Dinh Chavez%')->first(); if (!$user) { echo "Employee Dinh Chavez not found.\n"; exit; } echo "Found Employee: {$user->name} (ID: {$user->id})\n"; echo "=========================================\n"; // Get Attendance Records $startDate = '2026-06-10'; $endDate = '2026-06-25'; $attendanceRecords = AttendanceRecord::where('employee_id', $user->id) ->whereBetween('date', [$startDate, $endDate]) ->orderBy('date', 'asc') ->get(); echo "Attendance Records ({$startDate} to {$endDate}):\n"; if ($attendanceRecords->isEmpty()) { echo "No attendance records found.\n"; } else { foreach ($attendanceRecords as $record) { echo "- Date: {$record->date} | Status: {$record->status} | Clock In: {$record->clock_in} | Clock Out: {$record->clock_out} | OT Hours: {$record->overtime_hours} | Notes: {$record->notes}\n"; } } echo "=========================================\n"; // Get Overtime Applications $overtimeApps = OvertimeApplication::where('user_id', $user->id) ->whereBetween('date', [$startDate, $endDate]) ->orderBy('date', 'asc') ->get(); echo "Overtime Applications ({$startDate} to {$endDate}):\n"; if ($overtimeApps->isEmpty()) { echo "No overtime applications found.\n"; } else { foreach ($overtimeApps as $app) { echo "- Date: {$app->date} | Requested: {$app->hours}h | Approved: {$app->approved_hours}h | Status: {$app->status} | Reason: {$app->reason}\n"; } }