示例#1
0
    public DataSet TraePreguntas_DB(OracleConnection cnx)
    {
        MCommand objComando = new MCommand();

        int cod_ramo = Convert.ToInt32(WebConfigurationManager.AppSettings["RAMO"].ToString());

        try
        {
            objComando.Connection = cnx;

            objComando.CommandText = "MEL_K_LOGICA_PREGUNTAS.P_LISTA_PREGUNTAS";

            objComando.agregarINParametro("P_COD_RAMO", OracleDbType.Int32, cod_ramo);
            objComando.agregarOUTParametro("C_DATOS", OracleDbType.RefCursor, 0);

            return(objComando.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("Error al Traer Preguntas para Declaracion Estado " + ex.Message);
        }
        finally
        {
            cnx.Dispose();
        }
    }
示例#2
0
    public DataSet PlanesPagoConvenio_DB(string cod_cia, string cod_ramo, string tip_pago, string cod_agt, string cod_convenio, OracleConnection strConexion)
    {
        try
        {
            MCommand objCommand = new MCommand();

            objCommand.Connection = strConexion;

            objCommand.CommandText = "p_plan_pago_convenio";

            objCommand.agregarINParametro("p_cod_cia", OracleDbType.Varchar2, cod_cia);
            objCommand.agregarINParametro("p_cod_ramo", OracleDbType.Varchar2, cod_ramo);
            objCommand.agregarINParametro("p_cod_agt", OracleDbType.Varchar2, cod_agt);
            objCommand.agregarINParametro("p_cod_convenio", OracleDbType.Varchar2, cod_convenio);
            objCommand.agregarINParametro("p_tip_pago", OracleDbType.Varchar2, tip_pago);
            objCommand.agregarOUTParametro("p_cursor", OracleDbType.RefCursor, 0);
            objCommand.agregarOUTParametro("p_error", OracleDbType.Varchar2, 500);

            return(objCommand.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("ERROR Cobranza_DB.PlanesPago_DB : " + ex.Message);
        }
    }
示例#3
0
    public DataSet MarcaTarjetas_DB(OracleConnection strConexion)
    {
        try
        {
            MCommand objCommand = new MCommand();

            objCommand.Connection = strConexion;

            objCommand.CommandText = "MEL_K_MAPFRE_MCL.P_TRAE_TARJETAS";

            objCommand.agregarOUTParametro("p_cursor", OracleDbType.RefCursor, 0);
            objCommand.agregarOUTParametro("p_error", OracleDbType.Varchar2, 500);

            return(objCommand.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("ERROR Cobranza_DB.MarcaTarjetas_DB : " + ex.Message);
        }
    }
示例#4
0
    public DataSet getColores(OracleConnection cnx)
    {
        MCommand objComando = new MCommand();

        try
        {
            objComando.Connection = cnx;

            objComando.CommandText = "MEL_K_MAPFRE.P_colores";

            objComando.agregarINParametro("p_where", OracleDbType.Varchar2, "1=1");
            objComando.agregarOUTParametro("c_colores", OracleDbType.RefCursor, 0);
            objComando.agregarOUTParametro("p_error", OracleDbType.Varchar2, 255);

            return(objComando.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("ERROR Cotizador.ValidaSuplantacion : " + ex.Message);
        }
    }
示例#5
0
    public DataSet getModelos(OracleConnection cnx, string cod_marca)
    {
        MCommand objComando = new MCommand();

        try
        {
            objComando.Connection = cnx;

            objComando.CommandText = "MEL_K_MAPFRE.get_modelos";

            objComando.agregarINParametro("v_marca", OracleDbType.Varchar2, cod_marca);
            objComando.agregarOUTParametro("p_modelos", OracleDbType.RefCursor, 0);
            objComando.agregarOUTParametro("P_ERROR", OracleDbType.Varchar2, 255);

            return(objComando.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("ERROR Cotizador.ValidaSuplantacion : " + ex.Message);
        }
    }
示例#6
0
    public DataSet getMarcas(OracleConnection cnx, string cod_marca)
    {
        MCommand objComando = new MCommand();

        try
        {
            objComando.Connection = cnx;

            objComando.CommandText = "tron2000.mel_k_mapfre_mcl.get_marca";

            objComando.agregarINParametro("v_marca", OracleDbType.Varchar2, cod_marca);
            objComando.agregarOUTParametro("p_marca", OracleDbType.RefCursor, 0);
            objComando.agregarOUTParametro("p_error", OracleDbType.Varchar2, 255);

            return(objComando.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("Error al capturar M " + ex.Message);
        }
    }
示例#7
0
    public DataSet PlanesPago_DB(int cod_cia, OracleConnection strConexion)
    {
        try
        {
            MCommand objCommand = new MCommand();

            objCommand.Connection = strConexion;

            objCommand.CommandText = "MEL_K_MAPFRE.P_TRAE_PLANES_PAGO";

            objCommand.agregarINParametro("p_cod_cia", OracleDbType.Int32, cod_cia);
            objCommand.agregarOUTParametro("p_cursor", OracleDbType.RefCursor, 0);
            objCommand.agregarOUTParametro("p_error", OracleDbType.Varchar2, 500);

            return(objCommand.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("ERROR Cobranza_DB.PlanesPago_DB : " + ex.Message);
        }
    }
示例#8
0
    public DataSet getRegion_despacho(OracleConnection cnx, string str_cod_pais)
    {
        MCommand objComando = new MCommand();

        try
        {
            objComando.Connection = cnx;

            objComando.CommandText = "MEL_K_MAPFRE.P_REGION_DESPACHO";

            objComando.agregarINParametro("p_cod_pais", OracleDbType.Varchar2, str_cod_pais);
            objComando.agregarOUTParametro("c_regiones", OracleDbType.RefCursor, 0);
            objComando.agregarOUTParametro("P_ERROR", OracleDbType.Varchar2, 255);

            return(objComando.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("Error al capturar Regiones " + ex.Message);
        }
    }
示例#9
0
    public DataSet getPartesVeh(OracleConnection cnx)
    {
        MCommand objComando = new MCommand();

        try
        {
            objComando.Connection = cnx;

            objComando.CommandText = "tron2000.MEL_K_MAPFRE_MCL.P_PARTES_VEHICULO";

            objComando.agregarINParametro("p_where", OracleDbType.Varchar2, "1=1");
            objComando.agregarOUTParametro("c_partes", OracleDbType.RefCursor, 0);
            objComando.agregarOUTParametro("c_danos", OracleDbType.RefCursor, 0);
            objComando.agregarOUTParametro("p_error", OracleDbType.Varchar2, 255);

            return(objComando.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("ERROR Cotizador.getPartesVeh : " + ex.Message);
        }
    }
示例#10
0
    public DataSet getComuna(OracleConnection cnx, string str_cod_pais, string str_cod_prov)
    {
        MCommand objComando = new MCommand();

        try
        {
            objComando.Connection = cnx;

            objComando.CommandText = "MEL_K_MAPFRE.P_COMUNA";

            objComando.agregarINParametro("P_COD_PAIS", OracleDbType.Varchar2, str_cod_pais);
            objComando.agregarINParametro("P_COD_PROV", OracleDbType.Varchar2, str_cod_prov);
            objComando.agregarOUTParametro("C_COMUNAS", OracleDbType.RefCursor, 0);
            objComando.agregarOUTParametro("P_ERROR", OracleDbType.Varchar2, 255);

            return(objComando.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("ERROR Cotizador.ValidaSuplantacion : " + ex.Message);
        }
    }
示例#11
0
    public DataSet getCiudad_despacho(OracleConnection cnx, string str_cod_pais, string str_cod_estado)
    {
        MCommand objComando = new MCommand();

        try
        {
            objComando.Connection = cnx;

            objComando.CommandText = "MEL_K_MAPFRE.P_Ciudad_despacho";

            objComando.agregarINParametro("p_cod_pais", OracleDbType.Varchar2, str_cod_pais);
            objComando.agregarINParametro("p_cod_estado", OracleDbType.Varchar2, str_cod_estado);
            objComando.agregarOUTParametro("c_ciudades", OracleDbType.RefCursor, 0);
            objComando.agregarOUTParametro("P_ERROR", OracleDbType.Varchar2, 255);

            return(objComando.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("ERROR Cotizador.ValidaSuplantacion : " + ex.Message);
        }
    }
示例#12
0
    public DataSet DatosTerceroTronWeb_DB(OracleConnection cnx, string cod_docum)
    {
        MCommand objComando = new MCommand();

        try
        {
            objComando.Connection = cnx;

            objComando.CommandText = "MEL_K_TERCERO_TRN.P_TRAE_DATOS_ASEGURADO";

            //objComando.agregarINParametro("p_cod_cia", OracleDbType.Varchar2, "1");
            objComando.agregarINParametro("p_cod_docum_aseg", OracleDbType.Varchar2, cod_docum);
            objComando.agregarOUTParametro("p_cursor", OracleDbType.RefCursor, 0);
            objComando.agregarOUTParametro("p_error", OracleDbType.Varchar2, 255);

            return(objComando.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("Error al capturar Regiones " + ex.Message);
        }
    }
示例#13
0
    public DataSet getDescuentosOpcionales_DB(string cod_docum, string cod_ramo, OracleConnection cnx)
    {
        MCommand objComando = new MCommand();

        try
        {
            objComando.Connection = cnx;

            objComando.CommandText = "MEL_K_BOLSA_DESCUENTO.P_DESCUENTOS_OPCIONALES";

            objComando.agregarINParametro("P_COD_CIA", OracleDbType.Int32, 1);
            objComando.agregarINParametro("P_COD_DOCUM", OracleDbType.Varchar2, cod_docum);
            objComando.agregarINParametro("P_COD_RAMO", OracleDbType.Varchar2, cod_ramo);
            objComando.agregarOUTParametro("PO_RESU", OracleDbType.RefCursor, 0);
            objComando.agregarOUTParametro("PO_ERROR", OracleDbType.Varchar2, 255);

            return(objComando.ejecutarRefCursorSP());
        }
        catch (Exception ex)
        {
            throw new Exception("ERROR Cotizador.getDescuentosOpcionales_DB : " + ex.Message);
        }
    }