function view($lPledgeID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- global $gdteNow, $gclsChapterACO, $gbDateFormatUS; if (!bTestForURLHack('showFinancials')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($this, $lPledgeID, 'pledge ID'); $displayData = array(); $displayData['lPledgeID'] = $lPledgeID = (int) $lPledgeID; $displayData['js'] = ''; // load models $params = array('enumStyle' => 'terse'); $this->load->library('generic_rpt', $params); $this->load->helper('dl_util/web_layout'); // $this->load->helper ('dl_util/email_web'); $this->load->helper('gifts/pledge'); $this->load->model('admin/madmin_aco', 'clsACO'); $this->load->model('people/mpeople', 'clsPeople'); $this->load->model('biz/mbiz', 'clsBiz'); $this->load->model('donations/maccts_camps', 'clsAC'); $this->load->model('donations/mpledges', 'clsPledges'); $this->load->model('donations/mdonations', 'clsGifts'); $this->load->helper('js/div_hide_show'); $displayData['js'] .= showHideDiv(); $this->clsPledges->loadPledgeViaPledgeID($lPledgeID); $displayData['pledge'] = $pledge =& $this->clsPledges->pledges[0]; $displayData['lFID'] = $lFID = $pledge->lForeignID; $bPeople = !$pledge->bBiz; $displayData['pledge']->curTotFulfill = $this->clsPledges->curTotalFulfillmentViaPledgeID($pledge->lKeyID, $pledge->lACOID); $this->clsPledges->pledgeSchedule($pledge, $displayData['schedule']); $this->clsPledges->curFillmentViaPledgeID($pledge->lKeyID, $pledge->lACOID, $this->clsGifts); //------------------------------------------------ // stripes //------------------------------------------------ $this->load->model('util/mbuild_on_ready', 'clsOnReady'); $this->clsOnReady->addOnReadyTableStripes(); $this->clsOnReady->closeOnReady(); $displayData['js'] .= $this->clsOnReady->strOnReady; //-------------------------- // breadcrumbs //-------------------------- $displayData['mainTemplate'] = 'donations/pledge_record_view'; if ($bPeople) { $displayData['pageTitle'] = anchor('main/menu/people', 'People', 'class="breadcrumb"') . ' | ' . anchor('people/people_record/view/' . $lFID, 'Record', 'class="breadcrumb"') . ' | View Pledge Record'; $this->clsPeople->loadPeopleViaPIDs($lFID, false, false); $displayData['contextSummary'] = $this->clsPeople->peopleHTMLSummary(0); } else { $displayData['pageTitle'] = anchor('main/menu/biz', 'Businesses/Organizations', 'class="breadcrumb"') . ' | ' . anchor('biz/biz_record/view/' . $lFID, 'Record', 'class="breadcrumb"') . ' | View Pledge Record'; $this->clsBiz->loadBizRecsViaBID($lFID); $displayData['contextSummary'] = $this->clsBiz->strBizHTMLSummary(0); } $displayData['title'] = CS_PROGNAME . ' | Pledges'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $this->load->vars($displayData); $this->load->view('template'); }
function setActiveState($lPatientID, $bSetToActive) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- global $glChapterID; global $gbVolMgr, $glChapterID; if (!bTestForURLHack('volMgr')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($glChapterID, $lPatientID, 'patient ID'); $lPatientID = (int) $lPatientID; $bSetToActive = $bSetToActive == 'true'; //------------------------------------------------ // models, libraries and utilities //------------------------------------------------ $this->load->model('patients/mpatients', 'cPatients'); // load patient record $this->cPatients->loadPatientsViaPatientID($lPatientID); $pRec =& $this->cPatients->patients[0]; $strDirLetter = strtoupper(substr($pRec->strLName, 0, 1)); $this->cPatients->updateActiveStatus($lPatientID, $bSetToActive); $this->session->set_flashdata('msg', 'The patient record for <b>' . htmlspecialchars($pRec->strFName . ' ' . $pRec->strLName) . '</b> was set to <b>' . ($bSetToActive ? 'active' : 'inactive') . '</b>.'); redirect('hospice/patients/patient_directory/view/Y/' . $strDirLetter); }
function addNewClientS2($lClientID, $lLocID, $lStatCatID, $lVocID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- if (!bTestForURLHack('showClients')) { return; } $this->load->helper('dl_util/verify_id'); verifyIDsViaType($this, CENUM_CONTEXT_CLIENT, $lClientID, true); verifyID($this, $lLocID, 'client location ID'); verifyID($this, $lStatCatID, 'status category ID'); verifyID($this, $lVocID, 'client vocabulary ID'); $lClientID = (int) $lClientID; $lLocID = (int) $lLocID; $lStatCatID = (int) $lStatCatID; $lVocID = (int) $lVocID; $this->load->library('util/dl_date_time', '', 'clsDateTime'); $this->load->model('clients/mclients', 'clsClients'); $this->clsClients->loadClientsViaClientID($lClientID); $client = $this->clsClients->clients[0]; $client->lLocationID = $lLocID; $client->lStatusCatID = $lStatCatID; $client->lVocID = $lVocID; $this->addEditClient($lClientID, $this->clsClients); }
private function addEditCommon($bEnroll, $lFID, $lClientID, $lCProgID, $lERecID = null, $bUseReturnPath = false) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- if (!bTestForURLHack('showClients')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($this, $lClientID, 'client ID'); verifyID($this, $lCProgID, 'client program ID'); $lFID = (int) $lFID; $lClientID = (int) $lClientID; $lCProgID = (int) $lCProgID; //------------------------- // models & helpers //------------------------- $this->load->model('client_features/mcprograms', 'cprograms'); $this->load->model('personalization/muser_fields', 'clsUF'); $this->load->model('admin/mpermissions', 'perms'); $this->load->helper('img_docs/image_doc'); // load the client program $this->cprograms->loadClientProgramsViaCPID($lCProgID); $cprog =& $this->cprograms->cprogs[0]; if ($bEnroll) { $lTableID = $cprog->lEnrollmentTableID; } else { $lTableID = $cprog->lAttendanceTableID; } redirect('admin/uf_multirecord/addEditMultiRecord/' . $lTableID . '/' . $lClientID . '/' . $lFID . '/' . (is_null($lERecID) ? '0' : $lERecID) . '/' . ($bUseReturnPath ? 'true' : 'false')); }
function mgrViewLog($lUserID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- $this->load->helper('dl_util/verify_id'); verifyID($this, $lUserID, 'user ID'); $lUserID = (int) $lUserID; $displayData = array(); $displayData['js'] = ''; $this->load->helper('dl_util/permissions'); // in autoload if (!bAllowAccess('management')) { return ''; } $displayData['lUserID'] = $lUserID = (int) $lUserID; //------------------------------------- // models, libraries, and helpers //------------------------------------- $this->load->model('staff/mstaff_status', 'cstat'); $this->load->model('admin/muser_accts', 'clsUser'); $this->load->model('admin/mpermissions', 'perms'); $this->load->helper('dl_util/web_layout'); $this->load->helper('staff/link_staff'); $this->load->helper('staff/status_report'); // load the current user's record $this->clsUser->loadSingleUserRecord($lUserID); $displayData['uRec'] = $uRec =& $this->clsUser->userRec[0]; $this->cstat->loadStatusReportViaUserID($lUserID); $displayData['lNumSReports'] = $lNumSReports = $this->cstat->lNumSReports; $displayData['sreports'] = $sreports =& $this->cstat->sreports; // $displayData['bReviewedByTheMan'] = false; // load the reviews for this status report if ($lNumSReports > 0) { foreach ($sreports as $srpt) { $lRptID = $srpt->lKeyID; $srpt->bReviewedByTheMan = false; $this->cstat->loadReviewsViaRptID($lRptID, $srpt->lNumReviews, $srpt->reviewLog); if ($srpt->lNumReviews > 0) { foreach ($srpt->reviewLog as $rlog) { if ($rlog->lReviewerID == $lUserID) { $srpt->bReviewedByTheMan = true; break; } } } } } //-------------------------- // breadcrumbs //-------------------------- $displayData['pageTitle'] = anchor('aayhf/main/aayhfMenu', 'AAYHF', 'class="breadcrumb"') . ' | ' . anchor('staff/mgr_performance/review', 'Status Report Review', 'class="breadcrumb"') . ' | Status Log for ' . $uRec->strSafeName; $displayData['title'] = CS_PROGNAME . ' | Status Report Review'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $displayData['mainTemplate'] = 'aayhf/aayhf_staff/mgr_status_staff_log_view'; $this->load->vars($displayData); $this->load->view('template'); }
function viewRec($lVolID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- global $gbVolMgr, $glChapterID, $gstrFormatDatePicker, $gbDateFormatUS; global $glUserID, $gbVolLogin; $this->load->helper('dl_util/verify_id'); verifyID($glChapterID, $lVolID, 'volunteer ID'); $displayData = array(); $displayData['lVolID'] = $lVolID = (int) $lVolID; $displayData['js'] = ''; $displayData['formData'] = new stdClass(); //------------------------------------------------ // models, libraries and utilities //------------------------------------------------ $this->load->model('vols/mvol', 'cVol'); $this->load->model('vols/mvol_training', 'cvt'); $this->load->model('hospice/mhospice_pvisit', 'cPVisit'); $this->load->model('admin/mpermissions', 'perms'); $this->load->model('admin/muser_accts', 'cusers'); $this->load->helper('dl_util/web_layout'); $this->load->helper('dl_util/time_date'); $this->load->helper('hospice/link_hospice'); $this->load->library('util/dl_date_time', '', 'clsDateTime'); $this->load->helper('js/div_hide_show'); $displayData['js'] .= showHideDiv(); //------------------------------------------------ // stripes //------------------------------------------------ $this->load->model('util/mbuild_on_ready', 'clsOnReady'); $this->clsOnReady->addOnReadyTableStripes(); $this->clsOnReady->closeOnReady(); $displayData['js'] .= $this->clsOnReady->strOnReady; // load volunteer record $this->cVol->loadVolRecsViaVolID($lVolID, true); $displayData['volRec'] = $volRec =& $this->cVol->volRecs[0]; // associated patient contacts $this->cVol->loadVolClientAssocViaVolID($lVolID, $displayData['volClient'], true); // vol stats $this->cPVisit->loadVolActivityStats($lVolID, $displayData['volStats']); // vol training $this->cvt->loadVolTrainingViaVID($lVolID, $displayData['lNumTraining'], $displayData['training']); //-------------------------- // breadcrumbs //-------------------------- $params = array('enumStyle' => 'terse'); $this->load->library('generic_rpt', $params, 'generic_rpt'); $displayData['clsRpt'] = $this->generic_rpt; $displayData['pageTitle'] = 'Volunteer Record'; $displayData['title'] = CS_PROGNAME . ' | Volunteer'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $displayData['mainTemplate'] = 'hospice/vols/volunteer_rec_view'; $this->load->vars($displayData); $this->load->view('template'); }
function viewEntry($lDepositID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- if (!bTestForURLHack('showFinancials')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($this, $lDepositID, 'deposit ID'); $displayData = array(); $displayData['lDepositID'] = $lDepositID = (int) $lDepositID; // models/helpers $this->load->helper('dl_util/web_layout'); $this->load->model('admin/madmin_aco', 'clsACO'); $this->load->model('financials/mdeposits', 'clsDeposits'); $this->load->model('donations/mdonations', 'clsGifts'); //------------------------------------------------ // stripes //------------------------------------------------ $this->load->model('util/mbuild_on_ready', 'clsOnReady'); $this->clsOnReady->addOnReadyTableStripes(); $this->clsOnReady->closeOnReady(); $displayData['js'] = $this->clsOnReady->strOnReady; $this->clsDeposits->strWhereExtra = " AND dl_lKeyID = {$lDepositID} "; $this->clsDeposits->loadDepositReports(); $displayData['deposit'] = $this->clsDeposits->deposits[0]; $displayData['lNumGifts'] = $this->clsDeposits->lNumGiftsViaDeposit($lDepositID, $curTot); $displayData['curTot'] = $curTot; $this->clsDeposits->loadGroupedDepositReportsViaDepositID((int) $lDepositID); $displayData['lNumDepositSummary'] = $lNumDepositSummary = $this->clsDeposits->lNumDepositSummary; $displayData['depositSummary'] =& $this->clsDeposits->depositSum; $displayData['reportID'] = $this->strExportID($lDepositID); // load gifts based on payment type if ($lNumDepositSummary > 0) { $displayData['gifts'] = array(); $idx = 0; foreach ($this->clsDeposits->depositSum as $dep) { $displayData['gifts'][$idx] = new stdClass(); $gInfo =& $displayData['gifts'][$idx]; $gInfo->safePayType = $dep->strSafePaymentType; $this->clsDeposits->loadGiftsViaDIDPayID($lDepositID, $dep->lPaymentType, $gInfo->lNumGifts, $gInfo->gifts); ++$idx; } } //-------------------------- // breadcrumbs //-------------------------- $displayData['pageTitle'] = anchor('main/menu/financials', 'Financials/Grants', 'class="breadcrumb"') . ' | ' . anchor('financials/deposit_log/view', 'Deposit Log', 'class="breadcrumb"') . ' | Deposit Record'; $displayData['title'] = CS_PROGNAME . ' | Financials'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $displayData['mainTemplate'] = 'financials/deposit_record_view'; $this->load->vars($displayData); $this->load->view('template'); }
public function view($lPPTestID) { //------------------------------------------------------------------------- // //------------------------------------------------------------------------- if (!bTestForURLHack('showClients')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($this, $lPPTestID, 'pre/post test ID'); $displayData = array(); $displayData['js'] = ''; $displayData['lPPTestID'] = $lPPTestID = (int) $lPPTestID; //------------------------- // models & helpers //------------------------- $this->load->model('client_features/mcpre_post_tests', 'cpptests'); $this->load->model('admin/mpermissions', 'perms'); $this->load->model('groups/mgroups', 'groups'); $this->load->helper('dl_util/web_layout'); $this->load->helper('clients/link_client_features'); $this->load->helper('dl_util/record_view'); $this->load->helper('img_docs/link_img_docs'); $this->load->helper('personalization/ptable'); $this->load->helper('groups/groups'); $params = array('enumStyle' => 'terse', 'clsRpt'); $this->load->library('generic_rpt', $params); $this->load->helper('js/div_hide_show'); $displayData['js'] .= showHideDiv(); // load the Pre/Post test $this->cpptests->loadPPTestsViaPPTID($lPPTestID); $displayData['pptest'] = $pptest =& $this->cpptests->pptests[0]; $displayData['lNumQuests'] = $this->cpptests->lNumQuestsViaPPTID($lPPTestID); //------------------------------- // permission groups //------------------------------- $this->groups->groupMembershipViaFID(CENUM_CONTEXT_CPREPOST, $lPPTestID); $displayData['pdgroup'] = new stdClass(); $pdgroup =& $displayData['pdgroup']; $pdgroup->inGroups =& $this->groups->arrMemberInGroups; $pdgroup->lCntGroupMembership = $this->groups->lNumMemInGroups; $pdgroup->lNumGroups = $this->groups->lCntActiveGroupsViaType(CENUM_CONTEXT_CPREPOST); $this->groups->loadActiveGroupsViaType(CENUM_CONTEXT_CPREPOST, 'groupName', $this->groups->strMemListIDs, false, null); $pdgroup->groupList = $this->groups->arrGroupList; //-------------------------- // breadcrumbs //-------------------------- $displayData['pageTitle'] = anchor('main/menu/client', 'Clients', 'class="breadcrumb"') . ' | ' . anchor('cpre_post_tests/pptests/overview', 'Client Pre/Post Tests', 'class="breadcrumb"') . ' | ' . htmlspecialchars($pptest->strTestName); $displayData['title'] = CS_PROGNAME . ' | Clients'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $displayData['mainTemplate'] = 'cpre_post_tests/pp_record_view'; $this->load->vars($displayData); $this->load->view('template'); }
public function viewQuestions($lPPTestID) { //------------------------------------------------------------------------- // //------------------------------------------------------------------------- global $glUserID; /*---------------------------- echo(__FILE__.' '.__LINE__.'<br>'."\n"); $this->output->enable_profiler(TRUE); //----------------------------- */ if (!bTestForURLHack('showClients')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($this, $lPPTestID, 'pre/post test ID'); $displayData = array(); $displayData['js'] = ''; //------------------------- // models & helpers //------------------------- $this->load->model('client_features/mcpre_post_tests', 'cpptests'); $this->load->model('admin/mpermissions', 'perms'); $this->load->helper('clients/link_client_features'); $this->load->library('util/up_down_top_bottom'); $params = array('enumStyle' => 'terse'); $this->load->library('generic_rpt', $params); //-------------------------- // Stripes //-------------------------- $this->load->model('util/mbuild_on_ready', 'clsOnReady'); $this->clsOnReady->addOnReadyTableStripes(); $this->clsOnReady->closeOnReady(); $displayData['js'] .= $this->clsOnReady->strOnReady; //------------------------- // load the pre/post test //------------------------- $this->cpptests->loadPPTestsViaPPTID($lPPTestID); $displayData['pptest'] = $pptest =& $this->cpptests->pptests[0]; //------------------------- // load the questions //------------------------- $this->cpptests->loadQuestionsViaPPTID($lPPTestID); $displayData['quests'] = $quests =& $this->cpptests->questions; $displayData['lNumQuestions'] = $this->cpptests->lNumQuestions; $displayData['strTestSummary'] = $this->cpptests->strHTMLPPTestSummaryDisplay(); //-------------------------- // breadcrumbs //-------------------------- $displayData['pageTitle'] = anchor('main/menu/client', 'Clients', 'class="breadcrumb"') . ' | ' . anchor('cpre_post_tests/pptests/overview', ' Client Pre/Post Tests', 'class="breadcrumb"') . ' | ' . anchor('cpre_post_tests/pptest_record/view/' . $lPPTestID, htmlspecialchars($pptest->strTestName), 'class="breadcrumb"') . ' | Questions'; $displayData['title'] = CS_PROGNAME . ' | Client Pre/Post Tests'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $displayData['mainTemplate'] = 'cpre_post_tests/questions_list_view'; $this->load->vars($displayData); $this->load->view('template'); }
function bidsheetViaPID($lBSID, $lPackageID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- global $gpdf; if (!bTestForURLHack('showAuctions')) { return; } $gpdf = new stdClass(); $gpdf->bItemLayoutInProcess = false; // are we spliting the items across multiple pages? $this->load->helper('dl_util/verify_id'); verifyID($this, $lBSID, 'bidsheet ID'); verifyID($this, $lPackageID, 'package ID'); //----------------------------- // models and helpers //----------------------------- $this->load->helper('dl_util/pdf'); $this->load->model('auctions/mbid_sheet_pdf', 'cBSPDF'); $this->load->model('auctions/mbid_sheets', 'cBidSheets'); $this->load->model('auctions/mpackages', 'cPackages'); $this->load->model('auctions/mitems', 'cItems'); $this->load->model('img_docs/mimage_doc', 'clsImgDoc'); $this->load->helper('img_docs/image_doc'); $this->load->helper('img_docs/link_img_docs'); $this->load->helper('auctions/auction'); $this->cBidSheets->loadSheetByBSID($lBSID); $bs = $gpdf->bs =& $this->cBidSheets->bidSheets[0]; $this->cPackages->loadPackageByPacID($lPackageID); $this->cPackages->loadPackageProfileImage(); $package = $gpdf->package =& $this->cPackages->packages[0]; $package->curEstValue = $this->cItems->curEstValueViaPID($lPackageID); $this->cItems->loadItemsViaPackageID($lPackageID); $gpdf->items =& $this->cItems->items; $gpdf->lNumItems = $this->cItems->lNumItems; $this->cItems->loadItemProfileImage(); $pdf = new bsPDF('Portrait', 'pt', $bs->enumPaperType); $pdf->SetAutoPageBreak(true, 50); $pdf->AliasNbPages(); $pdf->AddPage(); $pdf->createBidSheet(); $pdf->SetFont('Arial', '', 12); $lNumExtra = $bs->lNumSignupPages; if ($lNumExtra > 0 && $bs->bIncludeSignup) { for ($idx = 0; $idx < $lNumExtra; ++$idx) { $pdf->AddPage(); $pdf->addSignUpColumns($gpdf->lTopMargin); } } $pdf->Output('package_' . str_pad($package->lKeyID, 5, '0', STR_PAD_LEFT) . '.pdf', 'I'); }
function viaLocationID($lLocID, $bShowInactive = false) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- $this->load->helper('dl_util/verify_id'); verifyID($this, $lLocID, 'client location ID'); $this->load->model('reports/mreports', 'clsReports'); $reportAttributes = array('rptType' => CENUM_REPORTTYPE_PREDEFINED, 'rptName' => CENUM_REPORTNAME_SPONVIALOCID, 'rptDestination' => CENUM_REPORTDEST_SCREEN, 'lStartRec' => 0, 'lRecsPerPage' => 50, 'bShowRecNav' => true, 'viewFile' => 'pre_basic_sponsor_list_view', 'bShowInactive' => $bShowInactive, 'lLocID' => $lLocID); $this->clsReports->createReportSessionEntry($reportAttributes); $reportID = $this->clsReports->sRpt->reportID; redirect('reports/reports/run/' . $reportID); }
public function viewDates($lDateID) { //------------------------------------------------------------------------- // //------------------------------------------------------------------------- $this->load->helper('dl_util/verify_id'); verifyID($this, $lDateID, 'event date ID'); $displayData = array(); $displayData['lDateID'] = $lDateID = (int) $lDateID; //------------------------------------------------ // libraries / models / utilities //------------------------------------------------ $params = array('enumStyle' => 'terse'); $this->load->library('generic_rpt', $params); $this->load->model('vols/mvol_event_dates', 'clsVolEventDates'); $this->load->model('vols/mvol_events', 'clsVolEvents'); $this->load->model('vols/mvol_event_dates_shifts', 'clsShifts'); $this->load->model('vols/mvol_event_dates_shifts_vols', 'clsSV'); $this->load->model('vols/mvol_event_hours', 'clsVolHours'); $this->load->helper('dl_util/web_layout'); $this->load->helper('dl_util/time_date'); $this->clsVolEventDates->loadEventDateViaDateID($lDateID); $displayData['edate'] = $edate =& $this->clsVolEventDates->dates[0]; $displayData['lEventID'] = $lEventID = $edate->lVolEventID; $this->clsVolEvents->loadEventsViaEID($lEventID); $displayData['contextSummary'] = $this->clsVolEvents->volEventHTMLSummary(0); $displayData['lNumEventDates'] = $lNumEventDates = $this->clsVolEventDates->lNumDatesViaEventID($lEventID); $this->clsShifts->loadShiftsViaEventDateID($lDateID); $displayData['lNumShifts'] = $lNumShifts = $this->clsShifts->lNumShifts; $displayData['lNumVolsTot'] = 0; if ($lNumShifts > 0) { foreach ($this->clsShifts->shifts as $shift) { $lShiftID = $shift->lKeyID; $this->clsSV->loadVolsViaShiftID($lShiftID); $shift->lNumVols = $this->clsSV->lNumVols; $displayData['lNumVolsTot'] += $shift->lNumVols; $shift->vols = $this->clsSV->vols; $shift->hoursLogged = $this->clsVolHours->dTotHoursWorkedViaShiftID($lShiftID); } } $displayData['shifts'] =& $this->clsShifts->shifts; //-------------------------- // breadcrumbs //-------------------------- $displayData['pageTitle'] = anchor('main/menu/vols', 'Volunteers', 'class="breadcrumb"') . ' | ' . anchor('volunteers/events_schedule/viewEventsList', 'Event List', 'class="breadcrumb"') . ' | ' . anchor('volunteers/events_record/viewEvent/' . $lEventID, 'Event', 'class="breadcrumb"') . ' | Event Date'; $displayData['title'] = CS_PROGNAME . ' | Volunteers'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $displayData['mainTemplate'] = 'vols/vol_event_date_record_view'; $this->load->vars($displayData); $this->load->view('template'); }
function viewSponsorFinancials($lSponID) { //------------------------------------------------------------------------------ // //------------------------------------------------------------------------------ if (!bTestForURLHack('showSponsorFinancials')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($this, $lSponID, 'sponsor ID'); $displayData = array(); $displayData['lSponID'] = $lSponID = (int) $lSponID; //------------------------------------------------ // models, libraries and utilities //------------------------------------------------ $params = array('enumStyle' => 'terse', 'clsRpt'); $this->load->library('generic_rpt', $params); $clsRpt = new generic_rpt($params); $this->load->library('util/dl_date_time', '', 'clsDateTime'); $this->load->model('sponsorship/msponsorship', 'clsSpon'); $this->load->model('sponsorship/msponsor_charge_pay', 'clsSCP'); $this->load->model('admin/madmin_aco', 'clsACO'); $this->load->helper('dl_util/web_layout'); $this->load->helper('dl_util/record_view'); $this->load->helper('img_docs/link_img_docs'); $this->load->helper('dl_util/time_date'); $this->clsSpon->sponsorInfoViaID($lSponID); $displayData['lSponFID'] = $this->clsSpon->sponInfo[0]->lForeignID; $displayData['contextSummary'] = $this->clsSpon->sponsorshipHTMLSummary(); //-------------------------- // load financial history //-------------------------- $this->clsSCP->bUseDateRange = false; $this->clsSCP->lSponID = $lSponID; $this->clsSCP->cumulativeChargeHistory($lSponID); $displayData['lNumCharges'] = $this->clsSCP->lNumCharges; $displayData['charges'] =& $this->clsSCP->charges; $this->clsSCP->sponsorPaymentHistory(true); $displayData['lNumPayments'] = $this->clsSCP->lPayTot; $displayData['payHistory'] =& $this->clsSCP->payHistory; $displayData['strFinancialSum'] = strSponsorFinancialSummary($clsRpt, $this->clsSCP, $lSponID, '70pt'); //-------------------------- // breadcrumbs //-------------------------- $displayData['pageTitle'] = anchor('main/menu/sponsorship', 'Sponsorship', 'class="breadcrumb"') . ' | ' . anchor('sponsors/view_spon_rec/viewViaSponID/' . $lSponID, 'Sponsorship Record', 'class="breadcrumb"') . ' | Financials'; $displayData['title'] = CS_PROGNAME . ' | Sponsorship'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $displayData['mainTemplate'] = 'sponsorship/financials_view'; $this->load->vars($displayData); $this->load->view('template'); }
function attribList($enumContext, $lAttribID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- $this->load->helper('dl_util/verify_id'); if ($lAttribID . '' != '0') { verifyID($this, $lAttribID, 'attributed to ID'); } $this->load->model('reports/mreports', 'clsReports'); $reportAttributes = array('rptType' => CENUM_REPORTTYPE_PREDEFINED, 'rptName' => CENUM_REPORTNAME_ATTRIB, 'rptDestination' => CENUM_REPORTDEST_SCREEN, 'lStartRec' => 0, 'lRecsPerPage' => 50, 'bShowRecNav' => true, 'viewFile' => 'pre_generic_rpt_view', 'enumContext' => $enumContext, 'lAttribID' => $lAttribID); $this->clsReports->createReportSessionEntry($reportAttributes); $reportID = $this->clsReports->sRpt->reportID; redirect('reports/reports/run/' . $reportID); }
public function moveSort($lReportID, $lFieldID, $enumMove) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- $this->load->helper('dl_util/verify_id'); verifyID($this, $lReportID, 'custom report ID'); $lReportID = (int) $lReportID; $lFieldID = (int) $lFieldID; //------------------------------------------------ // libraries and utilities //------------------------------------------------ $this->load->helper('reports/search'); $this->load->helper('dl_util/context'); $this->load->helper('reports/creport_util'); $this->load->helper('creports/creport_field'); $this->load->model('admin/madmin_aco'); $this->load->model('creports/mcreports', 'clsCReports'); //------------------------------------------------ // load report //------------------------------------------------ $displayData['cRptTypes'] = loadCReportTypeArray(); $this->clsCReports->loadReportViaID($lReportID, true); $report =& $this->clsCReports->reports[0]; if (!$report->bUserHasWriteAccess) { vid_bTestFail($this, false, 'Custom Report', $lReportID); return; } $this->load->library('util/up_down_top_bottom', '', 'upDown'); $this->upDown->enumMove = $enumMove; $this->upDown->enumRecType = 'creport fields'; $this->upDown->strUfieldDDL = 'creport_fields'; $this->upDown->strUfieldDDLKey = 'crf_lKeyID'; $this->upDown->strUfieldDDLSort = 'crf_lSortIDX'; $this->upDown->strUfieldDDLQual1 = 'crf_lReportID'; $this->upDown->strUfieldDDLRetired = ''; $this->upDown->lUfieldDDLQual1Val = $lReportID; $this->upDown->lKeyID = $lFieldID; $this->upDown->moveRecs(); $this->session->set_flashdata('msg', 'The display fields were re-ordered'); redirect('creports/display_order/addEditDisplayTermOrder/' . $lReportID); }
function setActiveStateVol($lVolID, $bSetActive) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- global $gbVolMgr, $glChapterID; $bSetActive = $bSetActive == 'true'; if (!bTestForURLHack('volMgr')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($glChapterID, $lVolID, 'volunteer ID'); //------------------------------------------------ // models, libraries and utilities //------------------------------------------------ $this->load->model('vols/mvol', 'cVol'); $this->cVol->changeVolActiveState($lVolID, $bSetActive); $this->session->set_flashdata('msg', 'The selected volunteer was set to ' . ($bSetActive ? '<b>Active</b>' : '<b>Inactive</b>') . '.'); redirect('hospice/vols/vol_record/viewRec/' . $lVolID); }
function update($lReportID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- $this->load->helper('dl_util/verify_id'); verifyID($this, $lReportID, 'custom report ID'); //------------------------------------------------ // models, libraries and utilities //------------------------------------------------ $this->load->helper('dl_util/context'); $this->load->helper('reports/creport_util'); $this->load->model('admin/madmin_aco'); $this->load->model('creports/mcreports'); $this->load->model('creports/mcrpt_search_terms', 'crptTerms'); $terms = array(); foreach ($_POST as $strFN => $vValue) { if (substr($strFN, 0, 8) == 'txtParen') { $parens = explode('_', $strFN); $bLeft = $parens[1] == 'L'; $lTermID = (int) $parens[2]; $lTermIDX = (int) $parens[3]; $this->setParenTermEntry($terms, $lTermID); if ($vValue . '' != '') { if ($bLeft) { ++$terms[$lTermID]->left; } else { ++$terms[$lTermID]->right; } } } elseif (substr($strFN, 0, 8) == 'ddlAndOr') { $strAndOr = explode('_', $strFN); $lTermID = (int) $strAndOr[1]; $this->setParenTermEntry($terms, $lTermID); $terms[$lTermID]->bAnd = $vValue == 'AND'; } } $this->crptTerms->updateParens($terms); $this->session->set_flashdata('msg', 'The search expression was updated.'); redirect('creports/custom_directory/viewRec/' . $lReportID); }
function viewViaBizID($lBizID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- $this->load->helper('dl_util/verify_id'); verifyID($this, $lBizID, 'business ID'); $displayData = array(); $displayData['lBizID'] = $lBizID = (int) $lBizID; //------------------------------------------------ // libraries and utilities //------------------------------------------------ $params = array('enumStyle' => 'terse'); $this->load->library('generic_rpt', $params); $this->load->library('util/dl_date_time', '', 'clsDateTime'); $this->load->model('admin/madmin_aco', 'clsACO'); $this->load->model('biz/mbiz', 'clsBiz'); // $this->load->helper ('dl_util/email_web'); //------------------------------------------------ // stripes //------------------------------------------------ $this->load->model('util/mbuild_on_ready', 'clsOnReady'); $this->clsOnReady->addOnReadyTableStripes(); $this->clsOnReady->closeOnReady(); $displayData['js'] = $this->clsOnReady->strOnReady; $this->clsBiz->loadBizRecsViaBID($lBizID); $displayData['contextSummary'] = $this->clsBiz->strBizHTMLSummary(); $displayData['strBizName'] = $this->clsBiz->bizRecs[0]->strBizName; $this->clsBiz->contactList(true, false, false); $displayData['contacts'] =& $this->clsBiz->contacts; $displayData['lNumContacts'] = $this->clsBiz->lNumContacts; //----------------------------- // breadcrumbs & page setup //----------------------------- $displayData['title'] = CS_PROGNAME . ' | Business'; $displayData['pageTitle'] = anchor('main/menu/biz', 'Businesses/Organizations', 'class="breadcrumb"') . ' | ' . anchor('biz/biz_record/view/' . $lBizID, 'Business Record', 'class="breadcrumb"') . ' | Business Contacts'; $displayData['mainTemplate'] = 'biz/contact_list_view'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $this->load->vars($displayData); $this->load->view('template'); }
function autoChargeRecord($lAutoChargeID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- if (!bTestForURLHack('showSponsorFinancials')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($this, $lAutoChargeID, 'autocharge ID'); $displayData = array(); //------------------------------------------------ // models, libraries and utilities //------------------------------------------------ $params = array('enumStyle' => 'terse'); $this->load->library('generic_rpt', $params); $this->load->library('util/dl_date_time', '', 'clsDateTime'); $this->load->model('sponsorship/msponsorship', 'clsSpon'); $this->load->model('sponsorship/msponsor_charge_pay', 'clsSCP'); $this->load->helper('dl_util/web_layout'); $this->load->model('admin/madmin_aco', 'clsACO'); $clsACEntry = new stdClass(); $this->clsSCP->loadAutoChargeViaACID($lAutoChargeID, $clsACEntry); $displayData['lMonth'] = $clsACEntry->lMonth; $displayData['lYear'] = $clsACEntry->lYear; $this->clsSCP->loadChargesViaACID($lAutoChargeID, $displayData['autoChargeInfo'], $displayData['lNumAutoCharges']); //------------------------------------------------ // breadcrumbs / page setup //------------------------------------------------ $displayData['contextSummary'] = $this->clsSCP->autoChargeHTMLSummary($clsACEntry); $displayData['mainTemplate'] = array('sponsorship/auto_charge_record_view'); $displayData['pageTitle'] = anchor('main/menu/sponsorship', 'Sponsorship', 'class="breadcrumb"') . ' | AutoCharge Record'; $displayData['title'] = CS_PROGNAME . ' | Sponsorship'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $this->load->vars($displayData); $this->load->view('template'); }
function addEdit($enumGroupType, $lGID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- if (!bAllowAccess('adminOnly')) { return; } $this->load->helper('dl_util/verify_id'); if ($lGID != '0') { verifyID($this, $lGID, 'group ID'); } $displayData = array(); $lGID = (int) $lGID; //------------------------- // models & helpers //------------------------- $this->load->model('groups/mgroups', 'clsGroups'); $this->load->helper('groups/groups'); $this->load->helper('dl_util/web_layout'); $displayData['strGroupType'] = $strGroupType = strXlateContext($enumGroupType); groupExtensionProperties($enumGroupType, $gProps); $displayData['gProps'] =& $gProps; //---------------------------- // validation rules //---------------------------- $this->form_validation->set_error_delimiters('<div class="formError">', '</div>'); $this->form_validation->set_rules('txtGroupName', $strGroupType . ' Group Name', 'trim|callback_groupNameBlankTest|callback_groupNameDupTest[' . $enumGroupType . ',' . $lGID . ']'); if ($gProps->extended) { if ($gProps->lNumBool > 0) { foreach ($gProps->bools as $bField) { $this->form_validation->set_rules($bField->strFormFN, 'Check Box', 'trim'); } } if ($gProps->lNumInt > 0) { echo __FILE__ . ' ' . __LINE__ . '<br>' . "\n"; die; } } if ($this->form_validation->run() == FALSE) { $this->load->library('generic_form'); $displayData['lGID'] = $lGID = (int) $lGID; $displayData['bNew'] = $bNew = $lGID <= 0; $displayData['enumGroupType'] = $this->clsGroups->gp_enumGroupType = $enumGroupType = htmlspecialchars($enumGroupType); if (validation_errors() == '') { $this->clsGroups->loadActiveGroupsViaType($enumGroupType, '', '', true, $lGID); $gl =& $this->clsGroups->arrGroupList[0]; $displayData['strGroupName'] = htmlspecialchars($gl->strGroupName); // set the database values for extended fields if ($gProps->extended) { if ($gProps->lNumBool > 0) { foreach ($gProps->bools as $bField) { $strFN = $bField->strDBFN; $bField->bValue = $gl->{$strFN}; } } if ($gProps->lNumInt > 0) { echo __FILE__ . ' ' . __LINE__ . '<br>' . "\n"; die; } } } else { setOnFormError($displayData); $displayData['strGroupName'] = set_value('txtGroupName'); if ($gProps->extended) { if ($gProps->lNumBool > 0) { foreach ($gProps->bools as $bField) { $bField->bValue = set_value($bField->strFormFN) == 'true'; } } if ($gProps->lNumInt > 0) { echo __FILE__ . ' ' . __LINE__ . '<br>' . "\n"; die; } } } $displayData['nav'] = $this->mnav_brain_jar->navData(); //---------------------- // set breadcrumbs //---------------------- $displayData['title'] = CS_PROGNAME . ' | Groups'; $displayData['pageTitle'] = anchor('main/menu/admin', 'Admin', 'class="breadcrumb"') . ' | ' . anchor('admin/alists/showLists', 'Lists', 'class="breadcrumb"') . ' | ' . anchor('groups/groups_view/view/' . $enumGroupType, 'Groups: ' . $strGroupType, 'class="breadcrumb"') . ' | ' . ($bNew ? 'Add New' : 'Edit'); $displayData['mainTemplate'] = 'groups/group_add_edit_view'; $this->load->vars($displayData); $this->load->view('template'); } else { $bNew = $lGID <= 0; $strGroupCat = strXlateContext($enumGroupType); $this->clsGroups->loadActiveGroupsViaType($this->clsGroups->gp_enumGroupType, '', '', true, -1); $clsList = $this->clsGroups->arrGroupList[0]; $clsList->lKeyID = $lGID; $clsList->strGroupName = xss_clean(trim($_POST['txtGroupName'])); $clsList->dteExpire = strtotime('1/1/2030'); $clsList->bTempGroup = false; $clsList->strNotes = ''; if ($gProps->extended) { if ($gProps->lNumBool > 0) { foreach ($gProps->bools as $bField) { $strFN = $bField->strDBFN; $clsList->{$strFN} = @$_POST[$bField->strFormFN] == 'true'; } } if ($gProps->lNumInt > 0) { echo __FILE__ . ' ' . __LINE__ . '<br>' . "\n"; die; } } if ($bNew) { $this->clsGroups->gp_enumGroupType = $enumGroupType; $this->session->set_flashdata('msg', $strGroupCat . ' Group added'); $this->clsGroups->lAddNewGroupParent(); } else { $this->session->set_flashdata('msg', $strGroupCat . ' Group updated'); $this->clsGroups->updateGroupParentRec(); } redirect('groups/groups_view/view/' . $enumGroupType); } }
function clientViaStatCatID($lStatCatID, $bActive) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- $this->load->helper('dl_util/verify_id'); verifyID($this, $lStatCatID, 'status category ID'); $bActive = $bActive == 'true'; $this->load->model('reports/mreports', 'clsReports'); $this->load->model('clients/mclients', 'clsClients'); $reportAttributes = array('rptType' => CENUM_REPORTTYPE_PREDEFINED, 'rptName' => CENUM_REPORTNAME_CLIENTVIASTATCAT, 'rptDestination' => CENUM_REPORTDEST_SCREEN, 'lStartRec' => 0, 'lRecsPerPage' => 50, 'bShowRecNav' => true, 'bActive' => $bActive, 'viewFile' => 'pre_generic_rpt_view', 'lStatCatID' => $lStatCatID); $this->clsReports->createReportSessionEntry($reportAttributes); $reportID = $this->clsReports->sRpt->reportID; redirect('reports/reports/run/' . $reportID); }
public function view($lPID = 0) { //------------------------------------------------------------------------- // //------------------------------------------------------------------------- global $gbVolLogin, $gVolPerms, $glVolPeopleID, $glUserID; if ($gbVolLogin) { $lPID = $glVolPeopleID; } else { if (!bTestForURLHack('viewPeopleBizVol')) { return; } } $this->load->helper('dl_util/verify_id'); verifyID($this, $lPID, 'people ID'); $displayData = array(); $displayData['lPID'] = $lPID = (int) $lPID; $displayData['js'] = ''; $params = array('enumStyle' => 'terse', 'clsRpt'); $this->load->library('generic_rpt', $params); //------------------------------------------------ // libraries and utilities //------------------------------------------------ $this->load->model('people/mpeople', 'clsPeople'); $this->load->model('biz/mbiz', 'clsBiz'); $this->load->model('admin/madmin_aco', 'clsACO'); $this->load->model('admin/muser_accts', 'clsUser'); $this->load->model('sponsorship/msponsorship', 'clsSpon'); $this->load->model('sponsorship/msponsor_charge_pay', 'clsSCP'); $this->load->model('donations/mdonations', 'clsGifts'); $this->load->model('donations/mpledges', 'clsPledges'); $this->load->model('vols/mvol', 'clsVol'); $this->load->model('people/mrelationships', 'clsRel'); $this->load->model('groups/mgroups', 'groups'); $this->load->model('img_docs/mimage_doc', 'clsImgDoc'); $this->load->model('img_docs/mimg_doc_tags', 'cidTags'); $this->load->model('admin/mpermissions', 'perms'); $this->load->library('util/dl_date_time', '', 'clsDateTime'); $this->load->helper('groups/groups'); $this->load->helper('dl_util/web_layout'); // $this->load->helper ('dl_util/email_web'); $this->load->helper('dl_util/record_view'); $this->load->helper('img_docs/link_img_docs'); $this->load->helper('dl_util/time_date'); $this->load->helper('img_docs/image_doc'); $this->load->helper('img_docs/link_img_docs'); $this->load->helper('personalization/ptable'); $this->load->helper('img_docs/img_doc_tags'); $this->load->helper('js/div_hide_show'); $displayData['js'] .= showHideDiv(); // $this->load->model('reminders/mreminders', 'clsReminders'); // $displayData['clsRem'] = $this->clsReminders; $this->clsPeople->sqlWhereExtra = " AND pe_lKeyID = {$lPID} "; $this->clsPeople->loadPeople(true, true, true); $displayData['people'] =& $this->clsPeople->people[0]; //------------------------------- // volunteer info //------------------------------- $displayData['vol'] = new stdClass(); $displayData['vol']->bVol = $this->clsVol->bVolStatusViaPID($lPID, $displayData['vol']->lVolID, $displayData['vol']->bInactive, $displayData['vol']->dteInactive, $displayData['vol']->dteVolStart); //------------------------------- // sponsorship info //------------------------------- if (!$gbVolLogin) { $this->clsSpon->sponsorshipInfoViaPID($lPID); $displayData['sponInfo'] = $this->clsSpon->sponInfo; $displayData['lNumSponsors'] = $this->clsSpon->lNumSponsors; } //------------------------------- // personalized tables //------------------------------- if (!$gbVolLogin) { $this->perms->loadUserAcctInfo($glUserID, $acctAccess); $this->load->model('personalization/muser_fields', 'clsUF'); $this->load->model('personalization/muser_fields_display', 'clsUFD'); $displayData['strPT'] = strPTableDisplay(CENUM_CONTEXT_PEOPLE, $lPID, $this->clsUFD, $this->perms, $acctAccess, $displayData['strFormDataEntryAlert'], $displayData['lNumPTablesAvail']); } //------------------------------- // household //------------------------------- if (!$gbVolLogin) { $this->clsPeople->lHouseholdID = $this->clsPeople->people[0]->lHouseholdID; $this->clsPeople->loadPIDsViaHouseholdHID(); $displayData['arrHouseholds'] = $this->clsPeople->arrHouseholds; } //------------------------------- // relationships //------------------------------- if (!$gbVolLogin) { $this->clsRel->lPID = $lPID; $this->clsRel->loadFromRelViaPID(); $displayData['arrRelAB'] = $this->clsRel->arrRelAB; $displayData['lNumRelAB'] = $this->clsRel->lNumRelAB; $this->clsRel->loadToRelViaPID(); $displayData['arrRelBA'] = $this->clsRel->arrRelAB; $displayData['lNumRelBA'] = $this->clsRel->lNumRelAB; } //------------------------------- // groups //------------------------------- if (!$gbVolLogin) { $this->groups->groupMembershipViaFID(CENUM_CONTEXT_PEOPLE, $lPID); $displayData['inGroups'] = $this->groups->arrMemberInGroups; $displayData['lCntGroupMembership'] = $this->groups->lNumMemInGroups; $displayData['lNumGroups'] = $this->groups->lCntActiveGroupsViaType(CENUM_CONTEXT_PEOPLE); $this->groups->loadActiveGroupsViaType(CENUM_CONTEXT_PEOPLE, 'groupName', $this->groups->strMemListIDs, false, null); $displayData['groupList'] = $this->groups->arrGroupList; } //------------------------------- // images and documents //------------------------------- if (!$gbVolLogin) { loadImgDocRecView($displayData, CENUM_CONTEXT_PEOPLE, $lPID); } //------------------- // donation summary //------------------- if (!$gbVolLogin) { $this->clsGifts->lPeopleID = $lPID; $displayData['lTotGifts'] = 0; $this->clsGifts->cumulativeOpts = new stdClass(); $this->clsGifts->cumulativeOpts->enumCumulativeSource = 'people'; $this->clsGifts->cumulativeOpts->enumMoneySet = 'monetaryOnly'; $this->clsGifts->cumulativeOpts->bSoft = false; $this->clsGifts->cumulativeDonation($this->clsACO, $displayData['lTotHard']); $displayData['strCumGiftsNonSoftMon'] = strBuildCumlativeTable($this->clsGifts->lNumCumulative, $this->clsGifts->cumulative, true); // $displayData['lTotGifts'] += $this->clsGifts->lNumCumulative; // in-kind donations $this->clsGifts->cumulativeOpts->enumMoneySet = 'gikOnly'; $this->clsGifts->cumulativeDonation($this->clsACO, $displayData['lTotInKind']); $displayData['strCumGiftsNonSoftInKind'] = strBuildCumlativeTable($this->clsGifts->lNumCumulative, $this->clsGifts->cumulative, true); // $displayData['lTotGifts'] += $this->clsGifts->lNumCumulative; // soft donations $this->clsGifts->cumulativeOpts->enumMoneySet = 'all'; $this->clsGifts->cumulativeOpts->bSoft = true; $this->clsGifts->cumulativeDonation($this->clsACO, $displayData['lTotSoft']); $displayData['strCumGiftsSoft'] = strBuildCumlativeTable($this->clsGifts->lNumCumulative, $this->clsGifts->cumulative, true); // $displayData['lTotGifts'] += $this->clsGifts->lNumCumulative; // sponsorship payments $this->clsSCP->cumulativeSponsorshipViaPeopleID($this->clsACO, $lPID); $displayData['strCumSpon'] = strBuildCumlativeTable($this->clsSCP->lNumSponPayCumulative, $this->clsSCP->sponPayCumulative, true); $displayData['lNumSponPay'] = $this->clsSCP->lNumSponPayCumulative; $displayData['lNumPledges'] = $this->clsPledges->lNumPledgesViaFID($lPID); } //------------------- // business contacts //------------------- if (!$gbVolLogin) { $this->clsBiz->lPID = $lPID; $this->clsBiz->contactList(false, true, false); $displayData['lNumContacts'] = $this->clsBiz->lNumContacts; $displayData['contacts'] = $this->clsBiz->contacts; } //-------------------------- // breadcrumbs //-------------------------- if ($gbVolLogin) { $displayData['pageTitle'] = 'Contact Info'; $displayData['title'] = CS_PROGNAME . ' | Contact Info'; } else { $displayData['pageTitle'] = anchor('main/menu/people', 'People', 'class="breadcrumb"') . ' | People Record'; $displayData['title'] = CS_PROGNAME . ' | People'; } $displayData['nav'] = $this->mnav_brain_jar->navData(); $displayData['mainTemplate'] = 'people/people_record_view'; $this->load->vars($displayData); $this->load->view('template'); }
function removeContact($lBizID, $lContactID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- if (!bTestForURLHack('editPeopleBizVol')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($this, $lBizID, 'business ID'); verifyID($this, $lContactID, 'business contact ID'); $lBizID = (int) $lBizID; $lContactID = (int) $lContactID; $this->load->model('biz/mbiz', 'clsBiz'); $lGroupID = null; $this->clsBiz->retireSingleBizCon($lContactID, $lGroupID); $this->session->set_flashdata('msg', 'The business contact record was removed'); redirect_Biz($lBizID); }
function remove($lQuestID, $lPPTestID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- if (!bTestForURLHack('showClients')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($this, $lPPTestID, 'pre/post test ID'); //------------------------- // models & helpers //------------------------- $this->load->model('client_features/mcpre_post_tests', 'cpptests'); $this->load->model('admin/mpermissions', 'perms'); //------------------------- // load the pre/post test //------------------------- $this->cpptests->loadPPTestsViaPPTID($lPPTestID); $pptest =& $this->cpptests->pptests[0]; $this->cpptests->removeQuestion($lQuestID); $this->session->set_flashdata('msg', 'The question was removed from test <b>' . htmlspecialchars($pptest->strTestName) . '</b>'); redirect('cpre_post_tests/ppquest_view/viewQuestions/' . $lPPTestID); }
function remove($lSponID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- if (!bTestForURLHack('showSponsors')) { return; } $this->load->helper('dl_util/verify_id'); verifyID($this, $lSponID, 'sponsor ID'); $this->load->model('util/mrecycle_bin', 'clsRecycle'); $this->load->model('sponsorship/msponsorship', 'clsSpon'); $this->load->model('sponsorship/msponsor_charge_pay', 'clsSCP'); $this->load->model('personalization/muser_fields', 'clsUF'); $this->clsSCP->removePaymentsChargesViaSponID($lSponID); $vNull = null; $this->clsSpon->retireSingleSponsorship($lSponID, $vNull); $this->session->set_flashdata('msg', 'The sponsorship <b>' . str_pad($lSponID, 5, '0', STR_PAD_LEFT) . '</b> was removed.'); redirect('main/menu/sponsorship'); }
function remove($lEventID) { $this->load->helper('dl_util/verify_id'); verifyID($this, $lEventID, 'event ID'); $lEventID = (int) $lEventID; $this->load->model('vols/mvol_events', 'clsVolEvents'); $this->clsVolEvents->deleteEvent($lEventID); $this->session->set_flashdata('msg', 'The specified event was removed.'); redirect_VolEventList(); }
function viewVolAssignViaEvent($lEventID) { //------------------------------------------------------------------------- // //------------------------------------------------------------------------- $this->load->helper('dl_util/verify_id'); verifyID($this, $lEventID, 'event ID'); //------------------------------------------------ // libraries / models / utilities //------------------------------------------------ $params = array('enumStyle' => 'terse'); $this->load->library('generic_rpt', $params); $this->load->model('vols/mvol_event_dates', 'clsVolEventDates'); $this->load->model('vols/mvol_events', 'clsVolEvents'); $this->load->model('vols/mvol_event_dates_shifts', 'clsShifts'); $this->load->model('vols/mvol_event_dates_shifts_vols', 'clsSV'); $this->load->helper('dl_util/web_layout'); $this->load->helper('dl_util/time_date'); $this->clsVolEvents->entireEventInfo($lEventID, $lNumEvents, $events); $displayData['events'] =& $events; $displayData['contextSummary'] = $this->clsVolEvents->volEventHTMLSummary(0); /* $this->clsVolEvents->loadEventsViaEID($lEventID); $displayData['strEventName'] = $this->clsVolEvents->events[0]->strEventName; $this->clsVolEventDates->loadEventDates($lEventID); $displayData['lNumDates'] = $lNumDates = $this->clsVolEventDates->lNumDates; if ($lNumDates > 0){ foreach ($this->clsVolEventDates->dates as $edate){ $lEventDateID = $edate->lKeyID; if ($edate->lNumShifts > 0){ $this->clsShifts->loadShiftsViaEventDateID($lEventDateID); $edate->shifts = arrayCopy($this->clsShifts->shifts); foreach ($edate->shifts as $shift){ $lShiftID = $shift->lKeyID; $this->clsSV->loadVolsViaShiftID($lShiftID); $shift->lNumVols = $lNumVols = $this->clsSV->lNumVols; if ($lNumVols > 0){ $shift->vols = arrayCopy($this->clsSV->vols); } } } } } $displayData['dates'] = &$this->clsVolEventDates->dates; */ //-------------------------- // breadcrumbs //-------------------------- $displayData['pageTitle'] = anchor('main/menu/vols', 'Volunteers', 'class="breadcrumb"') . ' | ' . anchor('volunteers/events_schedule/viewEventsList', 'Event List', 'class="breadcrumb"') . ' | ' . anchor('volunteers/events_record/viewEvent/' . $lEventID, 'Event', 'class="breadcrumb"') . ' | Event Date'; $displayData['title'] = CS_PROGNAME . ' | Volunteers'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $displayData['mainTemplate'] = 'vols/vol_assign_via_event_view'; $this->load->vars($displayData); $this->load->view('template'); }
function regUnreg($bRegister, $lShiftID, $lAssignID = null) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- global $genumDateFormat, $glVolPeopleID; $bRegister = $bRegister == 'true'; $lShiftID = (int) $lShiftID; $this->load->helper('dl_util/verify_id'); verifyID($this, $lShiftID, 'shift ID'); //-------------------------------- // Models & Helpers //-------------------------------- $this->load->model('vols/mvol_event_dates_shifts', 'clsShifts'); $this->load->model('vols/mvol_event_dates_shifts_vols', 'clsSV'); $this->load->model('vols/mvol', 'clsVol'); $lVolID = $this->clsVol->lVolIDViaPeopleID($glVolPeopleID); $this->clsShifts->loadShiftsViaEventShiftID($lShiftID); $shift =& $this->clsShifts->shifts[0]; $strRegInfo = '<table> <tr> <td><b>Event:</td> <td><b>' . htmlspecialchars($shift->strEventName) . '</b></td> </tr> <tr> <td ><b>date:</b></td> <td>' . date($genumDateFormat, $shift->dteEvent) . '</td> </tr> <tr> <td><b>time:</b></td> <td>' . date('g:i a', $shift->dteEventStartTime) . '</td> </tr> <tr> <td><b>duration:</b></td> <td>' . $shift->enumDuration . '</td> </tr> <tr> <td><b>shift:</b></td> <td>' . htmlspecialchars($shift->strShiftName) . '</td> </tr> </table>'; $this->clsShifts->loadShiftsViaEventShiftID($lShiftID); if ($bRegister) { $this->clsSV->lAddVolToShift($lShiftID, $lVolID, 'Self-registration'); $this->session->set_flashdata('msg', 'Thank you for registering for ' . $strRegInfo); } else { $this->clsSV->removeVolFromShift($lAssignID); $this->session->set_flashdata('msg', 'Your registration was cancelled for<br>' . $strRegInfo); } redirect('vol_reg/vol_hours/shifts'); }
function addFromCForm($lParentID, $lCFID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- global $gErrMessages, $gbShowHiddenVerifyError; $this->load->helper('dl_util/verify_id'); verifyID($this, $lCFID, 'custom form ID'); $displayData = array(); $displayData['js'] = ''; $displayData['lCFID'] = $lCFID = (int) $lCFID; $displayData['lParentID'] = $lParentID = (int) $lParentID; $gbShowHiddenVerifyError = false; $gErrMessages = array(); /*------------------------------------------------ models/libraries/helpers ------------------------------------------------*/ $params = array('enumStyle' => 'terse'); $this->load->library('generic_rpt', $params); $this->load->model('custom_forms/mcustom_forms', 'cForm'); $this->load->model('personalization/muser_fields', 'clsUF'); $this->load->model('personalization/muser_fields_display', 'clsUFD'); $this->load->model('admin/madmin_aco', 'clsACO'); $this->load->model('admin/mpermissions', 'perms'); $this->load->helper('dl_util/context'); $this->load->helper('dl_util/custom_forms'); $this->load->helper('dl_util/time_date'); $this->load->library('util/dl_date_time', '', 'clsDateTime'); // load the custom form $this->cForm->loadCustomFormsViaCFID($lCFID); $displayData['cForm'] = $cForm =& $this->cForm->customForms[0]; $enumType = $cForm->enumContextType; // now that the context is known, verify the parent ID verifyIDsViaType($this, $enumType, $lParentID, true); // custom verification ? $displayData['bCusVerification'] = $bCusVerification = $cForm->strVerificationModule . '' != ''; //----------------------------- // validation rules //----------------------------- $this->form_validation->set_error_delimiters('<div class="formError">', '</div>'); if ($bCusVerification) { $this->load->helper('path'); $this->form_validation->set_rules('hVerify', 'Hidden verification', 'callback_hiddenVerify[' . $cForm->strVerificationModule . ',' . $cForm->strVModEntryPoint . ']'); } // personalized tables and associated fields $this->cForm->loadPTablesForDisplay($lCFID, $this->clsUF); $displayData['utables'] = $utables =& $this->cForm->utables; $displayData['lNumTables'] = $lNumTables = $this->cForm->lNumTables; setValidationUTables($displayData['js'], $lNumTables, $utables); if ($this->form_validation->run() == FALSE) { $this->load->library('generic_form'); $this->load->model('util/mlist_generic', 'clsList'); $this->load->helper('dl_util/web_layout'); loadSupportModels($enumType, $lParentID); initUTableDates($displayData['js'], $lNumTables, $utables); initUTableDDLs($lNumTables, $utables); if (validation_errors() == '') { populateCustomTables($lNumTables, $utables, $lParentID); setCustomUTableDDLs($lNumTables, $utables); } else { setOnFormError($displayData); repopulateCustomTables($lNumTables, $utables); } //-------------------------- // breadcrumbs //-------------------------- $displayData['pageTitle'] = $this->cForm->strCustomFormsPageTitleAddEdit($enumType, $cForm->strFormName); $displayData['strHTMLSummary'] = strContextHTML($enumType, $lParentID, $enumType); $displayData['errMessages'] = arrayCopy($gErrMessages); $displayData['title'] = CS_PROGNAME . ' | Custom Forms'; $displayData['nav'] = $this->mnav_brain_jar->navData(); $displayData['mainTemplate'] = array('custom_forms/custom_form_data_entry_view'); $this->load->vars($displayData); $this->load->view('template'); } else { saveCustomPTables($lParentID, $lNumTables, $utables); $this->cForm->lLogFormSave($lParentID, $lCFID); $this->fromWhenceYeCame($lParentID, $enumType, $cForm); } }
function removeVolsFromShift($lVolAssignID, $lEventDateID, $lShiftID) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- $this->load->helper('dl_util/verify_id'); verifyID($this, $lVolAssignID, 'volunteer assignment ID'); verifyID($this, $lEventDateID, 'event date ID'); verifyID($this, $lShiftID, 'shift ID'); $lVolAssignID = (int) $lVolAssignID; $lEventDateID = (int) $lEventDateID; $lShiftID = (int) $lShiftID; $this->load->model('vols/mvol_event_dates_shifts', 'clsShifts'); $this->clsShifts->loadShiftsViaEventShiftID($lShiftID); $this->load->model('vols/mvol_event_dates_shifts_vols', 'clsSV'); $this->clsSV->removeVolFromShift($lVolAssignID); $this->session->set_flashdata('msg', 'The selected volunteer was removed from shift <b>' . htmlspecialchars($this->clsShifts->shifts[0]->strShiftName) . '</b>'); redirect('volunteers/event_dates_view/viewDates/' . $lEventDateID); }