예제 #1
0
	,html_entity_decode($ds['Title'])
	,array('NewPageCallback' => 'NewPageCallback'
			,'cols'=>array(
				'Nummer'=>array('justification'=>'left')
				,'InKrSumma'=>array('justification'=>'right')
				,'InKr'=>array('justification'=>'right')
				,'Admin'=>array('justification'=>'right')
				
				)
			));
$result2 = $db->Query($ds['QueryTotal'] . " LIMIT 0,2000");

$row = $db->GetRow($result2);
$row['OutKr'] = number_format($row['OutKr'],2,',','.');
$data[] = $row;
$pdf->ezText("<i>Antal poster:</i> ".$row['items']." <i>Outkr Total:</i> ".$row['OutKr'],12,array('justification'=>'center'));

function doHeader($pdf,$pageno,$pages) {
	$text = 'Sida '.$pageno.' av '.$pages;
	$pdf->addText(($pdf->ez['pageWidth'] / 2)-strlen($text), 12, 9, $text); 			
}

$pdf->siHeadersAndFooters(array('AllPages'=>'doHeader'));
$pdf->doHeader('Utskrift '.date('Y-m-d'),10,'left');
$pdf->doHeader("<b>Trosgnistan</b>",10,'right');
$pdf->doFooter("<b>Trosgnistan</b>",10,'right');
$pdf->doFooter('Utskrift '.date('Y-m-d'),10,'left');

header('connection:close');
//following causes pdf to be displayed inside an iframe!
//Content-Disposition:	inline; filename="doc.pdf";
예제 #2
0
    and Fadderbarn.Area1 = '".$_REQUEST['area']."'
	Order by Fadderbarn.Area DESC
";

    $result = $db->Query($query);
    $data = array();$tot = 0;
    while($row = $db->GetRow($result)) {$tot += $row["publicKr"];
        $data[] = $row;
    }
    
    //add a totals row...
    $row = array();
    $row["publicKr"] = "<b>".$tot."</b>";$row["Fadderbarn.Name"] = "Total";
    $data[] = $row;
    
    $pdf->ezText("<b>VERY IMPORTANT! Trosgnistan have increased the support for most of the children from last year. See the list. Be sure that 90% of the support reach the children. Please read the new text.</b>");
    $pdf->ezSetDy(-30);
    $pdf->ezText("Children list $area $areaName");
    $pdf->ezSetDy(-15);
    $pdf->ezTable(
        $data
        //columns
	    ,array('Fadderbarn.Area1'=>'<b>Area</b>'  
                ,'Fadderbarn.Id'=>'<b>Childno.</b>'  
                ,'Fadderbarn.Name'=>'<b>Name of Child</b>'  
                ,'Giver.Id'=>'<b>Sponsor</b>'  
                ,'Giver.Name'=>'<b>Givare</b>'  
                ,'publicKr'=>'<b>Sek p/mon.</b>'  
                
        )
	    ,""
예제 #3
0
$data = array();
$result = $db->Query($ds['Query'] . " LIMIT 0,2000");
$row = $db->GetRow($result);
$result2 = $db->Query($ds['QueryTotal'] . " LIMIT 0,2000");
$totRow = $db->GetRow($result2);
$result3 = $db->Query($OKTotal . " LIMIT 0,2000");
$okRow = $db->GetRow($result3);
$row['Total'] = number_format($row['Total'],2,',','.');
$totRow['Belopp'] = number_format($totRow['Belopp'],2,',','.');

/*
print "<pre>";
var_dump($data);
exit();*/

$pdf->ezText("<b>Kontroll av import från Postgirot</b>\n\n");
$pdf->ezText("\t\tNamn på betalningsmottargaren: ".$row['AccountName']."\n\n");
$pdf->ezText("\tDatum: " . $row['Date']."\n");
$pdf->ezText("\tAntal inbetalningar ");
$pdf->ezText("\t\t\t\t\t\t".$row['Rows']." - beräknad");
$pdf->ezText("\t\t\t\t\t\t".$totRow['items']." - angiven");
$pdf->ezText("");
$pdf->ezText("\tSumma inbetalningar ");
$pdf->ezText("\t\t\t\t\t\t".$row['Total']." - beräknad");
$pdf->ezText("\t\t\t\t\t\t".$totRow['Belopp']." - angiven");
//.$row['items']." <i>Total:</i> ".$row['Belopp'],12,array('justification'=>'center'));
$pdf->ezText("");
$pdf->ezText("\tKod (AccountNr): " . $row['AccountNr']."\n");
$pdf->ezText("\tAntal fel: " . ($totRow['items'] - $okRow['ok']));

function doHeader($pdf,$pageno,$pages) {
예제 #4
0
				,'Payment.InKrTotal' => array('justification'=>'right')
				,'InKr'=>array('justification'=>'right')
				,'Admin'=>array('justification'=>'right')
				
				)
			));
$result2 = $db->Query($ds['QueryTotal'] . " LIMIT 0,2000");

/*
$row = $db->GetRow($result2);
$row['InKrTotal'] = number_format($row['InKrTotal'],2,',','.');
$row['Admin'] = number_format($row['Admin'],2,',','.');
$data[] = $row;
$pdf->ezText("<i>Antal poster:</i> ".$row['items']." <i>Inkr Total:</i> ".$row['InKrTotal']." <i>Admin Total:</i> ".$row['Admin'],12,array('justification'=>'center'));
*/
$pdf->ezText("<i>Antal poster:</i> ".count($data)." <i>Inkr Total:</i> $inTot",12,array('justification'=>'center'));

function doHeader($pdf,$pageno,$pages) {
	$text = 'Sida '.$pageno.' av '.$pages;
	$pdf->addText(($pdf->ez['pageWidth'] / 2)-strlen($text), 12, 9, $text); 			
}

$pdf->siHeadersAndFooters(array('AllPages'=>'doHeader'));
$pdf->doHeader('Utskrift '.date('Y-m-d'),10,'left');
$pdf->doHeader("<b>Trosgnistan</b>",10,'right');
$pdf->doFooter("<b>Trosgnistan</b>",10,'right');
$pdf->doFooter('Utskrift '.date('Y-m-d'),10,'left');

header('connection:close');
//following causes pdf to be displayed inside an iframe!
//Content-Disposition:	inline; filename="doc.pdf";