$error = 'Successfully saved your timesheet... '; if ($forWhichUID == 0 || $forWhichUID == $_USER['uid']) { $output = generateTimesheet(); } else { $output = generateTimesheet($forWhichUID, false, true, $forWhichUID); } } else { $error = 'There is an error in your timesheet - ensure all numeric fields are filled with numeric data!...'; $output = ''; } break; case 'lockentries': $datestamp = COM_applyFilter($_REQUEST['datestamp'], true); $emp = COM_applyFilter($_REQUEST['emp'], true); $ts = new nexTime(); $ts->lockTimesheetEntries($datestamp, $emp); if ($emp == $_USER['uid']) { $output = generateTimesheet($emp); } else { $output = generateTimesheet($_USER['uid'], false, true, $emp); } //$output=generateTimesheet($emp); $error = 'Successfully locked your timesheet entry...'; break; case 'unlockentries': $datestamp = COM_applyFilter($_REQUEST['datestamp'], true); $emp = COM_applyFilter($_REQUEST['emp'], true); $ts = new nexTime(); $ts->unlockTimesheetEntries($datestamp, $emp); if ($emp == $_USER['uid']) { $output = generateTimesheet($emp);