1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
|
$pdf=new PDF('L','mm','A4');
$pdf->Open();
$pdf->AliasNbPages();
$pdf->AddPage();
$pdf->SetFont('Times','',8);
while ($row = oci_fetch_array($stid, OCI_ASSOC))
{
$cge=$row['COD_CGE'];
$total =0;
$pdf->SetY(40);
$pdf->Cell(10,0,"Centre de gestion", 0);
$pdf->SetX(40);
$pdf->Cell(10,0,$cge,0);
$pdf->SetY(50);
while ($cge=$row['COD_CGE'] )
{
//echo $row['LIB_NOM_TIT_RMB'];
$pdf->Cell(20,8,$row['COD_CGE'],'LRTB',0,'L');
$pdf->Cell(50,8,$row['LIB_NOM_TIT_RMB'],'LRTB',0,'L');
$pdf->Cell(50,8,$row['LIB_NOM_TIT_RMB'],'LRTB',0,'L');
$pdf->Cell(50,8,$row['LIB_BQE_RMB'],'LRTB',0,'L');
$pdf->Cell(20,8,$row['COD_BQE_RMB'],'LRTB',0,'L');
$pdf->Cell(20,8,$row['COD_GUI_BQE_RMB'],'LRTB',0,'L');
$pdf->Cell(20,8,$row['NUM_CPT_BQE_RMB'],'LRTB',0,'L');
$pdf->Cell(25,8,"Date Remb.",'LRTB',0,'L');
$pdf->Cell(25,8,$row['MONTANT'],'LRTB',1,'L');
$total = ($total+$row['MONTANT']);
$row = oci_fetch_array($stid, OCI_ASSOC);
}
$pdf->SetY(170);
$pdf->SetX(240);
$pdf->Cell(25,10,"Total",'LRTB',0,'L');
$pdf->Cell(25,10,$total,'LRTB',0,'L');
}
$pdf->Output(); |
Partager