public function sponsorChargeHTMLSummary()
 {
     //-----------------------------------------------------------------------
     // assumes user has called $clsSCP->loadChargeRecord()
     //-----------------------------------------------------------------------
     global $gdteNow, $genumDateFormat;
     $params = array('enumStyle' => 'terse');
     $clsRpt = new generic_rpt($params);
     $clsRpt->setBreadCrumbs();
     $cRec = $this->chargeRec;
     $bBiz = $cRec->bBiz;
     if ($bBiz) {
         $strLinkPeopleBiz = strLinkView_Biz($cRec->lForeignID, 'View business record', true);
     } else {
         $strLinkPeopleBiz = strLinkView_People($cRec->lForeignID, 'View people record', true);
     }
     $lSponID = $cRec->lSponsorshipID;
     $clsRpt->openReport('', '');
     $clsRpt->openRow(false);
     $clsRpt->writeLabel(' Sponsor:');
     $clsRpt->writeCell($strLinkPeopleBiz . ' ' . str_pad($cRec->lForeignID, 5, '0', STR_PAD_LEFT) . ' ' . $cRec->strSponSafeNameFL);
     $clsRpt->closeRow();
     $clsRpt->openRow(false);
     $clsRpt->writeLabel('Sponsor ID:');
     $clsRpt->writeCell(strLinkView_Sponsorship($lSponID, 'View sponsorship', true) . ' ' . str_pad($lSponID, 5, '0', STR_PAD_LEFT));
     $clsRpt->closeRow();
     if (is_null($cRec->lClientID)) {
         $strClient = '<i>not set</i>';
     } else {
         $strClient = strLinkView_Client($cRec->lClientID, 'View client record', true) . ' ' . str_pad($cRec->lClientID, 5, '0', STR_PAD_LEFT) . ' ' . $cRec->strClientSafeNameFL;
     }
     $clsRpt->openRow(false);
     $clsRpt->writeLabel('Client:');
     $clsRpt->writeCell($strClient);
     $clsRpt->closeRow();
     $clsRpt->openRow(false);
     $clsRpt->writeLabel('Status:');
     $clsRpt->writeCell($cRec->bInactive ? 'Inactive' : 'Active');
     $clsRpt->closeRow();
     $clsRpt->openRow(false);
     $clsRpt->writeLabel('Charge ID:');
     $clsRpt->writeCell(str_pad($cRec->lKeyID, 5, '0', STR_PAD_LEFT));
     $clsRpt->closeRow();
     $clsRpt->openRow(false);
     $clsRpt->writeLabel('Amount:');
     $clsRpt->writeCell($cRec->strCurSymbol . ' ' . number_format($cRec->curChargeAmnt, 2) . ' ' . $cRec->strFlagImage);
     $clsRpt->closeRow();
     $clsRpt->openRow(false);
     $clsRpt->writeLabel('Date of Charge:');
     $clsRpt->writeCell(date($genumDateFormat, $cRec->dteCharge));
     $clsRpt->closeRow();
     $clsRpt->closeReport(true);
 }
function showSingleSponsorshipInfo($clsRpt, $strTitle, $clsSpon)
{
    //---------------------------------------------------------------------
    // use for single sponsorship
    //---------------------------------------------------------------------
    $attributes = new stdClass();
    $attributes->lTableWidth = 900;
    $attributes->divID = 'ssponDiv';
    $attributes->divImageID = 'ssponDivImg';
    openBlock($strTitle, '', $attributes);
    $clsRpt->openReport();
    if ($clsSpon->lNumSponsors == 0) {
        echoT('<i>(no sponsorships)</i><br>');
    } else {
        foreach ($clsSpon->sponInfo as $idx => $spon) {
            echoT($clsRpt->openRow() . $clsRpt->writeLabel('Sponsor ID:') . $clsRpt->writeCell(strLinkView_Sponsorship($spon->lKeyID, 'view sponsorship', true) . ' ' . str_pad($spon->lKeyID, 5, '0', STR_PAD_LEFT)) . $clsRpt->closeRow());
            $lFID = $spon->lForeignID;
            if ($spon->bSponBiz) {
                $strLinkFID = strLinkView_Biz($lFID, 'View business record', true);
            } else {
                $strLinkFID = strLinkView_PeopleRecord($lFID, 'View people record', true);
            }
            echoT($clsRpt->openRow() . $clsRpt->writeLabel('Sponsor:') . $clsRpt->writeCell($strLinkFID . ' ' . str_pad($lFID, 5, '0', STR_PAD_LEFT) . ' ' . $spon->strSponSafeNameFL) . $clsRpt->closeRow() . $clsRpt->openRow() . $clsRpt->writeLabel('Sponsorship Program:') . $clsRpt->writeCell(htmlspecialchars($spon->strSponProgram)) . $clsRpt->closeRow() . $clsRpt->openRow() . $clsRpt->writeLabel('Client:'));
            if (is_null($spon->lClientID)) {
                echoT($clsRpt->writeCell('<i>Client not set</i>'));
            } else {
                echoT($clsRpt->writeCell(strLinkView_Client($spon->lClientID, 'View client record', true) . ' ' . $spon->strClientSafeNameFL . ' (' . htmlspecialchars($spon->strLocation) . ')'));
            }
            echoT($clsRpt->closeRow());
        }
    }
    echoT($clsRpt->closeReport());
    $attributes = new stdClass();
    $attributes->bCloseDiv = true;
    closeBlock($attributes);
}