Пример #1
0
 function compose()
 {
     $lines = $this->docVars->getRigo();
     while (list($key, $rigo) = each($lines)) {
         if ($this->GetY() >= 215) {
             $this->Cell(155, 6, '', 'T', 1);
             $this->SetFont('helvetica', '', 20);
             $this->SetY(225);
             $this->Cell(185, 12, '>>> --- CONTINÚA EN LA PÁGINA SIGUIENTE --- >>> ', 1, 1, 'R');
             $this->SetFont('helvetica', '', 9);
             $this->newPage();
             $this->Cell(185, 5, '<<< ---VIENE DE LA PÁGINA ANTERIOR --- <<< ', 0, 1);
         }
         if ($rigo['tiprig'] < 2) {
             $this->Cell(30, 6, $rigo['codart'], 1, 0, 'L');
             $this->Cell(82, 6, $rigo['descri'], 1, 0, 'L');
             $this->Cell(10, 6, $rigo['unimis'], 1, 0, 'L');
             $this->Cell(30, 6, gaz_format_quantity($rigo['quanti'], 1, $this->decimal_quantity), 1, 0, 'R');
             if ($this->docVars->client['stapre'] == 'S') {
                 $this->Cell(25, 6, number_format($rigo['prelis'], $this->decimal_price, ',', ''), 'TB', 0, 'R');
                 $this->Cell(10, 6, $rigo['sconto'], 1, 1, 'R');
             } else {
                 $this->Cell(25, 6);
                 $this->Cell(10, 6, '', 'R', 1);
             }
         } elseif ($rigo['tiprig'] == 2) {
             $this->Cell(30, 6, '', 'L');
             $this->Cell(122, 6, $rigo['descri'], 'LR');
             $this->Cell(35, 6, '', 'R', 1);
         } elseif ($rigo['tiprig'] == 6) {
             $this->writeHtmlCell(187, 6, 10, $this->GetY(), $rigo['descri'], 1, 1);
         }
     }
 }
Пример #2
0
 function body()
 {
     $lines = $this->docVars->getRigo();
     while (list($key, $rigo) = each($lines)) {
         if ($this->GetY() >= 185) {
             $this->Cell(186, 6, '', 'T', 1);
             $this->SetFont('helvetica', '', 20);
             $this->SetY(225);
             $this->Cell(186, 12, '>>> --- CONTINUA EN LA PAGINA SIGUIENTE --- >>> ', 1, 1, 'R');
             $this->SetFont('helvetica', '', 9);
             $this->newPage();
             $this->Cell(186, 5, '<<< --- VIENE DE LA PAGINA ANTERIOR --- <<< ', 0, 1);
         }
         switch ($rigo['tiprig']) {
             case "0":
                 $this->Cell(25, 6, $rigo['codart'], 1, 0, 'L');
                 $this->Cell(80, 6, $rigo['descri'], 1, 0, 'L');
                 $this->Cell(7, 6, $rigo['unimis'], 1, 0, 'C');
                 $this->Cell(16, 6, gaz_format_quantity($rigo['quanti'], 1, $this->decimal_quantity), 1, 0, 'R');
                 $this->Cell(18, 6, number_format($rigo['prelis'], $this->decimal_price, ',', '.'), 1, 0, 'R');
                 if ($rigo['sconto'] > 0) {
                     $this->Cell(8, 6, number_format($rigo['sconto'], 1, ',', ''), 1, 0, 'C');
                 } else {
                     $this->Cell(8, 6, '', 1, 0, 'C');
                 }
                 $this->Cell(20, 6, gaz_format_number($rigo['importo']), 1, 0, 'R');
                 $this->Cell(12, 6, gaz_format_number($rigo['pervat']), 1, 1, 'R');
                 break;
             case "1":
                 $this->Cell(25, 6, $rigo['codart'], 1, 0, 'L');
                 $this->Cell(80, 6, $rigo['descri'], 1, 0, 'L');
                 $this->Cell(49, 6, '', 1);
                 $this->Cell(20, 6, gaz_format_number($rigo['importo']), 1, 0, 'R');
                 $this->Cell(12, 6, gaz_format_number($rigo['pervat']), 1, 1, 'R');
                 break;
             case "2":
                 $this->Cell(25, 6, '', 'L');
                 $this->Cell(80, 6, $rigo['descri'], 'LR', 0, 'L');
                 $this->Cell(81, 6, '', 'R', 1);
                 break;
             case "3":
                 $this->Cell(25, 6, '', 1, 0, 'L');
                 $this->Cell(80, 6, $rigo['descri'], 'B', 0, 'L');
                 $this->Cell(49, 6, '', 'B', 0, 'L');
                 $this->Cell(20, 6, gaz_format_number($rigo['prelis']), 1, 0, 'R');
                 $this->Cell(12, 6, '', 1, 1, 'R');
                 break;
             case "6":
                 $this->writeHtmlCell(186, 6, 10, $this->GetY(), $rigo['descri'], 1, 1);
                 break;
         }
         if ($rigo['ritenuta'] > 0) {
             $this->Cell(154, 5, 'Retención de anticipo al ' . gaz_format_number($rigo['ritenuta']) . '%', 'LB', 0, 'R');
             $this->Cell(20, 5, gaz_format_number(round($rigo['importo'] * $rigo['ritenuta'] / 100, 2)), 'RB', 0, 'R');
             $this->Cell(12, 5, '', 1, 1, 'R');
         }
     }
 }
Пример #3
0
 function body()
 {
     $lines = $this->docVars->getRigo();
     while (list($key, $rigo) = each($lines)) {
         if ($this->GetY() >= 185) {
             $this->Cell(186, 6, '', 'T', 1);
             $this->SetFont('helvetica', '', 20);
             $this->SetY(225);
             $this->Cell(186, 12, '>>> --- SEGUE SU PAGINA SUCCESSIVA --- >>> ', 1, 1, 'R');
             $this->SetFont('helvetica', '', 9);
             $this->newPage();
             $this->Cell(186, 5, '<<< --- SEGUE DA PAGINA PRECEDENTE --- <<< ', 0, 1);
         }
         switch ($rigo['tiprig']) {
             case "0":
                 $this->Cell(25, 6, $rigo['codart'], 1, 0, 'L');
                 $this->Cell(80, 6, $rigo['descri'], 1, 0, 'L');
                 $this->Cell(7, 6, $rigo['unimis'], 1, 0, 'C');
                 $this->Cell(16, 6, gaz_format_quantity($rigo['quanti'], 1, $this->decimal_quantity), 1, 0, 'R');
                 if ($rigo['prelis'] > 0) {
                     $this->Cell(18, 6, number_format($rigo['prelis'], $this->decimal_price, ',', ''), 1, 0, 'R');
                 } else {
                     $this->Cell(18, 6, '', 1);
                 }
                 if ($rigo['sconto'] > 0) {
                     $this->Cell(8, 6, number_format($rigo['sconto'], 1, ',', ''), 1, 0, 'C');
                 } else {
                     $this->Cell(8, 6, '', 1);
                 }
                 if ($rigo['importo'] > 0) {
                     $this->Cell(20, 6, gaz_format_number($rigo['importo']), 1, 0, 'R');
                 } else {
                     $this->Cell(20, 6, '', 1);
                 }
                 $this->Cell(12, 6, gaz_format_number($rigo['pervat']), 1, 1, 'R');
                 break;
             case "1":
                 $this->Cell(25, 6, '', 'LBR', 0, 'L');
                 $this->Cell(80, 6, $rigo['descri'], 'LBR', 0, 'L');
                 $this->Cell(49, 6, '', 1);
                 $this->Cell(20, 6, gaz_format_number($rigo['importo']), 1, 0, 'R');
                 $this->Cell(12, 6, gaz_format_number($rigo['pervat']), 1, 1, 'R');
                 break;
             case "2":
                 $this->Cell(25, 6, '', 'L');
                 $this->Cell(80, 6, $rigo['descri'], 'LR', 0, 'L');
                 $this->Cell(81, 6, '', 'R', 1);
                 break;
             case "3":
                 $this->Cell(25, 6, '', 1, 0, 'L');
                 $this->Cell(80, 6, $rigo['descri'], 'B', 0, 'L');
                 $this->Cell(49, 6, '', 'B', 0, 'L');
                 $this->Cell(20, 6, gaz_format_number($rigo['prelis']), 1, 0, 'R');
                 $this->Cell(12, 6, '', 1, 1, 'R');
                 break;
         }
     }
 }
Пример #4
0
 function compose()
 {
     $lines = $this->docVars->getRigo();
     while (list($key, $rigo) = each($lines)) {
         if ($this->GetY() >= 215) {
             $this->Cell(155, 6, '', 'T', 1);
             $this->SetFont('helvetica', '', 20);
             $this->SetY(225);
             $this->Cell(185, 12, '>>> --- SEGUE SU PAGINA SUCCESSIVA --- >>> ', 1, 1, 'R');
             $this->SetFont('helvetica', '', 9);
             $this->newPage();
             $this->Cell(185, 5, '<<< --- SEGUE DA PAGINA PRECEDENTE --- <<< ', 0, 1);
         }
         if ($rigo['tiprig'] < 2) {
             $this->Cell(30, 6, $rigo['codart'], 1, 0, 'L');
             $this->Cell(82, 6, $rigo['descri'], 1, 0, 'L', 0, '', 1);
             $this->Cell(10, 6, $rigo['unimis'], 1, 0, 'L');
             $this->Cell(30, 6, gaz_format_quantity($rigo['quanti'], 1, $this->decimal_quantity), 1, 0, 'R');
             if ($this->docVars->client['stapre'] == 'S') {
                 $this->Cell(25, 6, number_format($rigo['prelis'], $this->decimal_price, ',', ''), 'TB', 0, 'R');
                 $this->Cell(10, 6, $rigo['sconto'], 1, 1, 'R');
             } else {
                 $this->Cell(25, 6);
                 $this->Cell(10, 6, '', 'R', 1);
             }
         } elseif ($rigo['tiprig'] == 2) {
             $this->Cell(30, 6, '', 'L');
             $this->Cell(122, 6, $rigo['descri'], 'LR');
             $this->Cell(35, 6, '', 'R', 1);
         } elseif ($rigo['tiprig'] == 6 || $rigo['tiprig'] == 7) {
             $this->writeHtmlCell(187, 6, 10, $this->GetY(), $rigo['descri'], 1, 1);
         } elseif ($rigo['tiprig'] == 11) {
             $this->Cell(30, 6, '', 'L');
             $this->Cell(122, 6, "CIG: " . $rigo['descri'], 'LR', 0, 'L');
             $this->Cell(35, 6, '', 'R', 1);
         } elseif ($rigo['tiprig'] == 12) {
             $this->Cell(30, 6, '', 'L');
             $this->Cell(122, 6, "CUP: " . $rigo['descri'], 'LR', 0, 'L');
             $this->Cell(35, 6, '', 'R', 1);
         } elseif ($rigo['tiprig'] == 13) {
             $this->Cell(30, 6, '', 'L');
             $this->Cell(122, 6, "IdDocumento: " . $rigo['descri'], 'LR', 0, 'L');
             $this->Cell(35, 6, '', 'R', 1);
         }
     }
 }
Пример #5
0
 function body()
 {
     $lines = $this->docVars->getRigo();
     while (list($key, $rigo) = each($lines)) {
         if ($this->GetY() >= 195) {
             $this->Cell(186, 6, '', 'T', 1);
             $this->SetFont('helvetica', '', 14);
             $this->SetY(225);
             $this->Cell(186, 12, '>>> --- CONTINUA EN LA PAGINA SIGUIENTE --- >>> ', 1, 1, 'R');
             $this->SetFont('helvetica', '', 9);
             $this->newPage();
             $this->Cell(186, 5, '<<< --- VIENE DE LA PAGINA ANTERIOR --- <<< ', 0, 1);
         }
         switch ($rigo['tiprig']) {
             case "0":
                 $this->Cell(105, 5, $rigo['descri'], 1, 0, 'L');
                 $this->Cell(7, 5, $rigo['unimis'], 1, 0, 'C');
                 $this->Cell(16, 5, gaz_format_quantity($rigo['quanti'], 1, $this->decimal_quantity), 1, 0, 'R');
                 $this->Cell(18, 5, number_format($rigo['prelis'], $this->decimal_price, ',', ''), 1, 0, 'R');
                 if ($rigo['sconto'] > 0) {
                     $this->Cell(8, 5, number_format($rigo['sconto'], 1, ',', ''), 1, 0, 'C');
                 } else {
                     $this->Cell(8, 5, '', 1, 0, 'C');
                 }
                 $this->Cell(20, 5, gaz_format_number($rigo['importo']), 1, 0, 'R');
                 $this->Cell(12, 5, gaz_format_number($rigo['pervat']), 1, 1, 'R');
                 break;
             case "1":
                 $this->Cell(105, 5, $rigo['descri'], 1, 0, 'L');
                 $this->Cell(49, 5, '', 1);
                 $this->Cell(20, 5, gaz_format_number($rigo['importo']), 1, 0, 'R');
                 $this->Cell(12, 5, gaz_format_number($rigo['pervat']), 1, 1, 'R');
                 break;
             case "2":
                 $this->Cell(105, 5, $rigo['descri'], 'LR', 0, 'L');
                 $this->Cell(81, 5, '', 'R', 1);
                 break;
         }
     }
 }
Пример #6
0
       if ($rigo['id_body_text'] > 0) { //se ho un rigo testo
           $text = gaz_dbi_get_row($gTables['body_text'],"id_body",$rigo['id_body_text']);
           $form["row_$next_row"] = $text['body_text'];
       }
       $form['rows'][$next_row]['descri'] = $rigo['descri'];
       $form['rows'][$next_row]['tiprig'] = $rigo['tiprig'];
       $form['rows'][$next_row]['id_doc'] = $rigo['id_doc'];
       $form['rows'][$next_row]['codart'] = $rigo['codart'];
       $form['rows'][$next_row]['pervat'] = $rigo['pervat'];
       $iva_row = gaz_dbi_get_row($gTables['aliiva'],'codice',$rigo['codvat']);
       $form['rows'][$next_row]['tipiva'] = $iva_row['tipiva'];
       $form['rows'][$next_row]['ritenuta'] = $rigo['ritenuta'];
       $form['rows'][$next_row]['unimis'] = $rigo['unimis'];
       $form['rows'][$next_row]['prelis'] = number_format($rigo['prelis'],$admin_aziend['decimal_price'],'.','');
       $form['rows'][$next_row]['sconto'] = $rigo['sconto'];
       $form['rows'][$next_row]['quanti'] = gaz_format_quantity($rigo['quanti'],0,$admin_aziend['decimal_quantity']);
       $form['rows'][$next_row]['codvat'] = $rigo['codvat'];
       $form['rows'][$next_row]['codric'] = $rigo['codric'];
       $form['rows'][$next_row]['provvigione'] = $rigo['provvigione'];
       $form['rows'][$next_row]['id_mag'] = $rigo['id_mag'];
       $form['rows'][$next_row]['annota'] = $articolo['annota'];
       $mv=$upd_mm->getStockValue(false,$rigo['codart'],$form['annemi'].'-'.$form['mesemi'].'-'.$form['gioemi'],$admin_aziend['stock_eval_method']);
       $magval=array_pop($mv);
       $form['rows'][$next_row]['scorta'] = $magval['q_g'] - $articolo['scorta'];
       $form['rows'][$next_row]['pesosp'] = $articolo['peso_specifico'];
       $form['rows'][$next_row]['status'] = "UPDATE";
       $next_row++;
    }
} elseif (!isset($_POST['Insert'])) { //se e' il primo accesso per INSERT
    $form['tipdoc'] = $_GET['tipdoc'];
    $form['id_tes'] = "";
Пример #7
0
    $result = gaz_dbi_dyn_query($gTables['rigdoc'].".*,".$gTables['tesdoc'].".id_tes,".$gTables['tesdoc'].".tipdoc,".$gTables['tesdoc'].".numdoc,".$gTables['tesdoc'].".datemi,".$gTables['tesdoc'].".datfat,".$gTables['tesdoc'].".imball,".$gTables['tesdoc'].".clfoco,".$gTables['tesdoc'].".caumag,".$gTables['tesdoc'].".sconto as scochi", $gTables['rigdoc']." LEFT JOIN ".$gTables['tesdoc']." ON ".$gTables['rigdoc'].".id_tes = ".$gTables['tesdoc'].".id_tes LEFT JOIN ".$gTables['caumag']." ON ".$gTables['tesdoc'].".caumag = ".$gTables['caumag'].".codice", "tiprig = 0 AND id_mag = 0 AND caumag > 0 AND datemi BETWEEN $datainizio AND $datafine ", " datemi ASC, ".$gTables['tesdoc'].".id_tes ASC, id_rig ASC");
    $numrow = gaz_dbi_num_rows($result);
    echo "<table class=\"Tlarge\">";
    if ($numrow > 0) {
       echo "<tr><td class=\"FacetFieldCaptionTD\" colspan=\"6\" >$numrow ".$script_transl[5]."</td></tr>";
       require("../../modules/vendit/lang.".$admin_aziend['lang'].".php");
       $desdoc = $strScript["admin_docven.php"][0];
       require("../../modules/acquis/lang.".$admin_aziend['lang'].".php");
       $desdoc += $strScript["admin_docacq.php"][0];
       while ($row = gaz_dbi_fetch_array($result)) {
             echo "<tr>\n";
             $valore = CalcolaImportoRigo($row['quanti'], $row['prelis'], $row['sconto']) ;
             $valore = CalcolaImportoRigo(1, $valore, $row['scochi']) ;
             $descri = $desdoc[$row['tipdoc']]." n.".$row['numdoc'];
             echo "<td class=\"FacetDataTD\" align=\"center\">".gaz_format_date($row["datemi"])." &nbsp;</td>\n";
             echo "<td class=\"FacetDataTD\" align=\"center\">".$row["caumag"]." - ".$row["descri"]."</td>\n";
             echo "<td class=\"FacetDataTD\" align=\"center\">$descri</td>\n";
             echo "<td class=\"FacetDataTD\" align=\"center\">".$row["codart"]."</td>\n";
             echo "<td class=\"FacetDataTD\" align=\"center\">".gaz_format_quantity($row["quanti"],1,$admin_aziend['decimal_quantity'])."</td>\n";
             echo "<td class=\"FacetDataTD\" align=\"right\">".gaz_format_number($valore)." </td>";
             echo "</tr>\n";
       }
       echo "<tr><td colspan=\"6\" align=\"center\"><input type=\"submit\" name=\"insert\" value=\"".strtoupper($script_transl[0])." !\"></TD></TR>";
    } else {
       echo "<tr><td class=\"FacetDataTDred\" align=\"center\">".$script_transl[6]."</td></tr>";
    }
}
?>
</form>
</body>
</html>
Пример #8
0
    $form['sconto'] = $tesdoc['sconto'];
    $i = 0;
    while ($row = gaz_dbi_fetch_array($rs_rig)) {
        $articolo = gaz_dbi_get_row($gTables['artico'],"codice",$row['codart']);
        if ($row['id_body_text'] > 0) { //se ho un rigo testo
            $text = gaz_dbi_get_row($gTables['body_text'],"id_body",$row['id_body_text']);
            $form["row_$i"] = $text['body_text'];
        }
        $form['rows'][$i]['descri'] = $row['descri'];
        $form['rows'][$i]['tiprig'] = $row['tiprig'];
        $form['rows'][$i]['codart'] = $row['codart'];
        $form['rows'][$i]['pervat'] = $row['pervat'];
        $form['rows'][$i]['unimis'] = $row['unimis'];
        $form['rows'][$i]['prelis'] = $row['prelis'];
        $form['rows'][$i]['sconto'] = $row['sconto'];
        $form['rows'][$i]['quanti'] = gaz_format_quantity($row['quanti'],0,$admin_aziend['decimal_quantity']);
        $form['rows'][$i]['codvat'] = $row['codvat'];
        $form['rows'][$i]['codric'] = $row['codric'];
        $form['rows'][$i]['id_mag'] = $row['id_mag'];
        $form['rows'][$i]['annota'] = $articolo['annota'];
        $form['rows'][$i]['pesosp'] = $articolo['peso_specifico'];
        $form['rows'][$i]['lot_or_serial'] = $articolo['lot_or_serial'];
        $form['rows'][$i]['status'] = "UPDATE";
        // recupero eventuale movimento di tracciabilità
        $form['lotmag'][$i] = gaz_dbi_get_row($gTables['lotmag'],'id_purchase',$row['id_rig']);
        $i++;
    }
} elseif (!isset($_POST['Insert'])) { //se e' il primo accesso per INSERT
    $form['tipdoc'] = $_GET['tipdoc'];
    $form['hidden_req'] = '';
    $form['id_tes'] = "";
Пример #9
0
 function body()
 {
     $lines = $this->docVars->getRigo();
     while (list($key, $rigo) = each($lines)) {
         if ($this->GetY() >= 166 && $this->taxstamp >= 0.01 || $this->GetY() >= 195) {
             $this->Cell(186, 6, '', 'T', 1);
             $this->SetFont('helvetica', '', 14);
             $this->SetY(225);
             $this->Cell(186, 12, '>>> --- SEGUE SU PAGINA SUCCESSIVA --- >>> ', 1, 1, 'R');
             $this->SetFont('helvetica', '', 9);
             $this->newPage();
             $this->Cell(186, 5, '<<< --- SEGUE DA PAGINA PRECEDENTE --- <<< ', 0, 1);
         }
         switch ($rigo['tiprig']) {
             case "0":
                 $this->Cell(25, 5, $rigo['codart'], 1, 0, 'L');
                 $this->Cell(80, 5, $rigo['descri'], 1, 0, 'L');
                 $this->Cell(7, 5, $rigo['unimis'], 1, 0, 'C');
                 $this->Cell(16, 5, gaz_format_quantity($rigo['quanti'], 1, $this->decimal_quantity), 1, 0, 'R');
                 $this->Cell(18, 5, number_format($rigo['prelis'], $this->decimal_price, ',', ''), 1, 0, 'R');
                 if ($rigo['sconto'] > 0) {
                     $this->Cell(8, 5, number_format($rigo['sconto'], 1, ',', ''), 1, 0, 'C');
                 } else {
                     $this->Cell(8, 5, '', 1, 0, 'C');
                 }
                 $this->Cell(20, 5, gaz_format_number($rigo['importo']), 1, 0, 'R');
                 $this->Cell(12, 5, gaz_format_number($rigo['pervat']), 1, 1, 'R');
                 break;
             case "1":
                 $this->Cell(25, 5, '', 1, 0, 'L');
                 $this->Cell(80, 5, $rigo['descri'], 1, 0, 'L');
                 $this->Cell(49, 5, '', 1);
                 $this->Cell(20, 5, gaz_format_number($rigo['importo']), 1, 0, 'R');
                 $this->Cell(12, 5, gaz_format_number($rigo['pervat']), 1, 1, 'R');
                 break;
             case "2":
                 $this->Cell(25, 5, '', 'L');
                 $this->Cell(80, 5, $rigo['descri'], 'LR', 0, 'L');
                 $this->Cell(81, 5, '', 'R', 1);
                 break;
             case "3":
                 $this->Cell(25, 5, '', 1, 0, 'L');
                 $this->Cell(80, 5, $rigo['descri'], 'B', 0, 'L');
                 $this->Cell(49, 5, '', 'B', 0, 'L');
                 $this->Cell(20, 5, gaz_format_number($rigo['prelis']), 1, 0, 'R');
                 $this->Cell(12, 5, '', 1, 1, 'R');
                 break;
             case "6":
                 $this->writeHtmlCell(186, 6, 10, $this->GetY(), $rigo['descri'], 1, 1);
                 break;
         }
         if ($rigo['ritenuta'] > 0) {
             $this->Cell(154, 5, 'Ritenuta d\'acconto al ' . gaz_format_number($rigo['ritenuta']) . '%', 'LB', 0, 'R');
             $this->Cell(20, 5, gaz_format_number(round($rigo['importo'] * $rigo['ritenuta'] / 100, 2)), 'RB', 0, 'R');
             $this->Cell(12, 5, '', 1, 1, 'R');
         }
     }
     if ($this->taxstamp >= 0.01) {
         if ($this->virtual_taxstamp == 2 || $this->virtual_taxstamp == 3) {
             $this->Cell(186, 5, '', 'LR', 1);
             $this->Cell(130, 8, '', 'L', 0, 0);
             $this->Cell(56, 8, "Bollo assolto ai sensi del", "TLR", 1, "C");
             $this->Cell(130, 8, '', 'L', 0, 0);
             $this->Cell(56, 8, "decreto MEF 17.06.2014 (art.6)", "LR", 1, "C");
             $this->Cell(130, 8, '', 'L', 0, 0);
             $this->Cell(56, 8, " € " . gaz_format_number($this->taxstamp), 'LR', 1, 'C');
         } else {
             $this->Cell(186, 5, '', 'LR', 1);
             $this->Cell(150, 8, '', 'L', 0, 0);
             $this->Cell(36, 8, "Bollo applicato", "TLR", 1, "C");
             $this->Cell(150, 8, '', 'L', 0, 0);
             $this->Cell(36, 8, "sull'originale", "LR", 1, "C");
             $this->Cell(150, 8, '', 'L', 0, 0);
             $this->Cell(36, 8, "€ " . gaz_format_number($this->taxstamp), 'LR', 1, 'C');
         }
     }
 }
Пример #10
0
	$exporter->addRow( array( "Categoria", "Codice", "Descrizione","Valore Unitario", "Quantita", "Giac.", "Val Totale", "Alla Data: ". $date ) );
	$elem_n=0;
	
	foreach($form['a'] as $k=>$v) {
		if ($ctrl_cm <> $v['i_g']) {
			$ctrl_cm = $v['i_g'];
		}
		
		$exporter->addRow(
				array(
						$v['g_d'],
						"-$k-",
						$v['i_d'],
						gaz_format_quantity($v['v_a'],0,$admin_aziend['decimal_price'] ),
						gaz_format_quantity($v['g_a'],0,$admin_aziend['decimal_quantity'] ),
						gaz_format_quantity($v['v_g'],0,$admin_aziend['decimal_price'] ),
				));
		
		$elem_n++;
	}
}

$exporter->addRow(
		array(
				"",
				"",
				"",
				"Valore Totale Magazzino",
				"",
				$tot_val_giac,
		));
Пример #11
0
        $linkHeaders=new linkHeaders($script_transl['header']);
        $linkHeaders->output();
        echo "</tr>";
        $sum=0.00;
        while (list($key, $mv) = each($m)) {
            $datedoc = substr($mv['datdoc'],8,2).'-'.substr($mv['datdoc'],5,2).'-'.substr($mv['datdoc'],0,4);
            $datereg = substr($mv['datreg'],8,2).'-'.substr($mv['datreg'],5,2).'-'.substr($mv['datreg'],0,4);
            $movQuanti = $mv['quanti']*$mv['operat'];
            $sum += $movQuanti;
            echo "<tr><td class=\"FacetDataTD\">".$datereg." &nbsp;</td>";
            echo "<td  align=\"center\" class=\"FacetDataTD\">".$mv['caumag'].'-'.substr($mv['descri'],0,20)." &nbsp</td>";
            echo "<td class=\"FacetDataTD\">".substr($mv['desdoc'].' del '.$datedoc.' - '.$mv['ragsoc'],0,85)." &nbsp;</td>";
            echo "<td align=\"right\" class=\"FacetDataTD\">".number_format($mv['prezzo'],$admin_aziend['decimal_price'],',','.')." &nbsp;</td>";
            echo "<td align=\"right\" class=\"FacetDataTD\">".gaz_format_number(CalcolaImportoRigo($mv['quanti'],$mv['prezzo'],array($mv['scochi'],$mv['scorig'])))." &nbsp;</td>";
            echo "<td align=\"right\" class=\"FacetDataTD\">".$mv['unimis']." &nbsp;</td>\n";
            echo "<td align=\"right\" class=\"FacetDataTD\">".gaz_format_quantity($movQuanti,1,$admin_aziend['decimal_quantity'])." &nbsp;</td>\n";
            echo "</tr>\n";
            $ctr_mv = $mv['artico'];
         }
         echo "\t<tr class=\"FacetFieldCaptionTD\">\n";
         echo '<td colspan="7" align="right"><input type="submit" name="print" value="';
         echo $script_transl['print'];
         echo '">';
         echo "\t </td>\n";
         echo "\t </tr>\n";
  }
  echo "</table></form>";
}
?>
</body>
</html>
Пример #12
0
$pdf->Cell(50,4,$script_transl['bank'],'LTB',0);
$pdf->Cell(11,4,':','TB',0,'R');
$pdf->Cell(125,4,$bank['descri'],'RTB',1);
$pdf->Cell(50,4,$script_transl['doc_type'],'LTB',0);
$pdf->Cell(11,4,':','TB',0,'R');
$pdf->Cell(125,4,$script_transl['doc_type_value'][$contract['doc_type']],'RTB',1);
$pdf->Cell(50,4,$script_transl['cod_revenue'],'LTB',0);
$pdf->Cell(11,4,':','TB',0,'R');
$pdf->Cell(125,4,$contract['cod_revenue'].' - '.$revenue['descri'],'RTB',1);
$pdf->Cell(50,4,$script_transl['vat_code'],'LTB',0);
$pdf->Cell(11,4,':','TB',0,'R');
$pdf->Cell(125,4,$contract['vat_code'].' - '.$vat['descri'],'RTB',1);
$pdf->Cell(50,4,$script_transl['initial_fee'],'LTB',0);
$pdf->Cell(11,4,':','TB',0,'R');
$pdf->Cell(125,4,$contract['initial_fee'],'RTB',1);
$pdf->Ln(4);
if (gaz_dbi_num_rows($rs_rows)){
   $pdf->Cell(186,4,$script_transl['rows_title'],0,1,'C');
}
while ($row = gaz_dbi_fetch_array($rs_rows)) {
      $importo = CalcolaImportoRigo($row['quanti'], $row['price'], $row['discount']);
      $pdf->Cell(90,4,$row['descri'],1);
      $pdf->Cell(11,4,$row['unimis'],1,0,'C');
      $pdf->Cell(20,4,gaz_format_quantity($row['quanti'],1,$admin_aziend['decimal_quantity']),1,0,'R');
      $pdf->Cell(25,4,number_format($row['price'],$admin_aziend['decimal_price'],',',''),1,0,'R');
      $pdf->Cell(10,4,gaz_format_quantity($row['discount'],1,9),1,0,'R');
      $pdf->Cell(30,4,number_format($importo,2,',',''),1,1,'R');
}

$pdf->Output();
?>
Пример #13
0
             echo "<td class=\"FacetDataTD\" align=\"left\">".$v['i_u']."</td>\n";
             echo "<td class=\"FacetDataTD\" align=\"right\">".gaz_format_quantity($mq,0,$admin_aziend['decimal_quantity'])."</td>\n";
             echo "<td class=\"FacetDataTD\"></td>\n";
             echo "<td class=\"FacetDataTD\" align=\"right\">".$v['v_r']."</td>\n";
             echo "<td class=\"FacetDataTD\" align=\"right\">".gaz_format_quantity($v['v_r']*$mq,0,$admin_aziend['decimal_price'])."</td>\n";
             echo "</tr>\n";
           }
           echo "<tr>\n";
           echo "<td class=\"FacetDataTD\">99-".$cau99['descri']."</td>\n";
           echo "<td class=\"FacetDataTD\" align=\"left\">".$k."</td>\n";
           echo "<td class=\"FacetDataTD\" align=\"left\">".$v['i_d']."</td>\n";
           echo "<td class=\"FacetDataTD\" align=\"left\">".$v['i_u']."</td>\n";
           echo "<td class=\"FacetDataTD\" align=\"right\">".$v['g_r']."</td>\n";
           echo "<td class=\"FacetDataTD\"></td>\n";
           echo "<td class=\"FacetDataTD\" align=\"right\">".$v['v_r']."</td>\n";
           echo "<td class=\"FacetDataTD\" align=\"right\">".gaz_format_quantity($v['v_r']*$v['g_r'],0,$admin_aziend['decimal_price'])."</td>\n";
           echo "</tr>\n";
         }
       }
       echo "<tr><td align=\"right\" colspan=\"8\" class=\"FacetFooterTD\"><input type=\"submit\" name=\"insert\" value=\"".$script_transl['submit']."!\">&nbsp;</td></tr>\n";
   }
} else {
   echo "<tr>
      <td colspan=\"9\" class=\"FacetDataTDred\">".$script_transl['noitem']."</td>
      </tr>\n";

}
echo "</table>\n";
?>
</form>
</body>
Пример #14
0
              if ($ctrl_id <> $mv['id_mov']) {
                echo "<tr><td class=\"FacetDataTD\" rowspan=\"$r_span\">".gaz_format_date($mv['datreg'])." id:".$mv['id_mov']."</td>";
                echo "<td align=\"center\" class=\"FacetDataTD\" rowspan=\"$r_span\">".$mv['caumag'].'-'.substr($mv['descri'],0,20)."</td>";
                echo "<td class=\"FacetDataTD\" rowspan=\"$r_span\">".substr($mv['desdoc'].' del '.gaz_format_date($mv['datdoc']).' - '.$mv['ragso1'].' '.$mv['ragso2'],0,85)."</td>";
                echo "<td align=\"right\" class=\"FacetDataTD\" rowspan=\"$r_span\">".number_format($mv['prezzo'],$admin_aziend['decimal_price'],',','.')."</td>";
                echo "<td align=\"right\" class=\"FacetDataTD\" rowspan=\"$r_span\">".$mv['unimis']."</td>\n";
              } else {
                echo "<tr>";
              }
              echo "<td align=\"right\" class=\"FacetDataTD\">".gaz_format_quantity($mval['q']*$mv['operat'],1,$admin_aziend['decimal_quantity'])."</td>";
              if ($mv['operat']==1) {
                echo "<td align=\"right\" class=\"FacetDataTD\">".number_format($mval['v'],$admin_aziend['decimal_price'],',','')."</td><td></td>";
              } else {
                echo "<td></td><td align=\"right\" class=\"FacetDataTD\">".number_format($mval['v'],$admin_aziend['decimal_price'],',','')."</td>";
              }
              echo "<td align=\"right\" class=\"FacetDataTD\">".gaz_format_quantity($mval['q_g'],1,$admin_aziend['decimal_quantity'])."</td>";
              echo "<td align=\"right\" class=\"FacetDataTD\">".gaz_format_number($mval['v_g'])."</td>";
              echo "</tr>";
              $ctrl_id = $mv['id_mov'];
            }
            $ctr_mv = $mv['artico'];
         }
         echo "\t<tr class=\"FacetFieldCaptionTD\">\n";
         echo '<td colspan="10" align="right"><input type="submit" name="print" value="'.$script_transl['print'].'">';
         echo "\t </td>\n";
         echo "\t </tr>\n";
  }
  echo "</table></form>";
}
?>
</body>
Пример #15
0
 function body()
 {
     $lines = $this->docVars->getRigo();
     while (list($key, $rigo) = each($lines)) {
         if ($this->GetY() >= 166 && $this->docVars->taxstamp >= 0.01 || $this->GetY() >= 195) {
             // mi serve per poter stampare la casella del bollo
             $this->Cell(186, 6, '', 'T', 1);
             $this->SetFont('helvetica', '', 20);
             $this->SetY(225);
             $this->Cell(186, 12, '>>> --- SEGUE SU PAGINA SUCCESSIVA --- >>> ', 1, 1, 'R');
             $this->SetFont('helvetica', '', 9);
             $this->newPage();
             $this->Cell(186, 5, '<<< --- SEGUE DA PAGINA PRECEDENTE --- <<< ', 0, 1);
         }
         switch ($rigo['tiprig']) {
             case "0":
                 $this->Cell(25, 5, $rigo['codart'], 1, 0, 'L');
                 $this->Cell(80, 5, $rigo['descri'], 1, 0, 'L', 0, '', 1);
                 $this->Cell(7, 5, $rigo['unimis'], 1, 0, 'C');
                 $this->Cell(16, 5, gaz_format_quantity($rigo['quanti'], 1, $this->decimal_quantity), 1, 0, 'R');
                 $this->Cell(18, 5, number_format($rigo['prelis'], $this->decimal_price, ',', ''), 1, 0, 'R');
                 if ($rigo['sconto'] > 0) {
                     $this->Cell(8, 5, number_format($rigo['sconto'], 1, ',', ''), 1, 0, 'C');
                 } else {
                     $this->Cell(8, 5, '', 1, 0, 'C');
                 }
                 $this->Cell(20, 5, gaz_format_number($rigo['importo']), 1, 0, 'R');
                 $this->Cell(12, 5, gaz_format_number($rigo['pervat']), 1, 1, 'R');
                 break;
             case "1":
                 $this->Cell(25, 5, $rigo['codart'], 1, 0, 'L');
                 $this->Cell(80, 5, $rigo['descri'], 1, 0, 'L');
                 $this->Cell(49, 5, '', 1);
                 $this->Cell(20, 5, gaz_format_number($rigo['importo']), 1, 0, 'R');
                 $this->Cell(12, 5, gaz_format_number($rigo['pervat']), 1, 1, 'R');
                 break;
             case "2":
                 $this->Cell(25, 5, '', 'L');
                 $this->Cell(80, 5, $rigo['descri'], 'LR', 0, 'L');
                 $this->Cell(81, 5, '', 'R', 1);
                 break;
             case "3":
                 $this->Cell(25, 5, '', 1, 0, 'L');
                 $this->Cell(80, 5, $rigo['descri'], 'B', 0, 'L');
                 $this->Cell(49, 5, '', 'B', 0, 'L');
                 $this->Cell(20, 5, gaz_format_number($rigo['prelis']), 1, 0, 'R');
                 $this->Cell(12, 5, '', 1, 1, 'R');
                 break;
             case "6":
             case "8":
                 $this->writeHtmlCell(186, 6, 10, $this->GetY(), $rigo['descri'], 1, 1);
                 break;
             case "11":
                 $this->Cell(25, 5, '', 'L');
                 $this->Cell(80, 5, "CIG: " . $rigo['descri'], 'LR', 0, 'L');
                 $this->Cell(81, 5, '', 'R', 1);
                 break;
             case "12":
                 $this->Cell(25, 5, '', 'L');
                 $this->Cell(80, 5, "CUP: " . $rigo['descri'], 'LR', 0, 'L');
                 $this->Cell(81, 5, '', 'R', 1);
                 break;
             case "13":
                 $this->Cell(25, 5, '', 'L');
                 $this->Cell(80, 5, "IdDocumento: " . $rigo['descri'], 'LR', 0, 'L');
                 $this->Cell(81, 5, '', 'R', 1);
                 break;
         }
         if ($rigo['ritenuta'] > 0) {
             $this->Cell(154, 5, 'Ritenuta d\'acconto al ' . gaz_format_number($rigo['ritenuta']) . '%', 'LB', 0, 'R');
             $this->Cell(20, 5, gaz_format_number(round($rigo['importo'] * $rigo['ritenuta'] / 100, 2)), 'RB', 0, 'R');
             $this->Cell(12, 5, '', 1, 1, 'R');
         }
     }
 }
Пример #16
0
function createProductTable($company_id,$prezzi=false,$decimal_price,$backcolor='f7b6c5')
{
    global $gTables;
    // creo files immagini e tabella da inserire lla pagina "product"-  catalogo con le immagini ed eventualmente i prezzi degli articoli di magazzino
    $rs_art = gaz_dbi_dyn_query($gTables['artico'].".codice AS codart,".
    $gTables['artico'].".descri AS desart,".
    $gTables['artico'].".image AS imaart,".
    $gTables['artico'].".catmer,".
    $gTables['artico'].".unimis,".
    $gTables['artico'].".barcode AS barcod,".
    $gTables['artico'].".web_url AS linkart,".
    $gTables['artico'].".web_mu,".
    $gTables['artico'].".web_multiplier,".
    $gTables['artico'].".web_price AS prezzo,".
    $gTables['artico'].".annota AS annart,".
    $gTables['artico'].".pack_units AS units,".
    $gTables['catmer'].".descri AS descat,".
    $gTables['catmer'].".image AS imacat,".
    $gTables['catmer'].".codice AS codcat,".
    $gTables['catmer'].".web_url AS linkcat,".
    $gTables['aliiva'].".aliquo,".
    $gTables['catmer'].".annota AS anncat ",
    $gTables['artico']." LEFT JOIN ".$gTables['aliiva']." ON ".$gTables['artico'].".aliiva = ".$gTables['aliiva'].".codice ".
    " LEFT JOIN ".$gTables['catmer']." ON ".$gTables['artico'].".catmer = ".$gTables['catmer'].".codice",
    1,
    "codcat, codart");
    $ctrl_cm = 0;
    $html='<table style="width: 100%;" border="0" cellspacing="0" cellpadding="0" align="center"><tbody>';
    $html .= '<tr>
            <td></td>
            <td>codice</td>
            <td>descrizione</td>
            <td>prezzo</td>
            <td>unità misura</td>
            <td>annotazione</td>
            </tr>
            ';     
    while ($r = gaz_dbi_fetch_array($rs_art)) {
        if ($prezzi==2) { // articoli con prezzo  
            $price = gaz_format_quantity($r['prezzo']*$r['web_multiplier'],true,$decimal_price);
            $vat='+IVA '.floatval($r['aliquo']).'%';
            $um= '€/'.$r['web_mu'];
        } elseif($prezzi==1) { // articoli con prezzo 
            $price = '';
            $vat='';
            $um='';
        }
        if ($r['codcat'] <> $ctrl_cm) { // categoria merceologica
            if ( !empty($r['imacat']) ) {
                // creo il file immagine
                $file=fopen('gazie_data.tmp','w+');
                fwrite($file,$r['imacat']);
                fclose($file);
                $imgd=getimagesize('gazie_data.tmp',$info);
                $mime_r=explode('/', $imgd['mime']);
                $mime_elem=end($mime_r);
                $file = fopen('gazie_site'.$company_id.'/images/catmer_'.$r['codcat'].".".$mime_elem, "w");
                fwrite($file, $r['imacat']);
                fclose($file);
                $src='images/catmer_'.$r['codcat'].".".$mime_elem;
            } else {
                $src='gazie_site_noimage.png';
            }
            $html .= '<tr><td colspan="5" bgcolor="#'.$backcolor.'">'.$r['codcat'].' - '.$r['descat'].'</td><td><img src="'.$src.'" height="50"></td>
            </tr>';
        }
        // articolo
        if ( !empty($r['imaart']) ) {
            // creo il file immagine
            $file=fopen('gazie_data.tmp','w+');
            fwrite($file,$r['imaart']);
            fclose($file);
            $imgd=getimagesize('gazie_data.tmp',$info);
            $mime_r=explode('/', $imgd['mime']);
            $mime_elem=end($mime_r);
            $file = fopen('gazie_site'.$company_id.'/images/artico_'.$r['codart'].".".$mime_elem, "w");
            fwrite($file, $r['imaart']);
            fclose($file);
            $src='images/artico_'.$r['codart'].".".$mime_elem;
        } else {
            $src='gazie_site_noimage.png';
        }
        $html .= '<tr><td><img src="'.$src.'" class="imgBox" title=" header=['.$r['codart'].'] body=[<center><img src=\''.$src.'\'>] fade=[on] fadespeed=[0.03] "></td><td>'.$r['codart'].'</td><td>'.$r['desart'].'</td><td align="right">'.$price.' </td> <td>'.$um.' '.$vat.'</td><td>'.$r['annart'].'</td>
        </tr>';
        $ctrl_cm = $r['codcat'];
    }
    return $html."</tbody></table>\n";
}
Пример #17
0
              $pdf->Cell(17,4,number_format($mv['prezzo'],$admin_aziend['decimal_price'],',',' '),'TR',0,'R');
              $pdf->Cell(8,4,$mv['unimis'],'TR',0,'C');
         } else {
              $pdf->Cell(16,4,'','LR');
              $pdf->Cell(30,4,'','R');
              $pdf->Cell(100,4,'','R');
              $pdf->Cell(17,4,'','R');
              $pdf->Cell(8,4,'','R');
         }
         $pdf->Cell(17,4,gaz_format_quantity($mval['q']*$mv['operat'],1,$admin_aziend['decimal_quantity']),1,0,'R');
         if ($mv['operat']==1) {
             $pdf->Cell(17,4,number_format($mval['v'],$admin_aziend['decimal_price'],',',''),1,0,'R');
             $pdf->Cell(17,4,'',1);
         } else {
             $pdf->Cell(17,4,'',1);
             $pdf->Cell(17,4,number_format($mval['v'],$admin_aziend['decimal_price'],',',''),1,0,'R');
         }
         $pdf->Cell(20,4,gaz_format_quantity($mval['q_g'],1,$admin_aziend['decimal_quantity']),1,0,'R');
         $pdf->Cell(20,4,gaz_format_number($mval['v_g']),1,1,'R');
         $ctrl_id = $mv['id_mov'];
      }
      $ctrlArtico = $mv['artico'];
}
$pdf->SetFont('helvetica','B',8);
$pdf->Cell($aRiportare['top'][0]['lun'],4,$script_transl['tot'].strftime("%d-%m-%Y",$utsrf).' : ',1,0,'R');
$pdf->Cell($aRiportare['top'][1]['lun'],4,$aRiportare['top'][1]['nam'],1,0,'R');
$pdf->Cell($aRiportare['top'][2]['lun'],4,$aRiportare['top'][2]['nam'],1,0,'R');
$pdf->SetFont('helvetica','',7);
$pdf->setRiporti('');
$pdf->Output();
?>
Пример #18
0
 $form['id_rif'] = intval($_POST['id_rif']);
 $form['caumag'] = intval($_POST['caumag']);
 $form['operat'] = intval($_POST['operat']);
 $form['gioreg'] = intval($_POST['gioreg']);
 $form['mesreg'] = intval($_POST['mesreg']);
 $form['annreg'] = intval($_POST['annreg']);
 $form['clfoco'] = intval($_POST['clfoco']);
 $form['clorfo'] = intval($_POST['clorfo']); //cliente, fornitore o entrambi
 $form['tipdoc'] = intval($_POST['tipdoc']);
 $form['desdoc'] = substr($_POST['desdoc'],0,50);
 $form['giodoc'] = intval($_POST['giodoc']);
 $form['mesdoc'] = intval($_POST['mesdoc']);
 $form['anndoc'] = intval($_POST['anndoc']);
 $form['scochi'] = floatval(preg_replace("/\,/",'.',$_POST['scochi']));
 $form['artico'] = $_POST['artico'];
 $form['quanti'] = gaz_format_quantity($_POST['quanti'],0,$admin_aziend['decimal_quantity']);
 $form['prezzo'] = number_format(preg_replace("/\,/",'.',$_POST['prezzo']),$admin_aziend['decimal_price'],'.','');
 $form['scorig'] = floatval(preg_replace("/\,/",'.',$_POST['scorig']));
 $form['status'] = substr($_POST['status'],0,10);
 $form['search_partner'] = $_POST['search_partner'];
 $form['search_item'] = $_POST['search_item'];
 // Se viene inviata la richiesta di conferma della causale la carico con le relative contropartite...
 if (isset($_POST['inscau_x'])) {
         $causa = gaz_dbi_get_row($gTables['caumag'],"codice",$form['caumag']);
         $form['operat'] = $causa['operat'];
         $form['clorfo'] = $causa['clifor']; //cliente, fornitore o entrambi
         if (($causa['clifor'] < 0 and substr($form['clfoco'],0,3) == $admin_aziend['masfor']) or
             ($causa['clifor'] > 0 and substr($form['clfoco'],0,3) == $admin_aziend['mascli'])) {
             $form['clfoco'] = 0;
             $form['search_partner'] = "";
         }
Пример #19
0
                             array('lun' => 17,'nam'=>'Prezzo'),
                             array('lun' => 18,'nam'=>'Importo'),
                             array('lun' => 10,'nam'=>'U.M.'),
                             array('lun' => 20,'nam'=>'Mov.Quant.')
                            )
              );

$pdf = new Report_template();
$pdf->setVars($admin_aziend,$title);
$pdf->SetTopMargin(39);
$pdf->SetFooterMargin(20);
$config = new Config;
$pdf->AddPage('L',$config->getValue('page_format'));
$pdf->SetFont('helvetica','',7);
if (sizeof($result) > 0) {
  while (list($key, $row) = each($result)) {
      $datadoc = substr($row['datdoc'],8,2).'-'.substr($row['datdoc'],5,2).'-'.substr($row['datdoc'],0,4);
      $datareg = substr($row['datreg'],8,2).'-'.substr($row['datreg'],5,2).'-'.substr($row['datreg'],0,4);
      $movQuanti = $row['quanti']*$row['operat'];
      $pdf->Cell(20,3,$datareg,1,0,'C');
      $pdf->Cell(40,3,$row['caumag'].'-'.substr($row['descri'],0,22),1);
      $pdf->Cell(70,3,$row['artico'].' - '.$row['desart'],1);
      $pdf->Cell(70,3,$row['desdoc'].' del '.$datadoc,1);
      $pdf->Cell(17,3,number_format($row['prezzo'],$admin_aziend['decimal_price'],',','.'),1,0,'R');
      $pdf->Cell(18,3,gaz_format_number(CalcolaImportoRigo($row['quanti'],$row['prezzo'],array($row['scochi'],$row['scorig']))),1,0,'R');
      $pdf->Cell(10,3,$row['unimis'],1,0,'C');
      $pdf->Cell(20,3,gaz_format_quantity($movQuanti,1,$admin_aziend['decimal_quantity']),1,1,'R');
  }
}
$pdf->Output();
?>