コード例 #1
0
 public function actionDownload()
 {
     parent::actionDownload();
     $pdf = new PDF();
     $pdf->title = 'Material Stock Overview List';
     $pdf->AddPage('L');
     $pdf->setFont('Arial', 'B', 12);
     // definisi font
     $pdf->setFont('Arial', 'B', 8);
     // menuliskan tabel
     $header = array('No', 'ID', 'Material Name', 'Sloc', 'Qty', 'UOM', 'Prod Trans Type', 'Ref Source');
     $model = new Productstock('search');
     $dataprovider = $model->search();
     $dataprovider->pagination = false;
     $data = $dataprovider->getData();
     $cols = $dataprovider->getKeys();
     $dataku = array(count($data));
     //var_dump($dataku);
     $w = array(10, 15, 70, 30, 30, 30, 40, 30);
     $pdf->SetTableHeader();
     //Header
     for ($i = 0; $i < count($header); $i++) {
         $pdf->Cell($w[$i], 7, $header[$i], 1, 0, 'C', true);
     }
     $pdf->Ln();
     $pdf->SetTableData();
     //Data
     $fill = false;
     $i = 0;
     foreach ($data as $datas) {
         $i = $i + 1;
         $pdf->Cell($w[0], 6, $i, 'LR', 0, 'L', $fill);
         $pdf->Cell($w[1], 6, $datas['productstockid'], 'LR', 0, 'L', $fill);
         $pdf->Cell($w[2], 6, Product::model()->findbypk($datas['productid'])->productname, 'LR', 0, 'L', $fill);
         $pdf->Cell($w[3], 6, Sloc::model()->findbypk($datas['slocid'])->sloccode, 'LR', 0, 'L', $fill);
         $pdf->Cell($w[4], 6, $datas['qty'], 'LR', 0, 'L', $fill);
         $pdf->Cell($w[5], 6, Unitofmeasure::model()->findbypk($datas['unitofmeasureid'])->uomcode, 'LR', 0, 'L', $fill);
         $pdf->Cell($w[6], 6, Prodtranstype::model()->findbypk($datas['prodtranstypeid'])->description, 'LR', 0, 'L', $fill);
         $pdf->Cell($w[7], 6, $datas['refsource'], 'LR', 0, 'L', $fill);
         $pdf->Ln();
         $fill = !$fill;
     }
     $pdf->Cell(array_sum($w), 0, '', 'T');
     // me-render ke browser
     $pdf->Output('productstock.pdf', 'D');
 }
コード例 #2
0
$animal = animalTableClass::NUMERO;
$veterinario = veterinarioTableClass::NOMBRE;
class PDf extends FPDF
{
    function Footer()
    {
        $this->SetY(-15);
        $this->SetFont('Arial', 'I', 8);
        $this->Cell(0, 10, 'Page ' . $this->PageNo() . '/{nb}', 0, 0, 'C');
    }
}
$pdf = new PDF('P', 'mm', 'letter');
$pdf->AliasNbPages();
$pdf->AddPage();
$pdf->Image(routing::getInstance()->getUrlImg('reporte_Vertical.jpg'), 0, 0, 216, 280);
$pdf->Ln(40);
$pdf->SetFont('Arial', 'B', 25);
$pdf->Cell(93);
$pdf->Cell(30, 10, $mensaje, 0, 0, 'C');
$pdf->Ln(20);
$pdf->SetFont('Arial', 'B', 15);
$pdf->Cell(10);
//$pdf->Cell(37, 10, utf8_decode('N. Documento'), 1, 0, 'C');
$pdf->Cell(40, 10, utf8_decode('Fecha'), 1, 0, 'C');
$pdf->Cell(38, 10, utf8_decode('Animal'), 1, 0, 'C');
$pdf->Cell(100, 10, utf8_decode('Veterinario'), 1, 0, 'C');
$pdf->Ln();
foreach ($objVacunacion as $key) {
    $pdf->Cell(10);
    //    $pdf->Cell(37, 10, utf8_decode($key->id), 1);
    $pdf->Cell(40, 10, date("Y-M-d", strtotime($key->{$fecha})), 1, 0, 'C');
コード例 #3
0
 $fotos = explode(",", $row['fotos']);
 //Creación del objeto de la clase heredada
 //$pdf=new PDF();
 //$pdf->AliasNbPages();
 /*	if (!isset($pdf)) {
 			$pdf=new PDF();
 			$pdf->AliasNbPages();
 		}
 	*/
 $pdf->AddPage();
 $pdf->SetDisplayMode('fullpage');
 $pdf->SetMargins(20, 20, 20);
 $pdf->SetFont('Arial', 'BU', 14);
 $pdf->SetTextColor(70, 125, 25);
 $pdf->Cell(0, 10, 'FICHA DE CHECK DOMICILIARIO', 0, 1, 'C');
 $pdf->Ln(2);
 $pdf->SetTextColor(0, 0, 0);
 $pdf->SetFont('Arial', 'B', 12);
 $pdf->Cell(55, 7, 'NOMBRES Y APELLIDOS', 1, 0, 'L');
 $pdf->SetFont('Arial', '', 12);
 $pdf->Cell(0, 7, $nombre, 1, 1, 'C');
 $pdf->SetFont('Arial', 'B', 12);
 $pdf->Cell(55, 7, 'DIRECCION', 1, 0, 'L');
 $pdf->SetFont('Arial', '', 12);
 $pdf->MultiCell(0, 7, $domicilio, 1, 'C');
 //$pdf->Ln(2);
 //$pdf->Image('../files/images_dni/imagen1.png',40,null,0,130);
 $pdf->Ln(2);
 $pdf->SetFont('Arial', 'B', 12);
 $pdf->Cell(35);
 $pdf->Cell(33, 7, 'DOMICILIADO', 0, 0, 'L');
コード例 #4
0
// 	con filtro del motivos y depattamento
if ($depto != '-1' and $motivo != '-1' and ($fechai != "" and $fechaf != "")) {
    $query1 = " \nSelect empleado.No_Empleado, CONCAT(Primer_nombre, ' ', Segundo_nombre, ' ', Primer_apellido, ' ', Segundo_Apellido) as Nombre, departamento_laboral.nombre_departamento,motivos.descripcion, \nCOUNT(permisos.id_Permisos) as Solicitudes, SUM(permisos.dias_permiso) as Inasistencias from permisos\n inner join motivos on permisos.id_motivo=motivos.Motivo_ID \n inner join empleado on empleado.No_Empleado=permisos.No_Empleado \n inner join persona on persona.N_identidad=empleado.N_identidad \n inner join departamento_laboral on departamento_laboral.id_departamento_laboral = permisos.id_departamento \n where  departamento_laboral.nombre_departamento='" . $depto . "' and motivos.descripcion='" . $motivo . "' and \n date_format(permisos.fecha,'%d-%m-%Y') between  date_format('" . $fechai . " ','%d-%m-%Y')and date_format('" . $fechaf . "','%d-%m-%Y')\t\n\tGROUP BY Primer_nombre, Segundo_nombre, Primer_apellido, Segundo_Apellido, departamento_laboral.nombre_departamento,motivos.descripcion ORDER BY Primer_nombre asc";
}
// 	por fechas
if ($depto == '-1' and $motivo != '-1') {
    $query1 = " \nSelect empleado.No_Empleado, CONCAT(Primer_nombre, ' ', Segundo_nombre, ' ', Primer_apellido, ' ', Segundo_Apellido) as Nombre, departamento_laboral.nombre_departamento, motivos.descripcion, \nCOUNT(permisos.id_Permisos) as Solicitudes, SUM(permisos.dias_permiso) as Inasistencias from permisos\n inner join motivos on permisos.id_motivo=motivos.Motivo_ID \n inner join empleado on empleado.No_Empleado=permisos.No_Empleado \n inner join persona on persona.N_identidad=empleado.N_identidad \n inner join departamento_laboral on departamento_laboral.id_departamento_laboral = permisos.id_departamento \n where  motivos.descripcion='" . $motivo . "' and \n date_format(permisos.fecha,'%d-%m-%Y') between  date_format('" . $fechai . " ','%d-%m-%Y')and date_format('" . $fechaf . "','%d-%m-%Y')\t\n\tGROUP BY Primer_nombre, Segundo_nombre, Primer_apellido, Segundo_Apellido, departamento_laboral.nombre_departamento,motivos.descripcion ORDER BY Primer_nombre asc";
}
$pdf = new PDF();
$pdf->AddPage("L", "Letter");
$pdf->SetFont('Arial', '', 18);
$pdf->Image($maindir . 'assets/img/lucen-aspicio.png', 50, 15, 200, 200, 'PNG');
$pdf->Image($maindir . 'assets/img/logo_unah.png', 15, 5, 24, 36, 'PNG');
$pdf->Image($maindir . 'assets/img/logo-cienciasjuridicas.png', 230, 8, 35, 35, 'PNG');
$pdf->Cell(22, 10, '', 0);
$pdf->SetFont('Arial', '', 18);
$pdf->Cell(45, 10, '', 0);
$pdf->Cell(70, 10, utf8_decode('Universidad Nacional Autónoma de Honduras'), 0);
$pdf->Ln(10);
$pdf->SetFont('Arial', 'U', 14);
$pdf->Cell(60, 8, '', 0, 0, "C");
$pdf->Cell(130, 8, 'Reportes de Permisos Personales', 0, 0, "C");
$pdf->Ln(25);
//$pdf->AddCol('N',25,'#Empleado','C');
$pdf->AddCol('Nombre', 70, 'Nombre Completo', 'C');
$pdf->AddCol('nombre_departamento', 40, 'Departamento', 'C');
$pdf->AddCol('descripcion', 40, 'Motivo', 'C');
$pdf->AddCol('Solicitudes', 28, 'Solicitudes', 'R');
$pdf->AddCol('Inasistencias', 30, utf8_decode('Días Faltados'), 'R');
$pdf->Table($query1);
$pdf->Output();
コード例 #5
0
$pdf->SetCreator('work | eventos');
$pdf->SetAuthor($usuarioNome . " - " . $empresaNome);
$pdf->SetTitle('Emissão do Pedido');
$pdf->SetSubject('Relatório gerado automaticamente pelo sistema');
$pdf->AliasNbPages();
$pdf->AddPage();
//Recupera o nome da empresa
$empresaNome = 'Consoli Eventos Ltda';
$edtPedidoId = $_GET["PedidoId"];
//Imprime o logotipo da empresa
$pdf->Image('../image/logo_consoli2.jpg', 10, 10, 34);
//Ajusta a fonte
$pdf->SetFont('Arial', 'B', 15);
$pdf->Cell(0, 6, $empresaNome, 0, 0, 'R');
$pdf->SetFont('Arial', '', 9);
$pdf->Ln();
$pdf->Cell(0, 4, 'Rua São Bento, 289 - Bairro Progresso - Rio do Sul - SC - CEP: 89160-000', 0, 0, 'R');
$pdf->Ln();
$pdf->Cell(0, 4, 'Fone: (47) 3520-1650 - consoli@consolieventos.com.br', 0, 0, 'R');
$pdf->Ln(14);
$pdf->SetFont('Arial', 'B', 16);
$pdf->SetFillColor(178, 178, 178);
$pdf->Cell(0, 7, 'Pedido de Foto e Vídeo Nro ' . $dados_pedido["id"], 0, 0);
$pdf->ln();
$pdf->SetFont('Arial', 'B', 11);
$pdf->Cell(0, 5, 'Emissão: ' . DataMySQLRetornar($dados_pedido["data"]) . ' Por: ' . $dados_pedido["usuario_nome"], 0, 0);
$pdf->ln();
$pdf->SetFont('Arial', 'B', 11);
$pdf->Cell(0, 5, 'Data da Venda: ' . DataMySQLRetornar($dados_pedido["data_venda"]), 0, 0);
$pdf->ln(8);
$pdf->SetFont('Arial', 'B', 11);
コード例 #6
0
ファイル: inventario.php プロジェクト: GrupoOCS/OCS
    $datos = $client->inventarioR($marca);
    $header = array('Nombre', 'Cantidad', 'Precio');
    $descripcion = "<br><b>Inventario</b><br><b>Marca: </b>" . $marca;
}
$nombre = "<b>Descripción del reporte</b>";
$img = "imagenes/log.jpg";
//Antes de pasar los datos al PDF, hay que pasar las variables por la función html_entity_decode para decodificar los caracteres especiales, los acentos y las ñ
// Siempre y cuando los datos extraídos de la BD sean UTF8 (no lo probe con otra codificación)
$nombre = html_entity_decode($nombre);
$descripcion = html_entity_decode($descripcion);
//Creamos una nueva instancia de la clase
$pdf = new PDF();
//Añádimos la primera página
$pdf->AddPage();
$pdf->Image('log.jpg', 8, 8, 30);
$pdf->Ln(12);
$pdf->SetFont('Helvetica', '', 20);
//$pdf->Ln(12);
$pdf->Line(10, 30, 200, 30);
$pdf->SetFontSize(17);
$pdf->SetTextColor(44, 62, 80);
$pdf->WriteHTML("Online Computer Shop");
$pdf->SetTextColor(0);
$pdf->SetLeftMargin(155);
$pdf->SetFontSize(14);
$pdf->Ln(-15);
$pdf->WriteHTML("<br><br><b>Fecha:</b> " . date("d/m/Y", time() - 25200));
$pdf->WriteHTML("<br><b>Hora:</b> " . date("H:i:s", time() - 25200) . "\n\n");
$pdf->SetLeftMargin(10);
$pdf->Ln(14);
// Otra parte importante, luego de pasar las variables por la función html_entity_decode, para que se vean bien los acentos y las ñ, hay que pasarlas por otra
コード例 #7
0
}
$codfactura = $_REQUEST["codfactura"];
$consulta = "Select * from facturas,clientes where facturas.codfactura='{$codfactura}' and facturas.codcliente=clientes.codcliente";
$resultado = mysql_query($consulta, $conexion);
$lafila = mysql_fetch_array($resultado);
$fecha = implota($lafila["fecha"]);
$dia1 = substr($fecha, 0, 2);
$mes1 = substr($fecha, 3, 2);
$mes1 = mes($mes1);
$ano1 = substr($fecha, 6, 4);
$pdf->SetFillColor(255, 255, 255);
$pdf->SetTextColor(18, 18, 239);
$pdf->SetDrawColor(0, 0, 0);
$pdf->SetLineWidth(0.2);
$pdf->SetFont('Arial', 'B', 11);
$pdf->Ln(31);
$pdf->Cell(115);
$pdf->Cell(10, 4, $codfactura, 0, 0, 'L', 0);
$pdf->Ln(22);
$pdf->Cell(60);
$pdf->Cell(42, 4, $CiudadActual, 0, 0, 'L', 0);
$pdf->Cell(20, 4, $dia1, 0, 0, 'L', 0);
$pdf->Cell(55, 4, $mes1, 0, 0, 'L', 0);
$pdf->Cell(10, 4, $ano1, 0, 0, 'L', 0);
$pdf->Ln(8);
$pdf->Cell(20);
$pdf->Cell(125, 4, $lafila["nombre"], 0, 0, 'L', 0);
$fecha = implota($lafila["fecha"]);
$pdf->Cell(35, 4, $lafila["nif"], 0, 0, 'L', 0);
$pdf->Ln(6);
//Calculamos la provincia
コード例 #8
0
ファイル: prjformativo.php プロジェクト: andreazurli/stage-ng
$stmt->bindValue(':id', $_GET['id']);
$stmt->execute();
if ($stmt->rowCount() > 0) {
    $row = $stmt->fetch(PDO::FETCH_ASSOC);
    $pdf = new PDF();
    $pdf->SetTitle("Progetto formativo e di orientamento");
    $pdf->AddFont('abac', '', 'abac.php');
    $pdf->AddFont('abalc', '', 'ABALC.php');
    $pdf->SetFillColor(255, 230, 255);
    $pdf->AliasNbPages();
    $pdf->AddPage();
    $pdf->SetLeftMargin(18);
    $pdf->SetRightMargin(18);
    $pdf->SetFont('abac', '', 14);
    $pdf->Cell(0, 10, 'PROGETTO FORMATIVO e di ORIENTAMENTO', 0, 0, 'C');
    $pdf->Ln(10);
    $pdf->SetFont('abalc', '', 11);
    $pdf->Cell(40, 6, 'Tirocinante ', 1, 0, 'R', 1);
    $pdf->Cell(135, 6, ' ' . utf8_decode($row['TIR_Nome']) . ' ' . utf8_decode($row['TIR_Cognome']) . ' - C.F.: ' . utf8_decode($row['TIR_CodiceFiscale']), 1, 1);
    $pdf->Cell(40, 6, 'Luogo e data di nascita ', 1, 0, 'R', 1);
    $pdf->Cell(135, 6, ' ' . utf8_decode($row['TIR_NatoA']) . ' (' . $row['TIR_NatoProv'] . ') il ' . strftime('%d/%m/%Y', strtotime($row['TIR_DataNascita'])), 1, 1);
    $pdf->Cell(40, 6, 'Residenza ', 1, 0, 'R', 1);
    $pdf->Cell(135, 6, ' ' . utf8_decode($row['TIR_IndirizzoResidenza']) . ' - ' . $row['TIR_CAP'] . ' ' . utf8_decode($row['TIR_ComuneResidenza']), 1, 1);
    $pdf->Cell(40, 6, 'Recapiti ', 1, 0, 'R', 1);
    $pdf->Cell(135, 6, ' ' . $row['TIR_Cellulare'] . ' - ' . $row['TIR_TelefonoFisso'] . ' - ' . $row['TIR_EMail'], 1, 1);
    $pdf->Cell(40, 6, 'Classe / Indirizzo ', 1, 0, 'R', 1);
    $pdf->Cell(135, 6, ' ' . $row['TIR_Classe'] . ' ' . $row['TIR_Indirizzo'], 1, 1);
    $pdf->Ln(3);
    $pdf->Cell(40, 6, 'Azienda ospitante ', 1, 0, 'R', 1);
    $pdf->Cell(135, 6, ' ' . utf8_decode($row['AZ_RagioneSociale']), 1, 1);
    $pdf->Cell(40, 6, 'Legale rappresentante ', 1, 0, 'R', 1);
コード例 #9
0
ファイル: pdf.php プロジェクト: raalveco/Escuela
/**
 * Genera un reporte en PDF
 *
 * @param array $result
 * @param array $sumArray
 * @param string $title
 * @param array $weightArray
 * @param array $headerArray
 */
function pdf($result, $sumArray, $title, $weightArray, $headerArray)
{
    $config = Config::read('config');
    $active_app = Router::get_application();
    //Orientación
    if ($sumArray > 200) {
        $orientation = 'L';
    } else {
        $orientation = 'P';
    }
    $numRows = 140;
    //Tipo de Papel
    if ($sumArray > 250) {
        $paper = 'legal';
    } else {
        $paper = 'letter';
    }
    if ($paper == 'letter' && $orientation == 'P') {
        $widthPage = 220;
        $numRows = 42;
    }
    if ($paper == 'legal' && $orientation == 'L') {
        $widthPage = 355;
        $numRows = 30;
    }
    if ($paper == 'letter' && $orientation == 'L') {
        $widthPage = 270;
        $numRows = 30;
    }
    //Crear Documento PDF
    $pdf = new PDF($orientation, 'mm', $paper);
    $pdf->Open();
    $pdf->AddPage();
    //Nombre del Listado
    $pdf->SetFillColor(255, 255, 255);
    $pdf->AddFont('Verdana', '', 'verdana.php');
    $pdf->SetFont('Verdana', '', 14);
    $pdf->SetY(20);
    $pdf->SetX(0);
    $pdf->Ln();
    if ($config->{$active_app}->name) {
        $pdf->MultiCell(0, 6, strtoupper($config->{$active_app}->name), 0, "C", 0);
    }
    $pdf->MultiCell(0, 6, "REPORTE DE " . strtoupper($title), 0, "C", 0);
    $pdf->SetFont('Verdana', '', 12);
    if (isset($_SESSION['fecsis'])) {
        $pdf->MultiCell(0, 6, "FECHA " . date("Y-m-d"), 0, "C", 0);
    }
    $pdf->Ln();
    //Colores, ancho de línea y fuente en negrita
    $pdf->SetFillColor(0xf2, 0xf2, 0xf2);
    $pdf->SetTextColor(0);
    $pdf->SetDrawColor(0, 0, 0);
    $pdf->SetLineWidth(0.2);
    $pdf->SetFont('Arial', 'B', 10);
    if ($weightArray[0] < 11) {
        $weightArray[0] = 11;
    }
    //Parametros del Reporte
    $pos = floor($widthPage / 2 - $sumArray / 2);
    $pdf->SetX($pos);
    for ($i = 0; $i <= count($headerArray) - 1; $i++) {
        $pdf->Cell($weightArray[$i], 7, $headerArray[$i], 1, 0, 'C', 1);
    }
    $pdf->Ln();
    //Restauración de colores y fuentes
    $pdf->SetFillColor(224, 235, 255);
    $pdf->SetTextColor(0);
    $pdf->SetFont('Arial', 'B', 7);
    //print_r($weightArray);
    //Buscamos y listamos
    $n = 1;
    $p = 1;
    $t = 0;
    foreach ($result as $row) {
        //$pdf->Cell(Ancho, Alto, contenido, ?, ?, Align)
        if ($n > $numRows || $p == 1 && $n > $numRows - 3) {
            $pdf->AddPage($orientation);
            $pdf->SetY(30);
            $pdf->SetX($pos);
            $pdf->SetFillColor(0xf2, 0xf2, 0xf2);
            $pdf->SetTextColor(0);
            $pdf->SetDrawColor(0, 0, 0);
            $pdf->SetLineWidth(0.2);
            $pdf->SetFont('Arial', 'B', 10);
            for ($i = 0; $i < count($headerArray); $i++) {
                $pdf->Cell($weightArray[$i], 7, $headerArray[$i], 1, 0, 'C', 1);
            }
            $pdf->Ln();
            $pdf->SetFillColor(224, 235, 255);
            $pdf->SetTextColor(0);
            $pdf->SetFont('Arial', 'B', 7);
            $n = 1;
            $p++;
        }
        $pdf->SetX($pos);
        for ($i = 0; $i <= count($row) - 1; $i++) {
            if (is_numeric($row[$i])) {
                $pdf->Cell($weightArray[$i], 5, trim($row[$i]), 'LRTB', 0, 'C');
            } else {
                $pdf->Cell($weightArray[$i], 5, trim($row[$i]), 'LRTB', 0, 'L');
            }
        }
        $n++;
        $t++;
        $pdf->Ln();
    }
    $pdf->SetX($pos);
    $pdf->SetFont('Arial', 'B', 7);
    $pdf->SetFillColor(0xf2, 0xf2, 0xf2);
    $pdf->Cell($weightArray[0], 5, "TOTAL", 'LRTB', 0, 'R');
    $pdf->Cell($weightArray[1], 5, $t, 'LRTB', 0, 'L');
    /*print "<div style='background: url(img/bg2.jpg) #F2f2f2;border:1px solid #c0c0c0'>
    	<table><td><img src='img/information.gif' width='64' height='64'/></td><td>";
    	print "Papel: $paper<br>";
    	print "Orientación: $orientation<br>";
    	print "Ancho Página: $widthPage mm<br>";
    	print "Número Páginas: $p<br>";
    	print "</td></table></div><br>";*/
    $file = md5(uniqid());
    $pdf->Output(CORE_PATH . 'public/temp/' . $file . ".pdf", 'F');
    if (isset($raw_output)) {
        print "<script type='text/javascript'> window.open('" . KUMBIA_PATH . "temp/" . $file . ".pdf', null); </script>";
    } else {
        Generator::forms_print("<script type='text/javascript'> window.open('" . KUMBIA_PATH . "temp/" . $file . ".pdf', null); </script>");
    }
}
コード例 #10
0
ファイル: informeMenuPDF.php プロジェクト: hakendo/Comeat
        if ($color % 2 == 0) {
            $imprimirColor = false;
        } else {
            $imprimirColor = true;
        }
        $valor = $row['PRECIO'];
        $descuento = $row['OFERTA'];
        $incognita = $descuento * $valor / 100;
        $total = $valor - $incognita;
        //Espacio para centrar
        $fpdf->Cell(30, 5, '', 0, 0, 'C');
        //Nombre
        $fpdf->Cell(45, 5, $row['NOMBRE'], 1, 0, 'C', $imprimirColor);
        //Valor
        $fpdf->Cell(38, 5, $valor, 1, 0, 'C', $imprimirColor);
        //DSCTO
        $fpdf->Cell(37, 5, $descuento, 1, 0, 'C', $imprimirColor);
        //TOTAL
        $fpdf->Cell(38, 5, $total, 1, 0, 'C', $imprimirColor);
        //CATEGORIA
        $fpdf->Cell(50, 5, $row['CATEGORIA'], 1, 0, 'C', $imprimirColor);
        //Salto de linea
        $fpdf->Ln();
        $color++;
    }
    $objConnect->closeConect();
    $fpdf->Output('prueba', 'I');
    $fpdf->Output();
} else {
    header("Location: ../../plantillas/errorPrivilegios.html");
}
コード例 #11
0
ファイル: facture.php プロジェクト: Kwendou/Rexel
 }
 $data[$key_next + 2][0] = "Total :";
 for ($i = 1; $i < 7; $i++) {
     $data[$key_next + 2][$i] = "";
 }
 $data[$key_next + 2][7] = str_replace(".", ",", $total);
 //Page d'en-tête
 $pdf->SetTitle('CSSH - Facturation');
 $pdf->SetFont('Arial', '', 14);
 $pdf->AddPage();
 //Hypothèses de travail
 $pdf->SetFillColor(224, 235, 255);
 $pdf->SetFont('', 'BU', 16);
 $pdf->Cell(70);
 $pdf->Cell(50, 11, 'Période : du ' . $_GET['from'] . ' au ' . $_GET['to'], 0, 0, 'C');
 $pdf->Ln(14);
 $pdf->Cell(90);
 $pdf->SetFont('', 'B', 14);
 $pdf->Cell(5, 10, 'Coordonnées du club :', 0, 0, 'C');
 $pdf->Ln(10);
 $pdf->SetFont('Arial', '', 10);
 $pdf->Cell(60);
 $pdf->Cell(30, 5, 'Responsable : ', 0, 0, 'L', true);
 $pdf->Cell(40, 5, $coordonnee['PRENOM'] . ' ' . $coordonnee['NOM'], 0, 0, 'L', true);
 $pdf->Ln(5);
 $pdf->Cell(60);
 $pdf->Cell(30, 5, 'Rue : ', 0, 0, 'L', false);
 $pdf->Cell(40, 5, $coordonnee['RUE'] . ', ' . $coordonnee['NUMERO'], 0, 0, 'L', false);
 $pdf->Ln(5);
 $pdf->Cell(60);
 $pdf->Cell(30, 5, 'Code Postal : ', 0, 0, 'L', true);
コード例 #12
0
ファイル: PersonaPDF.php プロジェクト: JLockerbie/BS
$pdf->SetFont('Helvetica', 'B', 20);
$pdf->SetTextColor(50, 60, 100);
//insert Collage logo
$pdf->Image('logo.png', 10, 10, 33, 0);
//display the title without a border around it
$pdf->SetXY(50, 15);
$pdf->SetDrawColor(50, 60, 100);
$pdf->Cell(100, 10, $name, 0, 0, 'C', 0);
// Insert a dynamic image from a URL
$pdf->Image($image, 11, 30, 0, 50);
//Set x and y position for the main text, reduce font size and write content
$pdf->SetXY(65, 30);
$pdf->SetLeftMargin(65);
$pdf->SetFontSize(10);
$pdf->Write(5, $characteristics);
$pdf->Ln(8);
//Output the clues
$pdf->SetFont('Helvetica', '', 9);
$pdf->SetXY(10, 90);
$column_width = $pdf->w - 10;
// For bullet list - width and bullet array variables
$cluesBullet = array();
$cluesBullet['bullet'] = chr(149);
$cluesBullet['margin'] = ' ';
$cluesBullet['indent'] = 0;
$cluesBullet['spacer'] = 0;
$cluesBullet['text'] = array();
//Set a counter for the foreach loop
$i = 0;
foreach ($clues as $val) {
    $cluesBullet['text'][$i] = $val;
コード例 #13
0
$pdf->SetFont('Arial', 'B', 9);
$pdf->SetX(5);
$pdf->SetFont('Amble-Regular', '', 9);
$sql = pg_query("select  I.comprobante, I.fecha_actual, I.hora_actual, U.nombre_usuario, U.apellido_usuario  from inventario I, usuario U where I.id_usuario = U.id_usuario and I.comprobante='{$_GET['id']}'");
while ($row = pg_fetch_row($sql)) {
    $pdf->SetX(1);
    $pdf->Cell(50, 6, utf8_decode('Comprobante: '), 0, 0, 'C', 0);
    $pdf->Cell(55, 6, utf8_decode($row[0]), 0, 0, 'L', 0);
    $pdf->Cell(50, 6, utf8_decode('Fecha: '), 0, 0, 'C', 0);
    $pdf->Cell(50, 6, utf8_decode($row[1]), 0, 1, 'L', 0);
    $pdf->SetX(1);
    $pdf->Cell(50, 6, utf8_decode('Hora:'), 0, 0, 'C', 0);
    $pdf->Cell(55, 6, utf8_decode($row[2]), 0, 0, 'L', 0);
    $pdf->Cell(50, 6, utf8_decode('Usuario:'), 0, 0, 'C', 0);
    $pdf->Cell(50, 6, utf8_decode($row[3]), 0, 1, 'L', 0);
    $pdf->Ln(3);
}
$sql2 = pg_query("select D.cod_productos, P.codigo, P.articulo, D.p_costo, D.p_venta, D.disponibles, D.existencia, D.diferencia from inventario I, detalle_inventario D, productos P where D.cod_productos = P.cod_productos and I.id_inventario = D.id_inventario and D.id_inventario='{$_GET['id']}'");
$pdf->SetX(1);
$pdf->Cell(30, 6, utf8_decode('Código'), 1, 0, 'C', 0);
$pdf->Cell(55, 6, utf8_decode('Producto'), 1, 0, 'C', 0);
$pdf->Cell(25, 6, utf8_decode('Precio Costo'), 1, 0, 'C', 0);
$pdf->Cell(25, 6, utf8_decode('Precio Venta'), 1, 0, 'C', 0);
$pdf->Cell(20, 6, utf8_decode('Stock'), 1, 0, 'C', 0);
$pdf->Cell(25, 6, utf8_decode('Existencia'), 1, 0, 'C', 0);
$pdf->Cell(25, 6, utf8_decode('Diferencia'), 1, 1, 'C', 0);
$total1 = 0;
$total2 = 0;
while ($row = pg_fetch_row($sql2)) {
    $pdf->SetX(1);
    $total1 = $total1 + $row[3];
コード例 #14
0
ファイル: persona.php プロジェクト: royer21/staff2
 protected function generaReporte($data, $titulo = '')
 {
     $this->load->library('Pdf');
     $pdf = new PDF('L', 'mm', 'A4');
     $pdf->AliasNbPages();
     $pdf->AddPage();
     $pdf->SetFont('Arial', '', 10);
     //if ($titulo != '')
     //{
     //	$pdf->Cell(40, 10, $titulo, 1);
     //	$pdf->Ln();
     //	$pdf->Ln();
     //}
     $header = array('#', 'Base', 'DNI', 'Nombres', 'A.Paterno', 'A.Materno', 'Celular', 'Est', 'Area', 'Cargo', 'Fecha Ini', 'T.Emp.');
     $w = array(5, 40, 13, 20, 20, 20, 14, 5, 60, 45, 15, 10, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11);
     $pdf->SetFont('Arial', 'B', 7);
     for ($i = 0; $i < count($header); $i++) {
         $pdf->Cell($w[$i], 8, utf8_decode($header[$i]), 1, 0, 'C');
     }
     $pdf->Ln();
     $pdf->SetFont('Arial', '', 7);
     $j = 1;
     foreach ($data as $row) {
         $pdf->Cell($w[0], 6, utf8_decode($j), 1);
         $pdf->Cell($w[1], 6, utf8_decode($row->base_nombre), 1);
         $pdf->Cell($w[2], 6, utf8_decode($row->dni), 1);
         $pdf->Cell($w[3], 6, utf8_decode($row->nombres), 1);
         $pdf->Cell($w[4], 6, utf8_decode($row->apellido_pat), 1);
         $pdf->Cell($w[5], 6, utf8_decode($row->apellido_mat), 1);
         $pdf->Cell($w[6], 6, utf8_decode($row->telefono), 1);
         //$pdf->Cell($w[7], 6, utf8_decode($row->ocupacion), 1);
         $pdf->Cell($w[7], 6, utf8_decode($row->estado), 1);
         $pdf->Cell($w[8], 6, utf8_decode($row->area_nombre), 1);
         $pdf->Cell($w[9], 6, utf8_decode($row->cargo), 1);
         $pdf->Cell($w[10], 6, utf8_decode($row->fecha_inicio), 1);
         $pdf->Cell($w[11], 6, utf8_decode($row->tiempo_empleo), 1);
         $pdf->Ln();
         $j++;
     }
     $pdf->Cell(array_sum($w), 0, '');
     $pdf->Output();
 }
コード例 #15
0
$n4p = array_shift($respuestaspractica->nota($id, 4));
$n1p = (int) $n1p['nota'];
$n2p = (int) $n2p['nota'];
$n3p = (int) $n3p['nota'];
$n4p = (int) $n4p['nota'];
$n1 = round((double) $nota1['nota'] * 100);
$n2 = round((double) $nota2['nota'] * 100);
$n3 = round((double) $nota3['nota'] * 100);
$n4 = round((double) $nota4['nota'] * 100);
$npt1 = ($n1p + $n1) / 2;
$npt2 = ($n2p + $n2) / 2;
$npt3 = ($n3p + $n3) / 2;
$npt4 = ($n4p + $n4) / 2;
$pdf = new PDF("P", "mm", array(215.9, 139.7));
$pdf->AddPage();
$pdf->Ln(5);
$pdf->CuadroCuerpoPersonalizado(100, "Nombre", 1, "C", 1, "B");
$pdf->CuadroCuerpoPersonalizado(50, "Paralelo", 1, "C", 1, "B");
$pdf->Ln();
$pdf->CuadroCuerpoPersonalizado(100, $est['nombres'] . " " . $est['paterno'] . " " . $est['materno'], 0, "C", 1, "");
$pdf->CuadroCuerpoPersonalizado(50, $par['nombre'], 0, "C", 1, "");
$pdf->Ln();
$pdf->Ln(5);
$pdf->CuadroCuerpoPersonalizado(50, "Bimestre", 1, "C", 1, "B");
$pdf->CuadroCuerpoPersonalizado(30, "Práctica", 1, "C", 1, "B");
$pdf->CuadroCuerpoPersonalizado(30, "Evaluación", 1, "C", 1, "B");
$pdf->CuadroCuerpoPersonalizado(30, "Nota", 1, "C", 1, "B");
$pdf->Ln();
$pdf->CuadroCuerpoPersonalizado(50, "1º Bimestre", 0, "C", 1, "");
$pdf->CuadroCuerpoPersonalizado(30, $n1p, 0, "C", 1, "");
$pdf->CuadroCuerpoPersonalizado(30, $n1, 0, "C", 1, "");
コード例 #16
0
$ivaT = 0;
$repetido = 0;
$consulta = pg_query('select * from proveedores order by id_proveedor asc');
while ($row = pg_fetch_row($consulta)) {
    $repetido = 0;
    $sub = 0;
    $contador = 0;
    $sql1 = pg_query("select * from factura_compra where estado='Activo' and id_proveedor='{$row['0']}' and forma_pago='Credito' order by forma_pago asc;");
    if (pg_num_rows($sql1)) {
        while ($row1 = pg_fetch_row($sql1)) {
            if ($repetido == 0) {
                $pdf->SetX(1);
                $pdf->SetFillColor(187, 179, 180);
                $pdf->Cell(70, 6, maxCaracter(utf8_decode('RUC/CI:' . $row[2]), 35), 1, 0, 'L', 1);
                $pdf->Cell(135, 6, maxCaracter(utf8_decode('NOMBRES:' . $row[3]), 50), 1, 1, 'L', 1);
                $pdf->Ln(2);
                $pdf->SetX(1);
                $pdf->Cell(25, 6, utf8_decode('Comprobante'), 1, 0, 'C', 0);
                $pdf->Cell(30, 6, utf8_decode('Tipo Documento'), 1, 0, 'C', 0);
                $pdf->Cell(45, 6, utf8_decode('Nro Factura'), 1, 0, 'C', 0);
                $pdf->Cell(25, 6, utf8_decode('Total'), 1, 0, 'C', 0);
                $pdf->Cell(25, 6, utf8_decode('Valor Pago'), 1, 0, 'C', 0);
                $pdf->Cell(25, 6, utf8_decode('Saldo'), 1, 0, 'C', 0);
                $pdf->Cell(30, 6, utf8_decode('Fecha Pago'), 1, 1, 'C', 0);
                $repetido = 1;
                $contador = 1;
            }
            $sql2 = pg_query("select * from factura_compra,pagos_compra where factura_compra.id_factura_compra= pagos_compra.id_factura_compra and pagos_compra.estado='Activo' and pagos_compra.id_proveedor='{$row['0']}' and factura_compra.id_factura_compra='{$row1['0']}'");
            while ($row2 = pg_fetch_row($sql2)) {
                $pdf->Cell(25, 6, utf8_decode($row2[0]), 0, 0, 'C', 0);
                $pdf->Cell(30, 6, utf8_decode($row2[10]), 0, 0, 'C', 0);
コード例 #17
0
ファイル: ReciboFunc.php プロジェクト: mriveros/PHPESTACIONES
$Permiso = pg_result($consulta, $i, 'sal_pyt');
$Judicial = pg_result($consulta, $i, 'sal_jud');
$ASO = pg_result($consulta, $i, 'sal_aso');
$Reposo = pg_result($consulta, $i, 'sal_rep');
$TotalDes = pg_result($consulta, $i, 'total_descuentos');
$Odescuentos = pg_result($consulta, $i, 'ode_mon');
$Neto = pg_result($consulta, $i, 'sal_neto');
//********************************************************************************
$pdf = new PDF();
$pdf->AddPage('P', 'recibo');
$pdf->AliasNbPages();
$pdf->SetFont('Arial', '', 10);
$pdf->Cell(0, 0, 'Fecha:', 0, 0, 'L', false);
//Fecha
$pdf->text(23, 36, $fecha);
$pdf->Ln(4);
$pdf->Cell(0, 0, 'Nombre Funcionario:', 0, 0, 'L', false);
//Nombre de Funcionario
$pdf->text(45, 40, $funcionario);
$pdf->text(147, 40, 'Ficha:');
$pdf->text(158, 40, $ficha);
$pdf->Ln(4);
$pdf->Cell(0, 0, 'C.I.:', 0, 0, 'L', false);
//numero de cedula de identidad
$pdf->text(19, 44, $CI);
$pdf->Ln(4);
$pdf->Cell(0, 0, utf8_decode('Descripción:'), 0, 0, 'L', false);
//descripcion..este campo no se usa
$pdf->Ln(4);
$pdf->Cell(0, 0, utf8_decode('Liquidacion y Pagos por: SUELDOS'), 0, 0, 'L', false);
//llenamos por defecto SUELDOS
コード例 #18
0
			$this->SetXY($r1 + ($r2-$r1)/2 -3 , ($y1 + 1) -5 );
			$this->SetFont("Arial", "B", 10);
			$this->Cell(10,5, $titulo, 0, 0, "C");
			$this->SetXY($r1 + ($r2-$r1)/2 -5 , $y1 + 5 );
			$this->SetFont( "Arial", "", 10);
			$this->Cell(10,5, $mode, 0, 0, "C");
		}
	}
	
	//Creación del objeto de la clase heredada
	$pdf=new PDF();
	$pdf->AliasNbPages();
	$pdf->AddPage();
	
	$pdf->Cell(0,10,'No. De Cliente: '.$c->idcliente.'',0,1,'L');
	$pdf->Ln(5);
	$pdf->Cell(0,10,'No. De Venta: '.$_GET[venta].'',0,1,'L');
	
	$pdf->Ln(5);
	
	$pdf->SetFont('Times','',11);	
	$pdf->MultiCell(0,10,'                   Recibí de Paquetería y Mensajería en Movimiento, S.A. de CV. Sucursal '.$f->descripcion.' ('.$c->cantidad.') guías de tipo '.(($c->prepagada=='SI')?'PREPAGADAS':'CONSIGNACION').' '.$c->folios.' a Precio de $'.$c->total.' '.(($c->prepagada=='SI')?'con un precio unitario de 
$ '.$c->precioporguia:'').', un peso máximo de '.$c->limitekg.' Kilos (real o volumen) y $'.$c->preciokgexcedente.' cada kilo excedente que resulte. Importes más IVA.',0,1,'L');
			
	$pdf->SetFont('Times','B',11);
	
	$pdf->Cell(0,10,'Fecha de Vencimiento: '.$c->vigencia.'.',0,1,'R');
	
	$pdf->Cell(0,10,'DATOS FISCALES DE LA EMPRESA:',0,1,'L');
	
	$pdf->SetFont('Times','',10);
コード例 #19
0
        $this->Cell($margin);
        $this->Cell(array_sum($w), 0, '', 'T');
        $this->Ln(15);
    }
}
// Instanciation of inherited class
$pdf = new PDF('P', 'mm', 'A4');
$pdf->AliasNbPages();
$pdf->AddPage();
$pdf->ChapterTitle("Salary Slip");
$pdf->Cell(15);
$pdf->SetFont('Times', '', 11);
$pdf->Cell(40, 5, 'Employee Name  :', 0, 1);
$pdf->Cell(15);
$pdf->Cell(40, 5, 'Month & Year     :', 0, 1);
$pdf->Ln(15);
////////
// Column headings
//$header = array('Earnings', 'Rs', 'Deductions', 'Rs');
// Data loading
//$data = $pdf->LoadData('countries.txt');
//$pdf->FancyTable($header,$data,15);
//$pdf->Ln(4);
// Column headings
$header = array('Earnings', 'Rs', 'Deductions', 'Rs');
// Data loading
$data2 = array();
$data2[] = array("Commissions", "12123.23", "Advances", "167.66");
$data2[] = array("Bonus", "0", "Missing", "127.89");
//$data = $pdf->LoadData('countries2.txt');
$pdf->FancyTable2($header, $data2, 15, '12321.213', 213.2312, 12321.89);
コード例 #20
0
ファイル: imprimir_Factura_tpv.php プロジェクト: klich3/gPOS
    $row = Row($res);
    $nombre = utf8_decode($row["nombre"]);
    $nif = $row["nif"];
    $direccion = utf8_decode($row["Direccion"]);
    $cliente = utf8_decode($row["TipoCliente"]);
    $nombre = $cliente == 'Empresa' ? utf8_decode($row["NombreLegal"]) : $nombre;
    $nombre = str_replace('&#038;', '&', $nombre);
}
$sql = "Select *  " . "       from " . "       ges_comprobantes " . "where  ges_comprobantes.IdComprobante='{$IdComprobante}' " . "and    ges_comprobantes.IdLocal='{$IdLocal}' " . "and    ges_comprobantes.Eliminado='0'";
$res = query($sql);
$lafila = Row($res);
//$pdf=new PDF();
$pdf = new PDF('P', 'mm', array(210, 297));
$pdf->Open();
$pdf->AddPage();
$pdf->Ln(2);
$pdf->Cell(95);
$pdf->Cell(80, 4, "", '', 0, 'C');
$pdf->Ln(5);
$pdf->SetFillColor(255, 255, 255);
$pdf->SetTextColor(0);
$pdf->SetDrawColor(0, 0, 0);
$pdf->SetLineWidth(0.2);
$pdf->SetFont('Arial', 'B', 10);
$pdf->SetX(130);
$pdf->Ln(40);
// Datos Cliente
$pdf->SetFont('Arial', 'B', 10);
$pdf->SetX(27);
// NOMBRE
$pdf->Cell(130, 4, $nombre);
コード例 #21
0
ファイル: purchase.php プロジェクト: kashifnasim/nexexcel
        }
        $pdf->Table($data, $prop);
        $_cMargin = $pdf->cMargin;
        $pdf->cMargin = $prop['padding'];
        $pdf->SetFont('Arial', 'B', 10);
        $width = $pdf->w - $pdf->lMargin - $pdf->rMargin;
        $cellSize = 0.01 * $width;
        $pdf->Cell($cellSize * ($showimport === true ? 48 : 45), 6, 'Total', 1, 0, 'C', false);
        $pdf->Cell($cellSize * ($showimport === true ? 8 : 20), 6, number_format($total['qty']), 1, 0, 'R', false);
        $pdf->Cell($cellSize * ($showimport === true ? 8 : 15), 6, '', 1, 0, 'L', false);
        $pdf->Cell($cellSize * ($showimport === true ? 12 : 20), 6, number_format($total['amt'], 2), 1, 0, 'R', false);
        if ($showimport) {
            $pdf->Cell($cellSize * 12, 6, '', 1, 0, 'L', false);
            $pdf->Cell($cellSize * 12, 6, number_format($total['uamt']), 1, 0, 'R', false);
        }
        $pdf->Ln();
        $pdf->Ln(10);
        $pdf->cMargin = $_cMargin;
    }
    $mysqli->close();
    $pdf->Output("purchase.pdf", "D");
} else {
    ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<link rel="shortcut icon" href="../images/logo_icon.gif">
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<link href="../stylesheets/style.css" rel="stylesheet" type="text/css" />
	<title><?php 
    echo $_SESSION['companyname'];
コード例 #22
0
            $pdf->SetX(1);
            $pdf->Cell(22, 6, utf8_decode($row1[14]), 0, 0, 'C', 0);
            $pdf->Cell(20, 6, utf8_decode($row1[1]), 0, 0, 'C', 0);
            $pdf->Cell(30, 6, utf8_decode(substr($row1[0], 8)), 0, 0, 'C', 0);
            $sub = $sub + ($row1[10] - $row1[8] - $row1[9]);
            $pdf->Cell(15, 6, $row1[10] - $row1[8] - $row1[9], 0, 0, 'C', 0);
            $desc = $desc + $row1[9];
            $pdf->Cell(17, 6, $row1[9], 0, 0, 'C', 0);
            $pdf->Cell(16, 6, $row1[6], 0, 0, 'C', 0);
            $pdf->Cell(17, 6, $row1[7], 0, 0, 'C', 0);
            $ivaT = $ivaT + $row1[8];
            $pdf->Cell(15, 6, $row1[8], 0, 0, 'C', 0);
            $total = $total + $row1[10];
            $pdf->Cell(15, 6, $row1[10], 0, 0, 'C', 0);
            $pdf->Cell(20, 6, $row1[3], 0, 0, 'C', 0);
            $pdf->Cell(20, 6, $row1[5], 0, 0, 'C', 0);
            $pdf->Ln(6);
        }
    }
}
$pdf->SetX(1);
$pdf->Ln(8);
$pdf->Cell(188, 6, utf8_decode("Subtotal"), 0, 0, 'R', 0);
$pdf->Cell(20, 6, maxCaracter(number_format($sub, 2, ',', '.'), 20), 0, 1, 'C', 0);
$pdf->Cell(188, 6, utf8_decode("Descuento"), 0, 0, 'R', 0);
$pdf->Cell(20, 6, maxCaracter(number_format($desc, 2, ',', '.'), 20), 0, 1, 'C', 0);
$pdf->Cell(188, 6, utf8_decode("Iva Total"), 0, 0, 'R', 0);
$pdf->Cell(20, 6, maxCaracter(number_format($ivaT, 2, ',', '.'), 20), 0, 1, 'C', 0);
$pdf->Cell(188, 6, utf8_decode("Total"), 0, 0, 'R', 0);
$pdf->Cell(20, 6, maxCaracter(number_format($total, 2, ',', '.'), 20), 0, 1, 'C', 0);
$pdf->Output();
コード例 #23
0
         SUM(experienciaentidad.monto_contrato) as monto, empresas.nombre_proponente, empresas.nit, empresas.matricula, empresas.celular, empresas.mail,
     (SELECT SUM(experienciaentidad.monto_contrato) FROM experienciaentidad where experienciaentidad.id_entidad = empresas.id) as montog, 
     (SELECT SUM(experienciaentidad.monto_contrato) FROM experienciaentidad where experienciaentidad.id_entidad = empresas.id and experienciaentidad.tipo = 1) as montoesp,
     (SELECT SUM(round(((to_days(`experienciaentidad`.`fecha_fin_contrato`) - to_days(`experienciaentidad`.`fecha_ini_contrato`)) / 30),2)) FROM experienciaentidad where experienciaentidad.id_entidad = empresas.id) as tiempomeses 
     FROM experienciaentidad INNER JOIN empresas ON experienciaentidad.id_entidad = empresas.id
     where empresas.estado = 4 and empresas.tipo <> 9 and empresas.tipo <> 19 group by experienciaentidad.id_entidad) as tb 
     INNER JOIN departamentosinteres on tb.id = departamentosinteres.id_empresas
     where departamentosinteres.id_departamentos = $iddepto and tb.monto >= $monto";
     */
     $sql = "SELECT * from (SELECT experienciaentidad.id_entidad as 'id', \r\n            SUM(experienciaentidad.monto_contrato) as monto, empresas.nombre_proponente, empresas.nit, empresas.matricula, empresas.celular, empresas.mail,\r\n(SELECT SUM(experienciaentidad.monto_contrato) FROM experienciaentidad where experienciaentidad.id_entidad = empresas.id and experienciaentidad.fecha_ini_contrato >= '{$date10}') as montog, \r\n(SELECT SUM(experienciaentidad.monto_contrato) FROM experienciaentidad where experienciaentidad.id_entidad = empresas.id and experienciaentidad.tipo = 1 and experienciaentidad.fecha_ini_contrato >= '{$date10}') as montoesp,\r\n(SELECT SUM(round(((to_days(`experienciaentidad`.`fecha_fin_contrato`) - to_days(`experienciaentidad`.`fecha_ini_contrato`)) / 30),2)) FROM experienciaentidad where experienciaentidad.id_entidad = empresas.id) as tiempomeses,\r\n(SELECT SUM(round(((to_days(`experienciaentidad`.`fecha_fin_contrato`) - to_days(`experienciaentidad`.`fecha_ini_contrato`)) / 30),2)) FROM experienciaentidad where experienciaentidad.id_entidad = empresas.id and experienciaentidad.tipo = 1) as tiempomesesp \r\n        FROM experienciaentidad INNER JOIN empresas ON experienciaentidad.id_entidad = empresas.id\r\n        where empresas.estado = 4 and empresas.tipo <> 9 and empresas.tipo <> 19 group by experienciaentidad.id_entidad) as tb \r\n        INNER JOIN departamentosinteres on tb.id = departamentosinteres.id_empresas\r\n        where departamentosinteres.id_departamentos = {$iddepto} and tb.montog >= ({$monto}*(SELECT dato1 from busquedaempresaparametros where parametro = 'monto_exp' and activo = 'SI' LIMIT 0,1)) and \r\ntb.montoesp >= ({$monto}*(SELECT dato2 from busquedaempresaparametros where parametro = 'monto_exp' and activo = 'SI' LIMIT 0,1)) order by tb.montog DESC";
 }
 $pdf = new PDF('P', 'mm', 'Letter');
 $pdf->SetMargins(15, 10, 5);
 $pdf->AddPage();
 $pdf->SetFont('helvetica', 'B', 14);
 $pdf->Ln(5);
 $pdf->Cell(195, 5, utf8_decode('REGISTRO DE BUSQUEDA DE EMPRESAS'), 0, FALSE, 'C');
 $pdf->Ln(4);
 $pdf->SetFont('helvetica', '', 10);
 $date = date('Y-m-d H:i:s');
 $pdf->Cell(195, 5, utf8_decode('USUARIO: ') . $user, 0, FALSE, 'C');
 $pdf->Ln(3);
 $pdf->Cell(195, 6, utf8_decode('CRITERIOS DE BUSQUEDA'), 0, FALSE, 'C');
 $pdf->Ln(3);
 $pdf->Cell(195, 7, utf8_decode('MONTO DEL PROYECTO: ') . $montodato, 0, FALSE, 'C');
 $pdf->Ln(3);
 $pdf->Cell(195, 8, utf8_decode('UBICACION DEL PROYECTO: ') . $departamento, 0, FALSE, 'C');
 $pdf->Ln(4);
 $pdf->Cell(195, 8, utf8_decode('DATOS TOMADOS DE LOS ') . $anios . utf8_decode(' ULTIMOS AÑOS DE EXPERIENCIA'), 0, FALSE, 'C');
 $pdf->Ln(4);
 $pdf->Cell(195, 8, utf8_decode('RELACION EXPERIENCIA GENERAL : ESPECIFICA (') . $dato11 . ':' . $dato12 . ')', 0, FALSE, 'C');
コード例 #24
0
<?php

require_once 'declaracao_matricula.inc.php';
require_once '../../../lib/fpdf16/fpdf.php';
class PDF extends FPDF
{
}
$pdf = new PDF();
$pdf->AddPage();
$pdf->SetMargins(20, 20, 20);
$pdf->SetTitle('Declaração de matrícula');
$pdf->SetFont('Times', 'B', 14);
//$pdf->Write(5,'DECLARAÇÃO');
$pdf->Ln(70);
$pdf->Cell(0, 5, 'DECLARAÇÃO', 0, 1, 'C', 0, 0, 0);
$pdf->Ln(15);
$pdf->SetFont('Times', '', 13);
$pdf->MultiCell(0, 5, $corpo, 0, 'J');
$pdf->Ln(10);
$pdf->Cell(0, 5, $data_declaracao, 0, 1, 'J', 0, 0, 0);
$pdf->Ln(15);
$pdf->Cell(44);
$pdf->Cell(70, 5, $carimbo_nome, 0, 1, 'C', 0, 0, 0);
$pdf->SetFont('Times', '', 10);
$pdf->Cell(44);
$pdf->MultiCell(70, 5, $carimbo_dados, 0, 'C');
//$pdf->SetFont('Times','',12);
$pdf->Ln(15);
$pdf->SetFont('Times', '', 9);
$pdf->MultiCell(0, 5, $decretos, 0, 'J');
$pdf->Ln(2);
コード例 #25
0
$contador = 0;
$consulta = pg_query("select id_cliente,identificacion,nombres_cli,telefono,direccion_cli from clientes");
while ($row = pg_fetch_row($consulta)) {
    $repetido = 0;
    $total = 0;
    $sql1 = pg_query("select id_factura_venta,num_factura,num_autorizacion,fecha_autorizacion,fecha_caducidad FROM factura_venta where id_cliente='{$row['0']}' and estado='Activo' and fecha_caducidad between '{$fecha}' and '{$_GET['fin']}'");
    if (pg_num_rows($sql1)) {
        if ($repetido == 0) {
            $pdf->SetX(1);
            $pdf->SetFillColor(221, 221, 221);
            $pdf->Cell(80, 6, utf8_decode('RUC/CI: ' . $row[1]), 1, 0, 'L', 1);
            $pdf->Cell(125, 6, utf8_decode('NOMBRE: ' . $row[2]), 1, 1, 'L', 1);
            $pdf->SetX(1);
            $pdf->Cell(80, 6, utf8_decode('TELF.: ' . $row[3]), 1, 0, 'L', 1);
            $pdf->Cell(125, 6, utf8_decode('DIRECCIÓN:  ' . $row[4]), 1, 1, 'L', 1);
            $pdf->Ln(2);
            $pdf->SetX(1);
            $pdf->Cell(40, 6, utf8_decode("Nro Factura"), 1, 0, 'C', 0);
            $pdf->Cell(35, 6, utf8_decode("Tipo Documento"), 1, 0, 'C', 0);
            $pdf->Cell(50, 6, utf8_decode("Nro. Autorización"), 1, 0, 'C', 0);
            $pdf->Cell(40, 6, utf8_decode("Fecha Autorización"), 1, 0, 'C', 0);
            $pdf->Cell(40, 6, utf8_decode("Fecha caducidad"), 1, 1, 'C', 0);
            $repetido = 1;
        }
        while ($row1 = pg_fetch_row($sql1)) {
            $pdf->SetX(1);
            $pdf->Cell(40, 6, utf8_decode($row1[1]), 0, 0, 'C', 0);
            $pdf->Cell(35, 6, utf8_decode('Factura'), 0, 0, 'C', 0);
            $pdf->Cell(50, 6, utf8_decode($row1[2]), 0, 0, 'C', 0);
            $pdf->Cell(40, 6, utf8_decode($row1[3]), 0, 0, 'C', 0);
            $pdf->Cell(40, 6, utf8_decode($row1[4]), 0, 1, 'C', 0);
コード例 #26
0
                 $this->SetX(55); 			
                 $this->Cell(60,5,"Tel: ".$telp,0,1,'L');	
                 $this->Line(10,30,200,30);
                 $this->Ln(10);*/
    }
    function Footer()
    {
        $this->SetY(-15);
        $this->SetFont('Arial', 'I', 8);
        $this->Cell(10, 10, 'Page ' . $this->PageNo(), 0, 0, 'C');
    }
}
$pdf = new PDF('P', 'mm', 'A4');
$pdf->SetMargins(20, '', 20);
$pdf->AddPage();
$pdf->Ln(45);
$pdf->SetFont('Arial', 'BU', '12');
$pdf->Cell(180, 5, strtoupper($_SESSION['lang']['kontrakJual']), 0, 1, 'C');
$pdf->SetFont('Arial', 'B', '10');
$pdf->Cell(180, 5, "No : " . $noKontrak, 0, 1, 'C');
$pdf->Ln(10);
$arrStatPPn = array(0 => "Exclude", 1 => "Include");
$pdf->SetFont('Arial', 'B', '10');
$pdf->Cell(39, 5, $_SESSION['lang']['penjual'], '', 0, 'L');
$pdf->Cell(5, 5, ':', '', 0, 'L');
$pdf->SetFont('Arial', '', '10');
$nmdt = explode(".", $nama);
setIt($nmdt[1], '');
$pdf->Cell(100, 5, $nmdt[0] . "." . ucwords(strtolower($nmdt[1])), '', 1, 'L');
$pdf->SetFont('Arial', 'B', '10');
$pdf->Cell(39, 5, '', '', 0, 'L');
コード例 #27
0
ファイル: view_bill.php プロジェクト: hari4you/hackrmz
//$address = getAddressBookPermanetn($_POST['cus_already_bill']); 
 
$noaddress = false;

   
   $stnoname = "Street name";
   $prov = "Prov";
   $postal = "600110";
   $city = "chennai";

$total_due = 1000;
$taxs = 500;
$total_due= "$".number_format($total_due, 2, '.', ','); 

$pdf->Ln(7);
$pdf->SetX(5);
$pdf->Write(8,"$name"); 
$pdf->Ln(7);
$pdf->SetX(5);
$pdf->Write(8,"$stnoname");
$pdf->Ln(7);
$pdf->SetX(5);
$pdf->Write(8,"$city $prov $postal");
$pdf->ln(15);

$head_valur = array("Header","Amount");
$caption = array();
$caption1["header"][] = "Settlement  Period \n".$_SESSION['startdate']." to ".$_SESSION['todate'];
$caption["price"][] = "$909.34";
$pdf->SetFont('Helvetica','B',10);
コード例 #28
0
$pdf->SetY($y);
$pdf->Image('../../css/images/logo_lapan.jpg', 135, 5, 30, 30, 'jpg');
$y = $pdf->GetY();
$pdf->Cell(0, 30, '', '', 1, 'L');
$oSatker = mysql_query("SELECT NAMA FROM t_satker WHERE KDUNITKERJA = '{$kdunit}' ");
$Satker = mysql_fetch_array($oSatker);
$kdeselon1 = substr($kdunit, 0, 3) . '000';
$oEselon = mysql_query("SELECT nama FROM tb_unitkerja WHERE kdunit = '{$kdeselon1}' ");
$Eselon = mysql_fetch_array($oEselon);
$w = array(0, 290);
$pdf->SetFont($font, 'B', $size + 2);
$pdf->SetX($margin + $w[0]);
$pdf->Cell($w[1], $ln, 'RENCANA AKSI DARI PENETAPAN KINERJA', '', 1, 'C');
$pdf->SetX($margin + $w[0]);
$pdf->Cell($w[1], $ln, trim(strtoupper(nm_unit($kdunit))), '', 1, 'C');
$pdf->Ln() * 2;
$w1 = array(35, 40, 18, 9, 40, 9, 40, 9, 40, 9, 40);
$pdf->SetFont($font, 'B', $size);
$pdf->SetX($margin);
$pdf->Cell($w1[0], $ln * 3, 'Sasaran Strategis', $border, 0, 'C');
$pdf->SetX($margin + $w1[0]);
$pdf->Cell($w1[1], $ln * 3, 'Indikator Kinerja', $border, 0, 'C');
$pdf->SetX($margin + $w1[0] + $w1[1]);
$pdf->Cell($w1[2], $ln * 3, 'Target', $border, 0, 'C');
$y = $pdf->GetY();
$pdf->SetXY($margin + $w1[0] + $w1[1] + $w1[2], $y);
$pdf->Cell(($w1[3] + $w1[4]) * 4, $ln, 'Rencana Aksi', $border, 0, 'C');
$pdf->SetXY($margin + $w1[0] + $w1[1] + $w1[2], $y + 5);
$pdf->Cell($w1[3] + $w1[4], $ln, 'Triwulan I', $border, 0, 'C');
$pdf->SetXY($margin + $w1[0] + $w1[1] + $w1[2] + $w1[3] + $w1[4], $y + 5);
$pdf->Cell($w1[5] + $w1[6], $ln, 'Triwulan II', $border, 0, 'C');
コード例 #29
0
        $this->SetFont('Arial', '', 6);
        //$this->SetY(27);
        $this->SetX(163);
        $this->Cell(30, 10, 'PRINT TIME : ' . date('d-m-Y H:i:s'), 0, 1, 'L');
    }
}
$pdf = new PDF('P', 'mm', 'A4');
$pdf->AddPage();
// kepada yth
$pdf->SetFont('Arial', 'B', 8);
if ($_SESSION['language'] == 'EN') {
    $pdf->Cell(30, 4, "TO :", 0, 0, 'L');
} else {
    $pdf->Cell(30, 4, "KEPADA YTH :", 0, 0, 'L');
}
$pdf->Ln();
$arte = "";
$pdf->Cell(35, 4, $_SESSION['lang']['nm_perusahaan'], 0, 0, 'L');
$pdf->Cell(40, 4, ": " . $nmSupplier . $arte, 0, 1, 'L');
if ($cp != '') {
    $pdf->Cell(35, 4, $_SESSION['lang']['cperson'], 0, 0, 'L');
    $pdf->Cell(40, 4, ": " . $cp, 0, 1, 'L');
}
$pdf->Cell(35, 4, $_SESSION['lang']['alamat'], 0, 0, 'L');
$pdf->Cell(40, 4, ": " . $almtSupplier, 0, 1, 'L');
$pdf->Cell(35, 4, $_SESSION['lang']['telp'], 0, 0, 'L');
$pdf->Cell(40, 4, ": " . $tlpSupplier, 0, 1, 'L');
$pdf->Cell(35, 4, $_SESSION['lang']['fax'], 0, 0, 'L');
$pdf->Cell(40, 4, ": " . $faxSupplier, 0, 1, 'L');
$pdf->Cell(35, 4, $_SESSION['lang']['namabank'], 0, 0, 'L');
$pdf->Cell(40, 4, ": " . $kdBank . " " . $kdBank, 0, 1, 'L');
コード例 #30
0
ファイル: symbol.php プロジェクト: RFDO93/mantenimiento
<?php

session_start();
include_once "../clases/clase_articulo.php";
include_once "../clases/clase_pdf_articulo.php";
$articulo = new articulo();
$parametro = $_SESSION["id2"];
$articulo->settipoarticulo($parametro);
$lista = $articulo->buscarticulo();
$pdf = new PDF('L', 'mm', 'Letter');
$pdf->Open();
$pdf->AliasNbPages();
$pdf->AddPage();
$pdf->SetFont('Times', '', 12);
$pdf->SetMargins(20, 20, 20);
$pdf->Ln(0);
$pdf->SetFont('Arial', 'B', 14);
$pdf->SetFillColor(170, 0, 0);
$pdf->SetTextColor(255);
$pdf->Cell(40, 6, 'Codigo', 1, 0, 'C', true);
$pdf->Cell(55, 6, 'Descripcion', 1, 0, 'C', true);
$pdf->Cell(35, 6, 'Tipo', 1, 0, 'C', true);
$pdf->Cell(35, 6, 'U/M', 1, 0, 'C', true);
$pdf->Cell(35, 6, 'Existencia', 1, 0, 'C', true);
$pdf->Cell(40, 6, 'Ubicacion', 1, 1, 'C', true);
if ($lista == "-1") {
    header("Location: ../php/error.php?url=../controladores/cierra_consulta.php & codigo=14 & mensaje2= Volver al Menu de Inicio.  ");
} else {
    for ($i = 0; $i < count($lista); $i++) {
        $codarti = $lista[$i][1];
        $descrip = $lista[$i][2];