예제 #1
0
    public static DataRow DatosTerceroTronWeb(string cod_docum)
    {
        try
        {
            using (OracleConnection cnx = MConexion.getConexion("OVDES"))
            {
                Tercero_DB objdb = new Tercero_DB();

                DataTable dt = new DataTable();

                DataSet ds = objdb.DatosTerceroTronWeb_DB(cnx, cod_docum);

                dt = ds.Tables[0];
                if (dt.Rows.Count > 0)
                {
                    return(dt.Rows[0]);
                }
                else
                {
                    return(null);
                }
            }
        }
        catch (Exception ex)
        {
            throw new Exception(ex.Message);
        }
    }
예제 #2
0
    public static bool ClienteBloqueado(string cod_docum)
    {
        DataRow    tercero    = null;
        Tercero_DB objtercero = new Tercero_DB();

        try
        {
            using (OracleConnection Conexion = MConexion.getConexion("OVDES"))
            {
                tercero = objtercero.ClienteBloqueado_DB(cod_docum, Conexion);

                if (tercero["p_retorno"].ToString() == "N")
                {
                    return(true); /* NO ESTA BLOQUEADO */
                }
                else
                {
                    return(false); /* ESTA BLOQUEADO */
                }
            }
        }
        catch
        {
            return(true);
        }
    }
예제 #3
0
    public static DataRow GuardaTerceroCotizacion(string P_NUM_COTIZACION,
                                                  string COD_DOCUM_ASEG,
                                                  string P_NOMBRES,
                                                  string P_AP_PATERNO,
                                                  string P_AP_MATERNO,
                                                  string P_MAIL,
                                                  string P_CELULAR,
                                                  string P_FONO_FIJO)
    {
        try
        {
            using (OracleConnection Conexion = MConexion.getConexion("OVDES"))
            {
                Tercero_DB objdb = new Tercero_DB();

                DataRow objdatos_tercero = objdb.GuardaTerceroCotizacion_DB(P_NUM_COTIZACION,
                                                                            COD_DOCUM_ASEG,
                                                                            P_NOMBRES,
                                                                            P_AP_PATERNO,
                                                                            P_AP_MATERNO,
                                                                            P_MAIL,
                                                                            P_CELULAR,
                                                                            P_FONO_FIJO,
                                                                            Conexion);

                return(objdatos_tercero);
            }
        }

        catch (Exception ex)
        {
            throw new Exception(ex.Message);
        }
    }
예제 #4
0
    public static string TraeCorreo(string cod_docum)
    {
        try
        {
            using (OracleConnection Conexion = MConexion.getConexion("OVDES"))
            {
                DataRow objdatos_tercero = Tercero_DB.TraeCorreo_DB(cod_docum, Conexion);

                return(objdatos_tercero["p_correo"].ToString());
            }
        }
        catch (Exception ex)
        {
            throw new Exception(ex.Message);
        }
    }
예제 #5
0
    public static DataRow GuardaTer(string cod_docum, string ape1_tercero, string ape2_tercero, string nom_tercero, string nom_direccion, int cod_region, int cod_ciudad, int cod_comuna, string tlf_pais, string tlf_zona, string tlf_numero, string mca_sexo)
    {
        try
        {
            using (OracleConnection Conexion = MConexion.getConexion("OVDES"))
            {
                Tercero_DB objdb = new Tercero_DB();

                DataRow objdatos_tercero = objdb.GuardaTer_DB(cod_docum, ape1_tercero, ape2_tercero, nom_tercero, nom_direccion, cod_region, cod_ciudad, cod_comuna, tlf_pais, tlf_zona, tlf_numero, mca_sexo, Conexion);

                return(objdatos_tercero);
            }
        }

        catch (Exception ex)
        {
            throw new Exception(ex.Message);
        }
    }
예제 #6
0
    public static string ValidaGAP(string cod_docum)
    {
        try
        {
            using (OracleConnection Conexion = MConexion.getConexion("OVDES"))
            {
                Tercero_DB objdb = new Tercero_DB();

                DataRow objdatos_tercero = objdb.ValidaGAP_DB(cod_docum, Conexion);

                return(objdatos_tercero["P_RESPUESTA"].ToString());
            }
        }

        catch (Exception ex)
        {
            throw new Exception(ex.Message);
        }
    }
예제 #7
0
    public static DataRow DatosAutomotora(string cod_docum_automotora)
    {
        try
        {
            using (OracleConnection Conexion = MConexion.getConexion("OVDES"))
            {
                Tercero_DB objdb = new Tercero_DB();

                DataRow objdatos_tercero = objdb.DatosAutomotora_DB(cod_docum_automotora, Conexion);

                return(objdatos_tercero);
            }
        }

        catch (Exception ex)
        {
            throw new Exception(ex.Message);
        }
    }
예제 #8
0
    public static string CuentaHabilitada(string cod_docum)
    {
        try
        {
            using (OracleConnection Conexion = MConexion.getConexion("OVDES"))
            {
                Tercero_DB objdb = new Tercero_DB();

                DataRow objdatos_tercero = objdb.CuentaHabilitada_DB(cod_docum, Conexion);

                return(objdatos_tercero["p_existe"].ToString());
            }
        }

        catch (Exception ex)
        {
            throw new Exception(ex.Message);
        }
    }
예제 #9
0
    public static DataRow GuardaNomTer(string cod_docum, string ape1_tercero, string ape2_tercero, string nom_tercero)
    {
        try
        {
            using (OracleConnection Conexion = MConexion.getConexion("OVDES"))
            {
                Tercero_DB objdb = new Tercero_DB();

                DataRow objdatos_tercero = objdb.GuardaNomTer_DB(cod_docum, ape1_tercero, ape2_tercero, nom_tercero, Conexion);

                return(objdatos_tercero);
            }
        }

        catch (Exception ex)
        {
            throw new Exception(ex.Message);
        }
    }