function makeCheckInWorkerDashboardListHTMLRows2(Worker $w, $expoid) { echo "<tr>\n"; echo "<td class=\"fieldValueFirst\">" . htmlspecialchars($w->nameString()) . "</td>\n"; echo "<td class=\"fieldValue\">" . htmlspecialchars($w->email) . "</td>\n"; echo "<td class=\"fieldValue\">" . swwat_format_phone($w->phone) . "</td>\n"; $ss = ShiftStatus::mostRecentStatusWorker($w->workerid, $expoid); echo "<td class=\"fieldValue\">"; if (!is_null($ss)) { $s = StationJob::selectID($ss->stationid); echo $s->location . " (" . $s->title . ")"; } else { echo "-"; } echo "</td>\n"; echo "<td class=\"fieldValue\">"; if (!is_null($ss)) { if ($ss->statusType == "CHECK_IN") { echo "<div style=\"color: red\">Checked In</div>"; } else { if ($ss->statusType == "CHECK_OUT") { echo "<div style=\"color: green\">Checked Out</div>"; } } } else { echo "Never checked in"; } echo "</td>\n"; echo "<td class=\"fieldValue\">"; if (!is_null($ss)) { $hours = ShiftStatus::WorkerHours($w->workerid, $expoid); if (is_int($hours)) { echo $hours; } else { echo sprintf('%.2f', $hours); } } else { echo "-"; } echo "</td>\n"; echo "</tr>\n"; }