$DNWR_R_RW_TIPOTELEFONO = $_SESSION['Responsable']['DNWR_R_RW_TIPOTELEFONO'];
        $DNWR_R_RW_EMAIL = $_SESSION['Responsable']['DNWR_R_RW_EMAIL'];
        $DNWR_C_RW_ID = $_SESSION['Responsable']['DNWR_C_RW_ID'];
        $DNWR_C_RW_IDRELEVNOMINA = $_SESSION['Responsable']['DNWR_C_RW_IDRELEVNOMINA'];
        $DNWR_C_RW_NOMBRE = $_SESSION['Responsable']['DNWR_C_RW_NOMBRE'];
        $DNWR_C_RW_APELLIDO = $_SESSION['Responsable']['DNWR_C_RW_APELLIDO'];
        $DNWR_C_RW_CODAREA = $_SESSION['Responsable']['DNWR_C_RW_CODAREA'];
        $DNWR_C_RW_TELEFONO = $_SESSION['Responsable']['DNWR_C_RW_TELEFONO'];
        $DNWR_C_RW_TIPOTELEFONO = $_SESSION['Responsable']['DNWR_C_RW_TIPOTELEFONO'];
        $DNWR_C_RW_EMAIL = $_SESSION['Responsable']['DNWR_C_RW_EMAIL'];
        $DNWR_C_RW_IGUALARESP = $_SESSION['Responsable']['DNWR_C_RW_IGUALARESP'];
        $CODIGOEWID = $_SESSION['Responsable']['CODIGOEWID'];
        $ArrayJsonTel = GetTelefonosJSON($CODIGOEWID);
    }
}
echo "\n\t<script type='text/javascript'> \t\t\t\t\n\t\tvar showDialogExp = " . ($GENERANOMINA ? 'true' : 'false') . ";\t\t\n\t\t\n\t\tvar TipoEstabSeleccionado = '" . $DNWE_EW_TIPOESTAB . "';\n\t\tvar TipoNominaSeleccExp = '" . $DNWE_EW_TIPONOMINA . "';\n\t\tvar CODIGOEWID = '" . $CODIGOEWID . "';\n\t\tvar CODIGOCIUU = '" . $CODIGOCIUU . "';\n\t\t\n\t\tvar ExisteNominaEnProceso = '" . $ExisteNominaEnProceso . "';\n\t\tvar ExisteNominaAnnoAnterior = '" . $ExisteNominaAnnoAnterior . "';\n\t\t\n\t\tvar ArrayJsonTelEdit = '" . $ArrayJsonTel . "';\n\t\tvar DesbloqTipoNomina = '" . $DesbloqTipoNomina . "';\n\t\tvar empresaESTABLECI = '" . $row["ES_NROESTABLECI"] . "';\n\t\tvar empresaCUIT = '" . $row["CUIT"] . "';\n\t\tvar empresaCUITSINGUION = '" . CuitExtractGuion($row["CUIT"]) . "';\n\t\tvar empresaUSUARIO = '" . substr($_SESSION["usuario"], 0, 20) . "';\t\t\n\t\t\t\n\t\tvar idActividad = '" . $_SESSION["IDACTIVIDAD"] . "';\n\t</script>\n\t";
//<!doctype html>
/*	
		".GetJS_ArrayCIUU("listaciuu").";   
		".GetJS_ArrayCIUUCodigos("listaciuuCodigos")."; 		
		".GetJS_ArrayCargo("listaCargos").";
*/
?>
<head>	
	<title>Formulario Nomina</title>	
	<link href="/styles/style2.css" rel="stylesheet">	
	<link href="/styles/style.css" rel="stylesheet">		
	<link href="/styles/rar/jquery-ui-custom.css<?php 
echo RandonNumberParameter();
?>
" rel="stylesheet">	
Beispiel #2
0
 public function EncabezadoReport()
 {
     $Contrato = 0;
     $rowEstableci = $this->DatosEstablecimiento;
     $this->filtroCUIL = CuitExtractGuion($rowEstableci["CUIT"]);
     if (isset($_SESSION['contrato'])) {
         $Contrato = $_SESSION['contrato'];
     }
     $this->Image($_SERVER["DOCUMENT_ROOT"] . "/images/logoProvARTmed.jpg", 260, 3);
     if ($this->TieneExpuestos == 'SINEXPUESTO') {
         $this->Image($_SERVER["DOCUMENT_ROOT"] . "/images/sinexpuestos.png", 10, 100, 280, 29, 'PNG');
         $this->SetDrawColor(195);
         $this->SetLineWidth(1);
         $this->Line(10, 60, 285, 180, 'PNG');
     }
     $this->SetDrawColor(0);
     $this->SetLineWidth(0);
     $this->SetXY(105, 10);
     $this->SetFont('Arial', 'B', 16);
     $this->Cell(0, 0, 'NÓMINA DE PERSONAL EXPUESTO ', 0, 0, 'L');
     $this->SetFont('Arial', "I", 6);
     $ahora = $rowEstableci["FECHASERVER"];
     $this->SetXY(5, 5);
     $this->Cell(0, 0, 'Fecha Impresión : ' . $ahora . "  ", 0, 0, 'L');
     /*
     if($this->TieneExpuestos == 'CONEXPUESTO' and $this->AnnoProcesar == 'ACTUAL' ){
     	$this->SetXY(5, 8);
     	$this->Write(1, 'Versión : '.$rowEstableci["VERSIONNOMINA"] );
     	$this->SetXY(5, 10);
     	$this->Write(1, 'Fecha : '.$rowEstableci["FECHAIMPRESIONNOMINA"] );
     }
     */
     /**************************************************************/
     $this->SetFillColor(0, 0, 0);
     $this->Rect(3, 18, 290, 6, 'F');
     $this->SetXY(5, 21);
     $this->SetTextColor(254, 254, 254);
     $this->SetFont('Arial', 'B', 10);
     $this->Cell(0, 0, "DATOS DE LA EMPRESA", 0, 0, 'L');
     $this->SetFillColor(254, 254, 254);
     $this->SetTextColor(0, 0, 0);
     /******** RENGLON 1 ******************************************************/
     $SizeFont = 8;
     $posy1 = 23;
     $this->SetXY(5, $posy1);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Write(10, "Razón Social : " . $rowEstableci["NOMBRE"]);
     $this->SetXY(175, $posy1);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Write(10, "C.U.I.T. .: " . $rowEstableci["CUIT"] . "   ");
     $this->SetXY(245, $posy1);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Write(10, "Contrato nº : " . $Contrato);
     $posy = 30;
     $this->line(3, $posy, 290, $posy);
     /******** RENGLON 2 ******************************************************/
     $posy2 = 29;
     $this->SetXY(5, $posy2);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Write(10, "Establecimiento (nº y nombre) : " . $rowEstableci["RAZONSOCIAL"]);
     $this->SetXY(145, $posy2);
     $this->SetFont('Arial', '', $SizeFont);
     //$this->Write(10,"CIIU _".$rowEstableci["CIIUEMPRESA"]);
     $this->Cell(0, 10, utf8_decode("CIIU : " . $rowEstableci["CIIUEMPRESA"]), 0, 0, 'L');
     $this->SetXY(195, $posy2);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Write(10, "Actividad :" . $rowEstableci["ACTIVIDAD"]);
     $this->SetXY(235, $posy2);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Write(10, "Cantidad de trabajadores : " . $rowEstableci["CANTIDADEMPLEADOS"]);
     $posy = 36;
     $this->line(3, $posy, 290, $posy);
     /******** RENGLON 3 ******************************************************/
     $posy3 = 35;
     $this->SetXY(5, $posy3);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Cell(65, 10, "Dirección : " . $rowEstableci["DOMICILIO"], 0, 0, 'L');
     $this->SetXY(75, $posy3);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Cell(50, 10, "Localidad : " . $rowEstableci["LOCALIDAD"], 0, 0, 'L');
     $this->SetXY(125, $posy3);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Write(10, "Provincia : " . $rowEstableci["PROVINCIA"]);
     $this->SetXY(175, $posy3);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Write(10, "Teléfono : " . $rowEstableci["TELEFONO"]);
     $this->SetXY(250, $posy3);
     $this->SetFont('Arial', '', $SizeFont);
     $this->Write(10, "Fax :" . $rowEstableci["FAX"]);
     $posy = 42;
     $this->line(3, $posy, 290, $posy);
     /**************************************************************/
     $tplIdx = $this->importPage(1);
     $this->useTemplate($tplIdx);
     $this->SetXY(5, 50);
     $this->SetFontAlignGeneral();
     //$this->SetFont('Arial' , 'B', 8);
     $this->SetFillColor(0, 0, 0);
     $this->SetTextColor(254, 254, 254);
     $this->SetFont('Arial', 'B', 8);
     $this->Rect(3, 47, 290, 12, 'F');
     $this->SetX(10);
     //$this->DibujaLineaSepara();
     $this->Row(array($this->trimUTF8("C.U.I.L."), $this->trimUTF8("Nombre Apellido"), $this->trimUTF8("Fecha de Ingreso a la Empresa"), $this->trimUTF8("Fecha de Inicio de la Exposición"), $this->trimUTF8("Sector de Trabajo"), $this->trimUTF8("Puesto de Trabajo"), $this->trimUTF8("Identificación de riesgo ESOP")));
     $this->SetFillColor(254, 254, 254);
     $this->SetTextColor(0, 0, 0);
 }
Beispiel #3
0
function Insert_NominaActualdeNominaAnterior($idEstablecimiento, $cuitEmpresa, $usualta)
{
    $cuitEmpresa = CuitExtractGuion($cuitEmpresa);
    $sql = obtener_NominaAnnoAnterior();
    try {
        global $conn;
        $paramsBusca = array(":IDESTABWEB" => $idEstablecimiento, ":CUIT" => $cuitEmpresa);
        $IDestableciWeb = ValorSql("SELECT  NVL(ew_id, 0) \n\t\t\t\t\t\t\t\t\t  FROM  hys.hew_establecimientoweb  \n\t\t\t\t\t\t\t\t\t WHERE  ew_estableci = :IDESTABWEB\n\t\t\t\t\t\t\t\t\t   AND  ew_cuit = :CUIT \n\t\t\t\t\t\t\t\t\t   AND nvl(ew_idmotivorechazo, 0) = 0 ", "", $paramsBusca);
        $cantidad = 0;
        $lista_resultados = '';
        if ($IDestableciWeb == 0 or $IDestableciWeb == '') {
            $rowEstableci = BuscarDetalleEstableci($idEstablecimiento, $cuitEmpresa);
            $CUIT = $cuitEmpresa;
            $ESTABLECI = $idEstablecimiento;
            $TIPOESTAB = 'O';
            $TIPONOMINA = 'S';
            $IDACTIVIDAD = $rowEstableci['ES_IDACTIVIDAD'];
            $DESCRIPCIONESTAB = $rowEstableci['AC_DESCRIPCION'];
            $USUALTA = $usualta;
            $IDestableciWeb = Insert_EstablecimientoWEB($conn, $CUIT, $ESTABLECI, $TIPOESTAB, $TIPONOMINA, $IDACTIVIDAD, $DESCRIPCIONESTAB, $USUALTA);
        }
        $idcabeceranomina = Insert_CabeceraNominaWEB($conn, $IDestableciWeb, $cantidad, $usualta);
        $params = array(":cuit" => $cuitEmpresa, ":estableci" => $idEstablecimiento);
        $stmt = DBExecSql($conn, $sql, $params);
        while ($row = DBGetQuery($stmt)) {
            $cuilTrabajador = $row["CUIL"];
            $nombre = $row["NOMBRE"];
            $fechaingreso = $row["FECHAINGRESO"];
            $fechainiexpo = $row["FECHAINIEXPO"];
            $sectortrab = $row["SECTOR"];
            $puestotrab = $row["PUESTO"];
            $resultValida = Valida_TrabajadorEnOtraNomina($cuilTrabajador, $cuitEmpresa, $idEstablecimiento);
            if ($resultValida == 0) {
                Insert_DetalleNominaWEB($conn, $idcabeceranomina, $cuilTrabajador, $nombre, $fechaingreso, $sectortrab, $puestotrab, $usualta);
                $cantidad++;
            } else {
                $showtext = ' - <b>' . $nombre . '</b> <i>cuil (' . $cuilTrabajador . ')</i> ';
                switch ($resultValida) {
                    case 1:
                        $lista_resultados .= $showtext . ' fue presentado en una nomina web <p>';
                        break;
                    case 2:
                        $lista_resultados .= $showtext . ' esta declarado en una nomina ya aprobada <p>';
                        break;
                    case 3:
                        $lista_resultados .= $showtext . ' ya esta ingresado en una nomina web <p>';
                        break;
                }
            }
        }
        Update_CantidadCabeceraNominaWEB($conn, $idcabeceranomina, $cantidad, $usualta);
        SetSessionVarNPE($IDestableciWeb, $cuitEmpresa, 'NominaPersonalExpuesto');
        DBCommit($conn);
        return $lista_resultados;
    } catch (Exception $e) {
        DBRollback($conn);
        SalvarErrorTxt(__FILE__, __FUNCTION__, __LINE__, $e->getMessage());
        return RetronaXML($e->getMessage());
    }
}