//establece el nombre del paciente

$pdf->SetXY(2,5);
$pdf->Cell(0,0,'POLIZA DE DIARIO',0,0,M);

$pdf->SetX(1);


//*****************ech*************





$fecha1=$_GET['fecha'];
$pdf->SetY(10);
$pdf->Cell(0,0,cambia_a_normal($fecha1),0,0,R);



$pdf->SetXY(2,10);
$pdf->Cell(0,0,"HOSPITAL LA CARLOTA",0,0,M);
$pdf->SetX(1);


$pdf->SetXY(2,25);
$pdf->Cell(0,0,"CONSUMO DE ALMACENES",0,0,M);
$pdf->SetX(1);


$pdf->SetXY(2, 41);
if ($_GET['cajero']) {
    $pdf->Cell(0, 0, 'Cajero: ' . $_GET['cajero'], 0, 0, L);
}
//referencia
$pdf->SetXY(2, 45);
$pdf->Cell(0, 0, 'Referencia: ' . $myrow311['folioVenta'], 0, 0, L);
$sSQLt = "SELECT numRecibo\r\nFROM\r\ncargosCuentaPaciente\r\nWHERE \r\nentidad='" . $_GET['entidad'] . "'\r\nand\r\nfolioVenta='" . $_GET['folioVenta'] . "'\r\nand\r\nrandom='" . $_GET['random'] . "'\r\n ";
$resultt = mysql_db_query($basedatos, $sSQLt);
$myrowt = mysql_fetch_array($resultt);
$pdf->SetXY(2, 25);
$pdf->Cell(0, 0, 'Recibo: ' . $myrowt['numRecibo'], 0, 0, R);
//cambiar fecha
//$myrow1['fecha1']=cambia_a_normal($myrow1['fecha1']);
$fecha1 = date("d/m/Y");
$pdf->SetY(30);
$pdf->Cell(0, 0, 'Fecha: ' . $fecha1, 0, 0, R);
//Citas
$pdf->SetY(34);
$pdf->Cell(0, 0, 'Hora Cargo: ' . $myrow311['hora'], 0, 0, R);
$pdf->SetY(38);
$sSQL1y = "Select * From catCajas WHERE entidad='" . $myrow311['entidad'] . "' AND keyCatC = '" . $myrow311['codigoCaja'] . "' ";
$result1y = mysql_db_query($basedatos, $sSQL1y);
$myrow1y = mysql_fetch_array($result1y);
$pdf->Cell(0, 0, $myrow1y['descripcionCaja'], 0, 0, R);
//Status
$pdf->SetY(42);
$pdf->Cell(0, 0, 'Tipo Px: ' . $myrow311['tipoPaciente'], 0, 0, R);
//Usuario
$pdf->SetY(45);
$pdf->Cell(0, 0, 'Usuario Autorizo: ' . $myrow311['autoriza'], 0, 0, R);
    //$pdf->Cell(0,0,$myrow311['paciente'],0,0,L);
}
if ($_GET['siniestro']) {
    $pdf->SetXY(100, 65);
    $pdf->Cell(0, 0, $_GET['siniestro'], 0, 0, L);
}
if ($_GET['credencial']) {
    $pdf->SetXY(29, 65);
    $pdf->Cell(0, 0, $_GET['credencial'], 0, 0, L);
}
//$pdf->SetXY(100,50);
//$pdf->Cell(0,0,"N� Folio: ".$myrow311['folioVenta'],0,0,L);
//numero de paciente
$pdf->SetXY(50, 43);
//$pdf->Cell(0,0,$_GET['folioFactura'],0,0,R);
$pdf->SetY(43);
$pdf->Cell(0, 0, "Fact N�: " . $_GET['folioFactura'], 0, 0, R);
//cambiar fecha
//$myrow1['fecha1']=cambia_a_normal($myrow1['fecha1']);
if ($_GET['fechaImpresion']) {
    $fecha1 = $_GET['fechaImpresion'];
} else {
    $fecha1 = date("d    m    Y");
}
$pdf->SetXY(50, 47);
$pdf->Cell(0, 0, $fecha1, 0, 0, R);
//Imprimo con salto de pagina
$pdf->Ln(25);
//salto de linea
$pdf->SetFont('Arial', '', 10);
$pdf->SetXY(30, 37);
} else {
    $pdf->Cell(0, 0, 'Particular', 0, 0, L);
}
//usuario
$pdf->SetXY(2, 41);
$pdf->Cell(0, 0, 'Usuario: ' . $_GET['usuario'], 0, 0, L);
//REFERENCIA
$pdf->SetXY(2, 45);
$pdf->Cell(0, 0, 'numCorte: ' . $_GET['numCorte'], 0, 0, L);
//numero de paciente
$pdf->SetXY(302, 25);
$pdf->Cell(0, 0, 'Recibo: ' . $_GET['numRecibo'], 0, 0, R);
//cambiar fecha
//$myrow1['fecha1']=cambia_a_normal($myrow1['fecha1']);
$fecha1 = date("d/m/Y");
$pdf->SetY(40);
$pdf->Cell(0, 0, 'Fecha: ' . $fecha1, 0, 0, R);
//Imprimo con salto de pagina
$pdf->Ln(25);
//salto de linea
$pdf->SetFont('Arial', '', 10);
$pdf->SetXY(2, 37);
//dibujar una linea
$pdf->Line(2, 48, 200, 48);
//linea divisoria
//$pdf->Line(23, 48, 23, 52);
//etiquetas
$pdf->SetFont('Arial', '', 10);
$pdf->SetXY(2, 50);
$pdf->Cell(0, 0, 'C', 0, 0, L);
$pdf->SetXY(7, 50);
    //$pdf->Cell(0,0,$myrow311['paciente'],0,0,L);
}
if ($_GET['siniestro']) {
    $pdf->SetXY(100, 65);
    $pdf->Cell(0, 0, $_GET['siniestro'], 0, 0, L);
}
if ($_GET['credencial']) {
    $pdf->SetXY(29, 65);
    $pdf->Cell(0, 0, $_GET['credencial'], 0, 0, L);
}
//$pdf->SetXY(100,50);
//$pdf->Cell(0,0,"N� Folio: ".$myrow311['folioVenta'],0,0,L);
//numero de paciente
$pdf->SetXY(50, 44);
//$pdf->Cell(0,0,$_GET['folioFactura'],0,0,R);
$pdf->SetY(45);
$pdf->Cell(0, 0, "Fact N�: " . $_GET['folioFactura'], 0, 0, R);
//cambiar fecha
//$myrow1['fecha1']=cambia_a_normal($myrow1['fecha1']);
if ($_GET['fechaImpresion']) {
    $fecha1 = $_GET['fechaImpresion'];
} else {
    $fecha1 = date("d    m    Y");
}
$pdf->SetXY(50, 50);
$pdf->Cell(0, 0, $fecha1, 0, 0, R);
//Imprimo con salto de pagina
$pdf->Ln(25);
//salto de linea
$pdf->SetFont('Arial', '', 10);
$pdf->SetXY(30, 37);
$myrow12 = mysql_fetch_array($result12);
if ($myrow12['medico'] == 'si') {
    $pdf->Cell(0, 0, 'Medico: ' . $myrow12['descripcion'], 0, 0, L);
} else {
    $pdf->Cell(0, 0, 'Departamento: ' . $myrow311['almacen'], 0, 0, L);
}
//usuario
$pdf->SetXY(22, 41);
$pdf->Cell(0, 0, 'Cajero: ' . $_GET['usuario'], 0, 0, L);
//numero de paciente
$pdf->SetXY(300, 25);
$pdf->Cell(0, 0, 'Folio: ' . $myrow311['folioVenta'], 0, 0, R);
//cambiar fecha
//$myrow1['fecha1']=cambia_a_normal($myrow1['fecha1']);
$fecha1 = date("d/m/Y");
$pdf->SetY(29);
$pdf->Cell(0, 0, 'Fecha: ' . $fecha1, 0, 0, R);
//Imprimo con salto de pagina
$pdf->Ln(25);
//salto de linea
$pdf->SetFont('Arial', '', 10);
$pdf->SetXY(30, 37);
//dibujar una linea
$pdf->Line(23, 48, 200, 48);
//linea divisoria
//$pdf->Line(23, 48, 23, 52);
//etiquetas
$pdf->SetFont('Arial', '', 8);
$pdf->SetXY(23, 50);
$pdf->Cell(0, 0, 'Cantidad', 0, 0, L);
$pdf->SetXY(40, 50);
$result2 = mysql_db_query($basedatos, $sSQL2);
$myrow2 = mysql_fetch_array($result2);
$TCargos = $myrow2['TCargos'];
$TOTAL = $myrow17['sumaCargos'] - $Tabonos + $TCargos;
$sSQL13 = "\r\n\tSELECT \r\n  sum(iva*cantidad) as sumaiva\r\nFROM\r\ncargosCuentaPaciente\r\nWHERE \r\nnumeroE = '" . $_GET['numeroE'] . "'\r\n and\r\n nCuenta='" . $_GET['nCuenta'] . "'\r\nand\r\nstatusCargo='cargado'\r\n\r\n";
$result13 = mysql_db_query($basedatos, $sSQL13);
$myrow13 = mysql_fetch_array($result13);
$iva = $myrow13['sumaiva'];
$pdf->SetFont('Arial', '', 12);
//establece el nombre del paciente
$pdf->SetXY(22, 18);
$pdf->Cell(0, 0, 'Descripci�n', 0, 0, L);
$pdf->SetXY(175, 18);
$pdf->Cell(0, 0, 'Descuento', 0, 0, L);
$pdf->Line(23, 21, 200, 21);
$pdf->SetY(5);
$pdf->Cell(0, 0, $numeroTransaccion, 0, 0, R);
//numero de paciente
$pdf->SetXY(30, 5);
$pdf->Cell(0, 0, $_GET['titulo'], 0, 0, L);
$pdf->SetX(1);
//cambiar fecha
//$myrow1['fecha1']=cambia_a_normal($myrow1['fecha1']);
$fecha1 = date("d/m/Y");
/* $pdf->SetY(10);
$pdf->Cell(0,0,$fecha1,0,0,R); */
//Imprimo con salto de pagina
$pdf->Ln(15);
//salto de linea
$pdf->SetFont('Arial', '', 10);
$pdf->SetXY(30, 7);
$sSQL39 = "SELECT *\r\nFROM\r\nclientes\r\nwhere \r\nnumCliente='" . $seguro . "'";
$result39 = mysql_db_query($basedatos, $sSQL39);
$myrow39 = mysql_fetch_array($result39);
$seguro = $myrow39['nomCliente'];
$auxiliar = $myrow39['ID_AUXILIAR'];
$ctaMayor = $myrow39['ID_CTAMAYOR'];
//**********cierra devolver seguro
if ($seguro) {
    $paciente = $seguro;
}
$pdf->SetFont('Arial', '', 10);
//establece el nombre del paciente
$pdf->SetXY(2, 5);
$pdf->Cell(0, 0, 'HOSPITAL LA CARLOTA', 0, 0, M);
$pdf->SetX(1);
$pdf->SetY(5);
$pdf->Cell(0, 0, 'Num. Corte: ' . $_GET['numCorte'], 0, 0, R);
//numero de paciente
$pdf->SetXY(2, 10);
$pdf->Cell(0, 0, "Diario de Caja", 0, 0, M);
$pdf->SetX(1);
$pdf->SetXY(2, 13);
$pdf->Cell(0, 0, 'Cajero(a): ' . $usuario, 0, 0, M);
$pdf->SetX(1);
//***********************************EFECTIVO SOLAMENTE***********************************
$pdf->SetFont('Arial', '', 12);
$pdf->SetXY(1, 25);
$pdf->Cell(0, 0, 'Devoluciones', 0, 0, M);
$pdf->SetFont('Arial', '', 10);
$pdf->line(2, 32, 203, 32);
$pdf->SetXY(1, 30);
$myrow39 = mysql_fetch_array($result39);
$seguro = $myrow39['nomCliente'];
$auxiliar = $myrow39['ID_AUXILIAR'];
$ctaMayor = $myrow39['ID_CTAMAYOR'];
//**********cierra devolver seguro
if ($seguro) {
    $paciente = $seguro;
}
$pdf->SetFont('Arial', '', 10);
//establece el nombre del paciente
//$pdf->SetXY(2,5);
//$pdf->SetX(1);
$pdf->SetXY(2, 5);
$pdf->Cell(0, 0, 'HOSPITAL LA CARLOTA', 0, 0, M);
$pdf->SetX(2);
$pdf->SetY(7);
$pdf->Cell(0, 0, 'Num. Corte: ' . $_GET['numCorte'], 0, 0, R);
//numero de paciente
$pdf->SetXY(2, 13);
$pdf->Cell(0, 0, "REPORTE POR RECIBO", 0, 0, M);
$pdf->SetX(1);
$pdf->SetXY(2, 17);
$pdf->Cell(0, 0, 'CAJERO(A): ' . $usuario, 0, 0, M);
$pdf->SetX(1);
$pdf->SetXY(2, 22);
$pdf->Cell(0, 0, $myrow13['descripcionCaja'], 0, 0, M);
$pdf->SetX(1);
//***********************************EFECTIVO SOLAMENTE***********************************
$pdf->SetFont('Arial', '', 12);
$pdf->SetXY(1, 25);
//$pdf->Cell(0,0,'FOLIOS',0,0,M);
    $pdf->Cell(0, 0, 'Departamento: ' . $myrow361a['descripcion'], 0, 0, L);
    //*****************
}
//usuario
$pdf->SetXY(2, 41);
$pdf->Cell(0, 0, 'Usuario: ' . $_GET['usuario'], 0, 0, L);
//usuario
$pdf->SetXY(2, 45);
$pdf->Cell(0, 0, 'Referencia: ' . $myrow311['folioVenta'], 0, 0, L);
//numero de paciente
/* $pdf->SetXY(302,25);
$pdf->Cell(0,0,'Folio: '.$myrow311['numRecibo'],0,0,R); */
//cambiar fecha
//$myrow1['fecha1']=cambia_a_normal($myrow1['fecha1']);
$fecha1 = date("d/m/Y");
$pdf->SetY(40);
$pdf->Cell(0, 0, 'Fecha: ' . $fecha1, 0, 0, R);
$pdf->SetY(35);
$pdf->Cell(0, 0, 'Hora: ' . $_GET['hora1'], 0, 0, R);
//Imprimo con salto de pagina
$pdf->Ln(25);
//salto de linea
$pdf->SetFont('Arial', '', 13);
$pdf->SetXY(2, 37);
//dibujar una linea
$pdf->Line(2, 48, 200, 48);
//linea divisoria
//$pdf->Line(23, 48, 23, 52);
//etiquetas
$pdf->SetFont('Arial', '', 13);
$pdf->SetXY(2, 50);
$pdf->SetFont('Arial','',10);
//establece el nombre del paciente

$pdf->SetXY(2,5);
$pdf->Cell(0,0,'RESUMEN DETALLADO DE FACTURAS',0,0,M);
$pdf->SetX(1);


//*****************ech*************





$fecha1=$_GET['fecha'];
$pdf->SetY(10);
$pdf->Cell(0,0,cambia_a_normal($fecha1),0,0,R);


$pdf->SetY(20);
if($_GET['fechaImpresion']!=NULL){
$pdf->Cell(0,0,'Fecha Impresion: '.cambia_a_normal($_GET['fechaImpresion']),0,0,R);
}

$pdf->SetXY(2,10);
$pdf->Cell(0,0,"HOSPITAL LA CARLOTA",0,0,M);
$pdf->SetX(1);


$pdf->SetXY(2,25);
$pdf->Cell(0,0,"REGISTRO DE FACTURAS/COMPRAS",0,0,M);
//establece el nombre del paciente

$pdf->SetXY(2,5);
$pdf->Cell(0,0,'VENTAS POR VOLUMEN ',0,0,M);
$pdf->SetX(1);


//*****************ech*************





$fecha1=$_GET['fecha'];
$pdf->SetFont('Arial','',8);
$pdf->SetY(10);
$pdf->Cell(0,0,'Inicial: '.cambia_a_normal($fechaInicial),0,0,R);
$pdf->SetY(13);
$pdf->Cell(0,0,'Final: '.cambia_a_normal($fechaFinal),0,0,R);




$pdf->SetXY(2,10);
$pdf->Cell(0,0,"-Basado en fecha de cargo-",0,0,M);
$pdf->SetX(1);



$pdf->SetFont('Arial','',10);
$pdf->SetXY(2,15);
Example #13
0
$seguro = $myrow39['nomCliente'];
$auxiliar = $myrow39['ID_AUXILIAR'];
$ctaMayor = $myrow39['ID_CTAMAYOR'];
//**********cierra devolver seguro
if ($seguro) {
    $paciente = $seguro;
}
$pdf->SetFont('Arial', '', 8);
//establece el nombre del paciente
$pdf->SetXY(50, 10);
$pdf->Cell(0, 0, $auxiliar, 0, 0, L);
$pdf->SetX(1);
$pdf->SetXY(50, 15);
$pdf->Cell(0, 0, $ctaMayor, 0, 0, L);
$pdf->SetX(1);
$pdf->SetY(5);
$pdf->Cell(0, 0, $numeroTransaccion, 0, 0, R);
//numero de paciente
$pdf->SetXY(50, 5);
$pdf->Cell(0, 0, $paciente, 0, 0, L);
$pdf->SetX(1);
//cambiar fecha
//$myrow1['fecha1']=cambia_a_normal($myrow1['fecha1']);
$fecha1 = date("d/m/Y");
$pdf->SetY(10);
$pdf->Cell(0, 0, $fecha1, 0, 0, R);
//Imprimo con salto de pagina
$pdf->Ln(15);
//salto de linea
$pdf->SetFont('Arial', '', 8);
$pdf->SetXY(30, 7);
$pdf->SetFont('Arial','',10);
//establece el nombre del paciente

$pdf->SetXY(2,5);
$pdf->Cell(0,0,'REPORTE DE VENTAS PX EXTERNOS',0,0,M);
$pdf->SetX(1);


//*****************ech*************





$fecha1=$_GET['fecha'];
$pdf->SetY(8);
$pdf->Cell(0,0,'De la fecha: '.cambia_a_normal($_GET['fechaInicial']).' a la fecha: '.cambia_a_normal($_GET['fechaFinal']),0,0,R);

$pdf->SetY(12);
$pdf->Cell(0,0,'Fecha de Impresion: '.date("d/m/Y"),0,0,R);



$pdf->SetXY(2,15);
$pdf->Cell(0,0,"HOSPITAL LA CARLOTA",0,0,M);
$pdf->SetX(1); 

/* 
$pdf->SetXY(2,13);
$pdf->Cell(0,0,'Cajero(a): '.$myrow1a['usuario'],0,0,M);
$pdf->SetX(1); */
$pdf->SetFont('Arial','',10);
//establece el nombre del paciente

$pdf->SetXY(2,5);
$pdf->Cell(0,0,'Reporte de Ventas del cliente: '.$_GET['nomSeguro'],0,0,M);
$pdf->SetX(1);


//*****************ech*************




$date=date("d/m/Y");
$fechaInicial=$_GET['fechaInicial'];
$pdf->SetY(10);
$pdf->Cell(0,0,'Fecha Inicial: '.cambia_a_normal($fechaInicial),0,0,R);

$fechaFinal=$_GET['fechaFinal'];
$pdf->SetY(14);
$pdf->Cell(0,0,'Fecha Final: '.cambia_a_normal($fechaFinal),0,0,R);

$pdf->SetXY(2,10);
$pdf->Cell(0,0,"HOSPITAL LA CARLOTA",0,0,M);
$pdf->SetX(1);


$pdf->SetXY(2,13);
$pdf->Cell(0,0,"EXTERNOS",0,0,M);
$pdf->SetX(1);