public static function addMenu($menuItemArray) { echo "<div id=\"menu\">\n<table>\n"; // always have a logout Menu::addMenuItem(MENU_LOGOUT); for ($k = 0; $k < count($menuItemArray); $k++) { Menu::addMenuItem($menuItemArray[$k]); } // $k // always able to see self's schedule $author = getWorkerAuthenticated(); $worker = getWorkerCurrent(); $expo = getExpoCurrent($author->workerid); $station = getStationCurrent($author->workerid); if (is_null($worker)) { $worker = $author; } if ($author->isOrganizer() || $author->isSupervisor()) { # Menu::addMenuItem(MENU_WORKER_MESSAGE); if (!is_null($expo)) { if (strpos($_SERVER['SCRIPT_URL'], "ShiftCheckInPage.php")) { Menu::addMenuItem(MENU_EXPO_CHECKIN_CLIENT); } else { if (!strpos($_SERVER['SCRIPT_URL'], "ExpoCheckInPage.php")) { if (!is_null($station)) { Menu::addMenuItem(MENU_CHECKIN_CLIENT); } else { Menu::addMenuItem(MENU_EXPO_CHECKIN_CLIENT); } } } } } if (!is_null($expo)) { if (!strpos($_SERVER['SCRIPT_URL'], Menu::$MENU_ACTION_ARRAY[MENU_VIEW_EXPOCURRENT])) { Menu::addMenuItem(MENU_VIEW_EXPOCURRENT); } Menu::addMenuItem(MENU_VIEW_SCHEDULE, !$expo->scheduleVisible); } Menu::addMenuItem(MENU_VIEW_WORKER); echo "</table>\n</div><!-- menu -->\n"; return; }
document.ShiftCheckIn_form.submit(); return; } </script> </head> <body> <div id="container"> <?php $expo = getExpoCurrent(); if (isset($_REQUEST[PARAM_LIST_INDEX])) { $station = StationJob::selectID($_REQUEST[PARAM_LIST_INDEX]); setStationCurrent($station); } else { $station = getStationCurrent(); } // ok, start the html include 'section/header.php'; ?> <div id="main"> <?php include 'section/LinkStation.php'; ?> <div id="checkinclient_workerlist"> <?php createShiftCheckInHTMLList($expo->expoid, $station->stationid); ?> </div><!-- checkinclient_workerlist -->
require_once 'util/session.php'; ?> <div id="LinkJob"> <table> <tr> <td><h5 style="margin:0">Expo</h5></td> <td class="fieldLink"><a href="ExpoViewPage.php"><?php echo getExpoCurrent()->titleString(); ?> </a></td> </tr> <tr> <td><h5 style="margin:0">Station</h5></td> <td class="fieldLink"><a href="StationViewPage.php"><?php echo getStationCurrent()->titleString(); ?> </a></td> </tr> <tr> <td><h5 style="margin:0">Job</h5></td> <!-- note this could be a drop-down or an <a>getJobCurrent</a> depending --> <td class="fieldLink"><?php echo getStationCurrent()->jobTitleString(); ?> </td> </tr> </table> </div> <br />
if (!is_null($to) && strlen($to) > 0) { FormMail::send($to, $subject, $message); } else { /* continue to process list */ logMessage("SendMessageAction", "failure with to field:" . $to . " index:" . $k . " value:" . $list[$k]); } } catch (ParseSWWATException $pe) { /* continue to process list */ logMessage("SendMessageAction", "failure with index:" . $k . " value:" . $list[$k]); } } // $k } // all null // return to whence we came if (is_null(getStationCurrent())) { if (is_null(getExpoCurrent())) { if (is_null(getWorkerCurrent())) { header('Location: WorkerListPage.php'); include 'WorkerListPage.php'; return; } else { header('Location: WorkerViewPage.php'); include 'WorkerViewPage.php'; return; } } else { header('Location: ExpoViewPage.php'); include 'ExpoViewPage.php'; return; }
require_once 'db/StationJob.php'; require_once 'util/session.php'; ?> <div id="LinkStation"> <table> <tr> <td><h5 style="margin:0">Expo</h5></td> <td class="fieldLink"><a href="ExpoViewPage.php"><?php echo getExpoCurrent()->titleString(); ?> </a></td> </tr> <tr> <td><h5 style="margin:0">Station</h5></td> <td class="fieldLink"><a href="StationViewPage.php"><?php echo getStationCurrent()->titleString(); ?> </a></td> </tr> <tr> <td><h5 style="margin:0">Staff</h5></td> <td class="fieldLink"><a href="WorkerViewPage.php"><?php echo getWorkerCurrent()->nameString(); ?> </a></td> </tr> </table> </div> <br />
{ // note we presume PARAM_LIST_MULTIPLE == 'list_index[]' move(document.shiftassignpage_form.elements['list_index[]'], document.shiftassignpage_form.ignored); } // sendLeft </script> </head> <body> <div id="container"> <?php $expo = getExpoCurrent(); // must have clicked a button to be 2nd time through $firstTimeThrough = !(isset($_REQUEST["add"]) || isset($_REQUEST["remove"]) || isset($_REQUEST["save"])); $job = getStationCurrent(); // note this only works (StationJob not Station) for CIW where station:job == 1:1 if ($firstTimeThrough) { // now go get the workers $workerList = Worker::selectStation($job->stationid); // now go to the non-workers! $workerOutList = Worker::selectNotStation($expo->expoid, $job->stationid); $oddWorkerList = array(); // but unfilled } else { $workerList = getSelectList(); $oddWorkerList = $job->oddWorkerList($workerList); // use REQUEST as may be a GET if (isset($_REQUEST["save"])) { $assignment = new ShiftAssignment(); // can re-use several times