</tr>'); $params = array('enumStyle' => 'enpRptC'); $clsRpt = new generic_rpt($params); $lRowIDX = 1; $lVolWidth = 170; foreach ($patientInfo as $patient) { $bActive = $patient->bActive; if ($bActive) { $strStyleActive = ''; } else { $strStyleActive = 'color: #999;'; } $lPatientID = $patient->lKeyID; echoT($clsRpt->openRow(true)); echoT($clsRpt->writeCell($lRowIDX, '', 'text-align: center;')); echoT($clsRpt->writeCell(strLinkView_PatientRecord($lPatientID, 'View patient record', true, ' id="prec_' . $lPatientID . '" ') . ' ' . str_pad($lPatientID, 5, '0', STR_PAD_LEFT), 60, $strStyleActive . 'text-align: center;')); echoT($clsRpt->writeCell(strLink_PatientActiveInactive($lPatientID, !$bActive, $bActive ? 'Set Inactive' : 'Activate', true), 30, $strStyleActive . 'text-align: center;')); echoT($clsRpt->writeCell('<b>' . $patient->strSafeNameLF . '</b><br>DOB: ' . $patient->dteBirth, 170, $strStyleActive)); echoT($clsRpt->writeCell($patient->strAddress, 170, $strStyleActive)); //--------------------------- // volunteer associations //--------------------------- if (count($patient->volClient) == 0) { echoT($clsRpt->writeCell('- none -', $lVolWidth, 'text-align: center;')); } else { $strVols = '<ul style="list-style-position: inside; list-style-type: square; display:inline; margin-left: 0pt; padding-left: 0pt;">'; foreach ($patient->volClient as $vc) { $strVols .= '<li>' . htmlspecialchars($vc->vol->strLName . ', ' . $vc->vol->strFName) . ' ' . strLinkAdd_HospicePVist($vc->lVolID, $vc->lPatientID, 'Add visit', false, ' id="apv_' . $vc->lVolID . '_' . $vc->lPatientID . ' " ') . '</li>'; } echoT($clsRpt->writeCell($strVols . '</ul>', $lVolWidth, ''));
public function strPatientHTMLSummary($idx) { /*----------------------------------------------------------------------- assumes user has called $clsClient->loadClientsVia...() caller must include $this->load->helper ('img_docs/image_doc'); -----------------------------------------------------------------------*/ $strOut = ''; $params = array('enumStyle' => 'terse'); $clsRpt = new generic_rpt($params); $clsRpt->setEntrySummary(); $clsC = $this->patients[$idx]; $lCID = $clsC->lKeyID; $strOut .= $clsRpt->openReport('', ''); $strOut .= $clsRpt->openRow(false) . $clsRpt->writeLabel('Patient Name:') . $clsRpt->writeCell(strLinkView_PatientRecord($lCID, 'View Client Record', true) . ' ' . $clsC->strSafeName . ' (client ID: ' . str_pad($lCID, 5, '0', STR_PAD_LEFT) . ')') . $clsRpt->closeRow(); $strOut .= $clsRpt->openRow(false) . $clsRpt->writeLabel('Date of Birth:') . $clsRpt->writeCell($clsC->dteBirth) . $clsRpt->closeRow(); /* $strOut .= $clsRpt->openRow (false) .$clsRpt->writeLabel('Gender:') .$clsRpt->writeCell ($clsC->enumGender) .$clsRpt->closeRow (); */ $strOut .= $clsRpt->closeReport('<br>'); return $strOut; }
$lPatientID = $vc->lPatientID; if ($bInactive) { $strNameColor = '#999'; } $strPatients .= '<tr> <td style="vertical-align: top; padding-right: 8px; color: ' . $strNameColor . ';" rowspan=' . $lRowSpan . '>' . htmlspecialchars($vc->patient->strLName . ', ' . $vc->patient->strFName) . ' </td>'; if (!$bInactive && $bVAActive) { $strPatients .= ' <td style="vertical-align: top;">' . strLinkAdd_HospicePVist($lVolID, $vc->lPatientID, 'Patient visit', true, ' id="addVisit_' . $lVolID . '_' . $vc->lPatientID . '" ') . ' ' . strLinkAdd_HospicePVist($lVolID, $vc->lPatientID, 'Patient visit', false) . ' </td> </tr> <tr>'; } if (!$bInactive) { $strPatients .= ' <td style="vertical-align: top;">' . strLink_VolAssocActiveInactive($lVolID, $lAssocID, !$bVAActive, $strALabel, true) . ' ' . strLink_VolAssocActiveInactive($lVolID, $lAssocID, !$bVAActive, $strALabel, false) . ' </td> </tr> <tr> <td style="vertical-align: top; padding-bottom: 8px;">' . strLinkView_PatientRecord($lPatientID, 'View patient record', true) . ' patient ID: ' . str_pad($lPatientID, 5, '0', STR_PAD_LEFT) . ' </td>'; } $strPatients .= ' </tr>'; } echoT($clsRpt->writeCell($strPatients . '</table>' . $strLinkAddNewAssoc, $lPatientWidth, $strColor)); } } echoT($clsRpt->closeReport()); }
function showPatientAssoc($attributes, $clsRpt, $volRec, $lVolID, $volClient) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- $bActive = $volRec->bActive; $attributes->bCloseDiv = false; $attributes->divID = 'pAssoc'; $attributes->divImageID = 'pAssocDivImg'; $attributes->lUnderscoreWidth = 400; if ($bActive) { $strLinkAddNewA = strLinkAdd_PatientAssociation($lVolID, 'Add patient association', true) . ' ' . strLinkAdd_PatientAssociation($lVolID, 'Add patient association', false); } else { $strLinkAddNewA = ''; } openBlock('Volunteer/Patient Associations', $strLinkAddNewA, $attributes); if (count($volClient) == 0) { echoT('<i>No associated patients</i>'); } else { echoT(' <table class="enpRpt"> <tr> <td class="enpRptLabel"> Patient ID </td> <td class="enpRptLabel"> Patient </td> <td class="enpRptLabel"> Status </td>'); if ($bActive) { echoT(' <td class="enpRptLabel"> </td> <td class="enpRptLabel"> </td>'); } echoT(' </tr>'); foreach ($volClient as $vc) { $bVCActive = $vc->bActive; if ($bVCActive) { $strALabel = 'Set inactive'; $lRowSpan = 3; $strNameColor = '#000'; } else { $strALabel = 'Set active'; $lRowSpan = 2; $strNameColor = '#999'; } $lAssocID = $vc->lKeyID; $lPatientID = $vc->lPatientID; echoT(' <tr class="makeStripe"> <td style="vertical-align: top; color: ' . $strNameColor . ';" class="enpRpt">' . strLinkView_PatientRecord($lPatientID, 'View patient record', true) . ' ' . str_pad($lPatientID, 5, '0', STR_PAD_LEFT) . ' </td>'); echoT(' <td style="vertical-align: top; padding-right: 8px; color: ' . $strNameColor . ';" class="enpRpt">' . htmlspecialchars($vc->patient->strLName . ', ' . $vc->patient->strFName) . ' </td>'); echoT(' <td style="vertical-align: top; padding-right: 8px; color: ' . $strNameColor . ';" class="enpRpt">' . ($bVCActive ? '<b>Active</b>' : 'Inactive') . ' </td>'); if ($bActive) { if ($bVCActive) { echoT(' <td style="vertical-align: top;" class="enpRpt">' . strLinkAdd_HospicePVist($lVolID, $vc->lPatientID, 'Add patient visit', true) . ' ' . strLinkAdd_HospicePVist($lVolID, $vc->lPatientID, 'Add patient visit', false) . ' </td>'); } else { echoT(' <td style="vertical-align: top;" class="enpRpt"> </td>'); } echoT(' <td style="vertical-align: top;" class="enpRpt">' . strLink_VolAssocActiveInactive($lVolID, $lAssocID, !$bActive, $strALabel, true) . ' ' . strLink_VolAssocActiveInactive($lVolID, $lAssocID, !$bActive, $strALabel, false) . ' </td>'); } echoT(' </tr>'); } echoT('</table>'); } $attributes->bCloseDiv = true; closeBlock($attributes); }
function showGeneralPVisitInfo($attributes, $clsRpt, $pVisit) { //--------------------------------------------------------------------- // //--------------------------------------------------------------------- global $gbVolMgr; $attributes->bCloseDiv = false; $attributes->divID = 'pVGen'; $attributes->divImageID = 'pVGenDivImg'; openBlock('Visit', '', $attributes); echoT($clsRpt->openReport()); echoT($clsRpt->openRow() . $clsRpt->writeLabel('Visit ID:') . $clsRpt->writeCell(str_pad($pVisit->lKeyID, 5, '0', STR_PAD_LEFT)) . $clsRpt->closeRow()); echoT($clsRpt->openRow() . $clsRpt->writeLabel('Organization:') . $clsRpt->writeCell(htmlspecialchars($pVisit->strChapterName)) . $clsRpt->closeRow()); if ($gbVolMgr) { $strViewPRec = strLinkView_PatientRecord($pVisit->lPatientID, 'View patient record', true); $strViewVRec = strLinkView_VolRecord($pVisit->lVolID, 'View volunteer record', true); } else { $strViewVRec = $strViewPRec = ''; } echoT($clsRpt->openRow() . $clsRpt->writeLabel('Patient:') . $clsRpt->writeCell(htmlspecialchars($pVisit->strPatientLName . ', ' . $pVisit->strPatientFName) . ' ' . $strViewPRec) . $clsRpt->closeRow()); echoT($clsRpt->openRow() . $clsRpt->writeLabel('Volunteer:') . $clsRpt->writeCell(htmlspecialchars($pVisit->strVolLName . ', ' . $pVisit->strVolFName) . ' ' . $strViewVRec) . $clsRpt->closeRow()); echoT($clsRpt->openRow() . $clsRpt->writeLabel('Date of Visit:') . $clsRpt->writeCell(date('l, F jS, Y', $pVisit->dteVisit)) . $clsRpt->closeRow()); echoT($clsRpt->openRow() . $clsRpt->writeLabel('Time/Duration:') . $clsRpt->writeCell(date('g:i A', $pVisit->lStartTime) . ' / ' . pvisit\strMinutesToHoursMin($pVisit->lDuration)) . $clsRpt->closeRow()); echoT($clsRpt->openRow() . $clsRpt->writeLabel('Medical Record #:') . $clsRpt->writeCell(htmlspecialchars($pVisit->strMedRec)) . $clsRpt->closeRow()); echoT($clsRpt->closeReport()); $attributes->bCloseDiv = true; closeBlock($attributes); }