fix hanging
This commit is contained in:
@@ -835,8 +835,17 @@ class AttendanceRecordController extends Controller
|
||||
$status = 'H';
|
||||
$label = 'Half Day';
|
||||
} else if ($record->status === 'present') {
|
||||
$status = 'P';
|
||||
$label = 'Present';
|
||||
// Only show P if they actually clocked in/out, otherwise show A for data integrity
|
||||
if (!empty($record->clock_in) && !empty($record->clock_out)) {
|
||||
$status = 'P';
|
||||
$label = 'Present';
|
||||
} else if (!empty($record->clock_in)) {
|
||||
$status = 'P';
|
||||
$label = 'Present (Clocked In Only)';
|
||||
} else {
|
||||
$status = 'A';
|
||||
$label = 'Marked Present (No times recorded)';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user