protected function getConfirmEmailInfo($regID) { $infoArray = array(); $email = ''; $admEmail = ''; $confirmNum = ''; $person_fname = ''; $person_lname = ''; $campus_name = ''; $event_name = ''; $confirm_text = ''; // determine if parameter has been set if (isset($regID)) { // get admin's e-mail $viewers = new RowManager_ViewerManager(); $viewers->setID($this->viewer->getViewerID()); $view_person = new RowManager_AccessManager(); $person = new RowManager_PersonManager(); $viewerInfo = new MultiTableManager(); $viewerInfo->addRowManager($viewers); $viewerInfo->addRowManager($view_person, new JoinPair($viewers->getJoinOnViewerID(), $view_person->getJoinOnViewerID())); $viewerInfo->addRowManager($person, new JoinPair($person->getJoinOnPersonID(), $view_person->getJoinOnPersonID())); $personInfoList = $viewerInfo->getListIterator(); $personInfoArray = $personInfoList->getDataList(); // echo "<pre>".print_r($personInfoArray,true)."</pre>"; $person_id = ''; reset($personInfoArray); foreach (array_keys($personInfoArray) as $k) { $record = current($personInfoArray); $admEmail = $record['person_email']; // NOTE: should only be one person per viewer ID (ENFORCE??) next($personInfoArray); } $infoArray['adminEmail'] = $admEmail; // get registration info for in confirmation e-mail (and get registrant's e-mail address) $regs = new RowManager_RegistrationManager(); $regs->setRegID($regID); $people = new RowManager_PersonManager(); $assign = new RowManager_AssignmentsManager(); $campus = new RowManager_CampusManager(); $event = new RowManager_EventManager(); $personRegs = new MultiTableManager(); $personRegs->addRowManager($people); $personRegs->addRowManager($regs, new JoinPair($regs->getJoinOnPersonID(), $people->getJoinOnPersonID())); $personRegs->addRowManager($assign, new JoinPair($people->getJoinOnPersonID(), $assign->getJoinOnPersonID())); $personRegs->addRowManager($campus, new JoinPair($assign->getJoinOnCampusID(), $campus->getJoinOnCampusID())); $personRegs->addRowManager($event, new JoinPair($regs->getJoinOnEventID(), $event->getJoinOnEventID())); $personList = $personRegs->getListIterator(); $personArray = $personList->getDataList(); // echo "<pre>".print_r($personArray,true)."</pre>"; reset($personArray); foreach (array_keys($personArray) as $k) { $person = current($personArray); $email = $person['person_email']; $person_fname = $person['person_fname']; // NOTE: should only be one person per registration (ENFORCE??) $person_lname = $person['person_lname']; $campus_name = $person['campus_desc']; $confirmNum = $person['registration_confirmNum']; $event_name = $person['event_name']; $confirm_text = $person['event_emailConfirmText']; $event_basePrice = $person['event_basePrice']; $event_contactEmail = $person['event_contactEmail']; next($personArray); } $infoArray['event_email'] = $event_contactEmail; $infoArray['email'] = $email; $infoArray['person_fname'] = $person_fname; $infoArray['person_lname'] = $person_lname; $infoArray['campus_name'] = $campus_name; $infoArray['confirmNum'] = $confirmNum; $infoArray['event_name'] = $event_name; $infoArray['confirm_text'] = $confirm_text; $infoArray['event_basePrice'] = $event_basePrice; } return $infoArray; //$email.','.$event_name.','.$confirmNum.','.$event_basePrice.','.$person_fname.','.$person_lname.','.$campus_desc.','.$admEmail; }