Inheritance: BPBase
Esempio n. 1
0
        void SelectSolicitud()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);

                // Transacción
                oENTResponse = oBPQueja.SelectSolicitud_Detalle(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Campos ocultos
                this.hddEstatusId.Value = oENTResponse.dsResponse.Tables[1].Rows[0]["EstatusId"].ToString();
                this.hddFuncionarioId.Value = oENTResponse.dsResponse.Tables[1].Rows[0]["FuncionarioId"].ToString();
                this.hddCalificacionId.Value = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionId"].ToString();

                // Formulario
                this.SolicitudNumero.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["SolicitudNumero"].ToString();
                this.EstatusaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["EstatusNombre"].ToString();
                this.AfectadoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Afectado"].ToString();

                this.FuncionarioLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FuncionarioNombre"].ToString();
                this.ContactoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FormaContactoNombre"].ToString();
                this.TipoSolicitudLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoSolicitudNombre"].ToString();
                this.ProblematicaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaNombre"].ToString();
                this.ProblematicaDetalleLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaDetalleNombre"].ToString();

                this.FechaRecepcionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaRecepcion"].ToString();
                this.FechaAsignacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaAsignacion"].ToString();
                this.FechaGestionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaInicioGestion"].ToString();
                this.FechaModificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaUltimaModificacion"].ToString();
                this.NivelAutoridadLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["NivelAutoridadNombre"].ToString();
                this.MecanismoAperturaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["MecanismoAperturaNombre"].ToString();

                this.TipoOrientacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoOrientacionNombre"].ToString();
                this.LugarHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["LugarHechosNombre"].ToString();
                this.DireccionHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["DireccionHechos"].ToString();
                this.ObservacionesLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Observaciones"].ToString();

                // Cierre de Orientación
                if ( oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionId"].ToString() != "3" ){
                    this.CierreOrientacionLabel.Visible = false;
                    this.TipoOrientacionLabel.Visible = false;
                }

                // Canalizaciones
                if (oENTResponse.dsResponse.Tables[7].Rows.Count > 0){

                    this.CanalizacionesLabel.Visible = true;

                    this.grdCanalizacion.DataSource = oENTResponse.dsResponse.Tables[7];
                    this.grdCanalizacion.DataBind();
                }

                // Calificacion
                this.CalificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionNombre"].ToString();
                this.FundamentoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Fundamento"].ToString();

                // Grid
                this.gvCiudadano.DataSource = oENTResponse.dsResponse.Tables[2];
                this.gvCiudadano.DataBind();

                // Documentos
                if (oENTResponse.dsResponse.Tables[3].Rows.Count == 0){

                    this.SinDocumentoLabel.Text = "<br /><br />No hay documentos anexados a la solicitud";
                }else{

                    this.SinDocumentoLabel.Text = "";
                    this.dlstDocumentoList.DataSource = oENTResponse.dsResponse.Tables[3];
                    this.dlstDocumentoList.DataBind();
                }

                // Asuntos
                if (oENTResponse.dsResponse.Tables[4].Rows.Count == 0){

                    this.SinComentariosLabel.Text = "<br /><br />No hay asuntos para esta solicitud";
                    this.repComentarios.DataSource = null;
                    this.repComentarios.DataBind();
                    this.ComentarioTituloLabel.Text = "";
                }else{

                    this.SinComentariosLabel.Text = "";
                    this.repComentarios.DataSource = oENTResponse.dsResponse.Tables[4];
                    this.repComentarios.DataBind();
                    this.ComentarioTituloLabel.Text = oENTResponse.dsResponse.Tables[4].Rows.Count.ToString() + " asuntos";

                    CheckDeleteLinkComentario();

                }

            }catch (Exception ex){
                throw (ex);
            }
        }
        void SelectSolicitud( Boolean Recovery)
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            ENTSession oSession = (ENTSession)Session["oENTSession"];

            try
            {

                // Formulario
                oENTQueja.Numero = this.txtNumeroSolicitud.Text.Trim();
                oENTQueja.Nombre = this.txtCiudadano.Text.Trim();
                oENTQueja.FormaContactoId = Int32.Parse(this.ddlFormaContacto.SelectedValue);
                oENTQueja.FuncionarioId = Int32.Parse(this.ddlFuncionario.SelectedValue);
                oENTQueja.FechaDesde = (Recovery ? dtBeginDate : this.wucBeginDate.BeginDate);
                oENTQueja.FechaHasta = (Recovery ? dtEndDate : this.wucEndDate.EndDate);

                // Transacción
                oENTResponse = oBPQueja.SelectSolicitud_Filtro(oENTQueja);

                // Errores
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }

                // Warnings
                if (oENTResponse.sMessage != "") { ScriptManager.RegisterStartupScript(this.Page, this.GetType(), Convert.ToString(Guid.NewGuid()), "alert('" + oENTResponse.sMessage + "');", true); }

                // Llenado de control
                this.gvSolicitud.DataSource = oENTResponse.dsResponse.Tables[1];
                this.gvSolicitud.DataBind();

            }catch (Exception ex){
                throw (ex);
            }
        }
        void UpdateSolicitud_Calificacion()
        {
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            BPQueja oBPQueja = new BPQueja();

            DataTable tblCanalizacion = null;
            DataRow rowCanalizacion;

            try
            {

                // Obtener el DataTable del grid
                tblCanalizacion = gcParse.GridViewToDataTable(this.grdCanalizacion, false);

                // Validaciones
                if (this.ddlProblematica.SelectedIndex == 0) { throw (new Exception("Es necesario seleccionar una Problemática")); }
                if (this.ddlProblematicaDetalle.SelectedIndex == 0) { throw (new Exception("Es necesario seleccionar un Detalle de Problemática")); }
                if (this.ddlMecanismoApertura.SelectedIndex == 0) { throw (new Exception("Es necesario seleccionar un Mecanismo de Apertura")); }
                if (this.ddlNivelAutoridad.SelectedIndex == 0) { throw (new Exception("Es necesario seleccionar un Nivel de Autoridad")); }
                if (this.ddlCalificacion.SelectedIndex == 0) { throw (new Exception("Es necesario seleccionar una Calificación")); }
                if (this.ddlTipoOrientacion.Enabled && this.ddlTipoOrientacion.SelectedItem.Value == "0") { throw (new Exception("Es necesario seleccionar un Cierre de Orientación")); }
                if (this.ddlCanalizacion.Enabled && tblCanalizacion.Rows.Count == 0) { throw (new Exception("Es necesario seleccionar una Canalización")); }
                if (this.ckeFundamento.Text.Trim() == "") { throw (new Exception("Es necesario ingresar un fundamento")); }

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.ProblematicaId = Int32.Parse(this.ddlProblematica.SelectedItem.Value);
                oENTQueja.ProblematicaDetalleId = Int32.Parse(this.ddlProblematicaDetalle.SelectedItem.Value);
                oENTQueja.MecanismoAperturaId = Int32.Parse(this.ddlMecanismoApertura.SelectedItem.Value);
                oENTQueja.NivelAutoridadId = Int32.Parse(this.ddlNivelAutoridad.SelectedItem.Value);
                oENTQueja.CalificacionId = Int32.Parse(this.ddlCalificacion.SelectedItem.Value);
                oENTQueja.TipoOrientacionId = Int32.Parse(this.ddlTipoOrientacion.SelectedItem.Value);
                oENTQueja.Fundamento = this.ckeFundamento.Text.Trim();
                oENTQueja.MediosComunicacion = Int16.Parse( ( this.chkMedioComunicacion.Checked ? 1 : 0 ).ToString() );

                // Canalizaciones seleccionadas
                oENTQueja.tblCanalizacion = new DataTable("tblCanalizacion");
                oENTQueja.tblCanalizacion.Columns.Add("CanalizacionId", typeof(Int32));

                foreach(DataRow oDataRow in tblCanalizacion.Rows){

                    rowCanalizacion = oENTQueja.tblCanalizacion.NewRow();
                    rowCanalizacion["CanalizacionId"] = oDataRow["CanalizacionId"];
                    oENTQueja.tblCanalizacion.Rows.Add(rowCanalizacion);
                }

                // Transacción
                oENTResponse = oBPQueja.UpdateSolicitudCalificacion(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 4
0
        // Rutinas del programador
        void CreateFolio()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            String CalificacionId = this.hddCalificacionId.Value;

            try
            {

                // Validaciones - A excepcion de la clasificación Orientación/Apoyo, será necesario seleccionar una visitaduría
                if (CalificacionId != "3" && CalificacionId != "9"){
                    if (this.ddlVisitaduria.SelectedItem.Value == "0") { throw (new Exception("Es necesario seleccionar una Visitaduría")); }
                }

                // Determinar el Tipo de Folio
                switch (CalificacionId){
                    case "2": // Queja
                    case "4": // SI
                    case "5": // Otra CEDH
                    case "6": // Comisión Nacional de los Derechos Humanos

                        oENTQueja.TipoFolio = 1; // Folio de Queja
                        break;

                    case "3": // Orientación
                    case "9": // Apoyo o colaboración

                        oENTQueja.TipoFolio = 2; // Folio de Orientacion
                        break;

                    case "7": // Solicitud de gestión

                        // DORQ
                        if(this.ddlVisitaduria.SelectedItem.Value == "3"){
                            oENTQueja.TipoFolio = 3;
                        }

                        // Primera Visitaduría (igual que DORQ)
                        if(this.ddlVisitaduria.SelectedItem.Value == "4"){
                            oENTQueja.TipoFolio = 3;
                        }

                        // Coordinación Penitenciaria
                        if(this.ddlVisitaduria.SelectedItem.Value == "10"){
                            oENTQueja.TipoFolio = 4;
                        }

                        break;

                    case "8": // Medidas Cautelares

                        oENTQueja.TipoFolio = 5; // Folio de Medida Cautelar
                        break;

                    default: // No configurada

                        throw (new Exception("Opción no configurada"));
                }

                // Transacción
                oENTResponse = oBPQueja.CreateFolio(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Transación exitosa
                this.lblExpediente.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["NumeroFolio"].ToString();

            }catch(Exception ex){
                throw(ex);
            }
        }
        void SelectSolicitud_Cierre()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);

                // Transacción
                oENTResponse = oBPQueja.SelectSolicitud_Cierre(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Campos ocultos
                this.hddCalificacionId.Value = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionId"].ToString();

                // Formulario
                this.SolicitudNumero.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["SolicitudNumero"].ToString();
                this.EstatusaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["EstatusNombre"].ToString();
                this.AfectadoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Afectado"].ToString();

                this.FuncionarioLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FuncionarioNombre"].ToString();
                this.ContactoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FormaContactoNombre"].ToString();
                this.TipoSolicitudLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoSolicitudNombre"].ToString();
                this.ProblematicaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaNombre"].ToString();
                this.ProblematicaDetalleLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaDetalleNombre"].ToString();

                this.FechaRecepcionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaRecepcion"].ToString();
                this.FechaAsignacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaAsignacion"].ToString();
                this.FechaGestionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaInicioGestion"].ToString();
                this.FechaModificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaUltimaModificacion"].ToString();
                this.NivelAutoridadLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["NivelAutoridadNombre"].ToString();
                this.MecanismoAperturaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["MecanismoAperturaNombre"].ToString();

                this.TipoOrientacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoOrientacionNombre"].ToString();
                this.LugarHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["LugarHechosNombre"].ToString();
                this.DireccionHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["DireccionHechos"].ToString();
                this.ObservacionesLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Observaciones"].ToString();

                // Cierre de Orientación
                if ( oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionId"].ToString() != "3" ){
                    this.CierreOrientacionLabel.Visible = false;
                    this.TipoOrientacionLabel.Visible = false;
                }

                // Canalizaciones
                if (oENTResponse.dsResponse.Tables[7].Rows.Count > 0){

                    this.CanalizacionesLabel.Visible = true;

                    this.grdCanalizacion.DataSource = oENTResponse.dsResponse.Tables[7];
                    this.grdCanalizacion.DataBind();
                }

                // Calificacion
                this.CalificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionNombre"].ToString();
                this.FundamentoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Fundamento"].ToString();

                // Ciudadanos
                this.gvCiudadano.DataSource = oENTResponse.dsResponse.Tables[2];
                this.gvCiudadano.DataBind();

                // Documentos
                if (oENTResponse.dsResponse.Tables[8].Rows.Count == 0){

                    this.SinDocumentoLabel.Text = "<br /><br />No hay documentos anexados a la solicitud";
                }else{

                    this.SinDocumentoLabel.Text = "";
                    this.dlstDocumentoList.DataSource = oENTResponse.dsResponse.Tables[8];
                    this.dlstDocumentoList.DataBind();
                }

                // Comentarios
                if (oENTResponse.dsResponse.Tables[3].Rows.Count == 0){

                    this.SinComentariosLabel.Text = "<br /><br />No hay comentarios para esta solicitud";
                }else{

                    this.SinComentariosLabel.Text = "";
                    this.repComentarios.DataSource = oENTResponse.dsResponse.Tables[3];
                    this.repComentarios.DataBind();
                    this.ComentarioTituloLabel.Text = oENTResponse.dsResponse.Tables[3].Rows.Count.ToString() + " comentarios";
                }

                // Autoridad y voces señaladas
                this.gvAutoridades.DataSource = oENTResponse.dsResponse.Tables[4];
                this.gvAutoridades.DataBind();

                // Diligencias
                this.gvDiligencia.DataSource = oENTResponse.dsResponse.Tables[5];
                this.gvDiligencia.DataBind();

                // Seleccionar indicadores
                for (int k = 0; k < this.chkIndicadorGenero.Items.Count; k++) {

                    if (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorGenero.Items[k].Value).Length == 1) {
                        this.chkIndicadorGenero.Items[k].Selected = true;
                        this.chkIndicadorGenero.Items[k].Attributes.Add("Style", "color:red;");
                    }
                    this.chkIndicadorGenero.Items[k].Enabled = false;
                }

                for (int k = 0; k < this.chkIndicadorEdad.Items.Count; k++) {

                    if (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorEdad.Items[k].Value).Length == 1) {
                        this.chkIndicadorEdad.Items[k].Selected = true;
                        this.chkIndicadorEdad.Items[k].Attributes.Add("Style", "color:red;");
                    }
                    this.chkIndicadorEdad.Items[k].Enabled = false;
                }

                for (int k = 0; k < this.chkIndicadorActividad.Items.Count; k++) {

                    if (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorActividad.Items[k].Value).Length == 1) {
                        this.chkIndicadorActividad.Items[k].Selected = true;
                        this.chkIndicadorActividad.Items[k].Attributes.Add("Style", "color:red;");
                    }
                    this.chkIndicadorActividad.Items[k].Enabled = false;
                }

                for (int k = 0; k < this.chkIndicadorCondicion.Items.Count; k++) {

                    if (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorCondicion.Items[k].Value).Length == 1) {
                        this.chkIndicadorCondicion.Items[k].Selected = true;
                        this.chkIndicadorCondicion.Items[k].Attributes.Add("Style", "color:red;");
                    }
                    this.chkIndicadorCondicion.Items[k].Enabled = false;
                }

                for (int k = 0; k < this.chkIndicadorComunidades.Items.Count; k++) {

                    if (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorComunidades.Items[k].Value).Length == 1) {
                        this.chkIndicadorComunidades.Items[k].Selected = true;
                        this.chkIndicadorComunidades.Items[k].Attributes.Add("Style", "color:red;");
                    }
                    this.chkIndicadorComunidades.Items[k].Enabled = false;
                }

                for (int k = 0; k < this.chkIndicadorVictimas.Items.Count; k++) {

                    if (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorVictimas.Items[k].Value).Length == 1) {
                        this.chkIndicadorVictimas.Items[k].Selected = true;
                        this.chkIndicadorVictimas.Items[k].Attributes.Add("Style", "color:red;");
                    }
                    this.chkIndicadorVictimas.Items[k].Enabled = false;
                }

                for (int k = 0; k < this.chkIndicadorTemas.Items.Count; k++) {

                    if (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorTemas.Items[k].Value).Length == 1) {
                        this.chkIndicadorTemas.Items[k].Selected = true;
                        this.chkIndicadorTemas.Items[k].Attributes.Add("Style", "color:red;");
                    }
                    this.chkIndicadorTemas.Items[k].Enabled = false;
                }

            }catch (Exception ex){
                throw (ex);
            }
        }
        void SelectProblematicaDetalle()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTQueja.ProblematicaDetalleId = 0;
                oENTQueja.ProblematicaId = Int32.Parse(this.ddlProblematica.SelectedItem.Value);
                oENTQueja.Nombre = "";

                // Transacción
                oENTResponse = oBPQueja.SelectProblematicaDetalle(oENTQueja);

                // Errores
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }

                // Warnings
                if (oENTResponse.sMessage != "") { ScriptManager.RegisterStartupScript(this.Page, this.GetType(), Convert.ToString(Guid.NewGuid()), "alert('" + oENTResponse.sMessage + "');", true); }

                // Llenado de control
                this.ddlProblematicaDetalle.DataTextField = "Nombre";
                this.ddlProblematicaDetalle.DataValueField = "ProblematicaDetalleId";
                this.ddlProblematicaDetalle.DataSource = oENTResponse.dsResponse.Tables[1];
                this.ddlProblematicaDetalle.DataBind();

                // Opción todos
                this.ddlProblematicaDetalle.Items.Insert(0, new ListItem("[Seleccione]", "0"));

            }catch (Exception ex){
                throw (ex);
            }
        }
        void UpdateSolicitud()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Validaciones
                if (this.ddlFormaContacto.SelectedItem.Value == "0") { throw (new Exception("Es necesario seleccionar una forma de contacto")); }
                if (this.ddlLugarHechos.SelectedItem.Value == "0") { throw (new Exception("Es necesario seleccionar un lugar de los hechos")); }
                if (this.ckeDireccionHechos.Text.Trim() == "") { throw (new Exception("Es necesario ingresar una dirección de los hechos")); }
                if (this.ckeObservaciones.Text.Trim() == "") { throw (new Exception("Es necesario ingresar observaciones")); }

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.FormaContactoId = Int32.Parse(this.ddlFormaContacto.SelectedItem.Value);
                oENTQueja.LugarHechosId = Int32.Parse(this.ddlLugarHechos.SelectedItem.Value);
                oENTQueja.DireccionHechos = this.ckeDireccionHechos.Text.Trim();
                oENTQueja.Observaciones = this.ckeObservaciones.Text.Trim();

                // Transacción
                oENTResponse = oBPQueja.UpdateSolicitud(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Transacción exitosa
                Response.Redirect("QueDetalleSolicitud.aspx?key=" + this.hddSolicitudId.Value + "|" + this.SenderId.Value, false);

            }catch (Exception ex){
                throw (ex);
            }
        }
        // Rutinas del programador
        void SelectSolicitud()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            ENTSession oSession = (ENTSession)Session["oENTSession"];

            try
            {

                // Formulario
                oENTQueja.UsuarioId = oSession.idUsuario;
                oENTQueja.Nivel = 2;

                // Transacción
                oENTResponse = oBPQueja.SelectSolicitud(oENTQueja);

                // Errores
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }

                // Warnings
                if (oENTResponse.sMessage != "") { ScriptManager.RegisterStartupScript(this.Page, this.GetType(), Convert.ToString(Guid.NewGuid()), "alert('" + oENTResponse.sMessage + "');", true); }

                // Llenado de control
                this.gvSolicitud.DataSource = oENTResponse.dsResponse.Tables[1];
                this.gvSolicitud.DataBind();

            }catch (Exception ex){
                throw (ex);
            }
        }
        void UpdateSolicitudBanderaDiligencia(Int16 Diligencias)
        {
            BPQueja oBPQueja = new BPQueja();
            ENTResponse oENTResponse = new ENTResponse();
            ENTQueja oENTQueja = new ENTQueja();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.Diligencias = Diligencias;

                //Transacción
                oENTResponse = oBPQueja.UpdateSolicitudCapturaDiligencia(oENTQueja);

                //Validación
                if (oENTResponse.GeneratesException) { throw new Exception(oENTResponse.sErrorMessage); }
                if (oENTResponse.sMessage != "") { throw new Exception(oENTResponse.sMessage); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 10
0
        void SelectSolicitud()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);

                // Transacción
                oENTResponse = oBPQueja.SelectSolicitud_Detalle(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Formulario
                this.SolicitudNumero.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["SolicitudNumero"].ToString();
                this.AfectadoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Afectado"].ToString();

                this.CalificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionNombre"].ToString();
                this.EstatusaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["EstatusNombre"].ToString();
                this.FuncionarioLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FuncionarioNombre"].ToString();
                this.TipoSolicitudLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoSolicitudNombre"].ToString();

                this.FechaRecepcionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaRecepcion"].ToString();
                this.FechaAsignacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaAsignacion"].ToString();
                this.FechaGestionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaInicioGestion"].ToString();
                this.FechaModificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaUltimaModificacion"].ToString();

                this.ddlFormaContacto.SelectedValue = oENTResponse.dsResponse.Tables[1].Rows[0]["FormaContactoId"].ToString();
                this.ddlLugarHechos.SelectedValue = oENTResponse.dsResponse.Tables[1].Rows[0]["LugarHechosId"].ToString();
                this.ckeDireccionHechos.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["DireccionHechos"].ToString();
                this.ckeObservaciones.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Observaciones"].ToString();

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 11
0
        void SelectSolicitud()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);

                // Transacción
                oENTResponse = oBPQueja.SelectSolicitud_Detalle(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Formulario
                this.SolicitudNumero.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["SolicitudNumero"].ToString();
                this.AfectadoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Afectado"].ToString();

                this.CalificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionNombre"].ToString();
                this.EstatusaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["EstatusNombre"].ToString();
                this.FuncionarioLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FuncionarioNombre"].ToString();
                this.ContactoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FormaContactoNombre"].ToString();
                this.TipoSolicitudLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoSolicitudNombre"].ToString();
                this.ProblematicaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaNombre"].ToString();
                this.ProblematicaDetalleLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaDetalleNombre"].ToString();

                this.FechaRecepcionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaRecepcion"].ToString();
                this.FechaAsignacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaAsignacion"].ToString();
                this.FechaGestionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaInicioGestion"].ToString();
                this.FechaModificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaUltimaModificacion"].ToString();
                this.NivelAutoridadLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["NivelAutoridadNombre"].ToString();
                this.MecanismoAperturaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["MecanismoAperturaNombre"].ToString();

                this.LugarHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["LugarHechosNombre"].ToString();
                this.DireccionHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["DireccionHechos"].ToString();
                this.ObservacionesLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Observaciones"].ToString();

                // Estatus de capturas de diligencias
                if (oENTResponse.dsResponse.Tables[1].Rows[0]["Diligencias"].ToString() == "1"){

                    // Habilitar controles
                    this.chkDiligencias.Checked = true;
                    this.btnNuevo.Enabled = true;
                    this.btnNuevo.CssClass = "Button_General";
                }else{

                    // Inhabilitar controles
                    this.chkDiligencias.Checked = false;
                    this.btnNuevo.Enabled = false;
                    this.btnNuevo.CssClass = "Button_General_Disabled";
                }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 12
0
        void SelectSolicitud()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);

                // Transacción
                oENTResponse = oBPQueja.SelectSolicitud_Cierre(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Campos ocultos
                this.hddCalificacionId.Value = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionId"].ToString();

                // Formulario
                this.SolicitudNumero.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["SolicitudNumero"].ToString();
                this.CalificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionNombre"].ToString();
                this.EstatusaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["EstatusNombre"].ToString();
                this.FuncionarioLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FuncionarioNombre"].ToString();
                this.ContactoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FormaContactoNombre"].ToString();
                this.TipoSolicitudLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoSolicitudNombre"].ToString();

                this.FechaRecepcionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaRecepcion"].ToString();
                this.FechaAsignacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaAsignacion"].ToString();
                this.FechaGestionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaInicioGestion"].ToString();
                this.FechaModificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaUltimaModificacion"].ToString();

                this.LugarHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["LugarHechosNombre"].ToString();
                this.DireccionHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["DireccionHechos"].ToString();
                this.ObservacionesLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Observaciones"].ToString();
                this.FundamentoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Fundamento"].ToString();

                // Llenado de Visitadurias en base al catálogo de Áreas y la calificación de la Solicitud
                switch (oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionId"].ToString()){
                    case "2": // Queja
                    case "4": // SI
                    case "8": // Medidas Cautelares

                        this.ddlVisitaduria.Items.Insert(0, new ListItem("Tercera Visitaduría", "6"));
                        this.ddlVisitaduria.Items.Insert(0, new ListItem("Segunda Visitaduría", "5"));
                        this.ddlVisitaduria.Items.Insert(0, new ListItem("Primera Visitaduría", "4"));
                        this.ddlVisitaduria.Items.Insert(0, new ListItem("[Seleccione]", "0"));
                        break;

                    case "7": // Solicitud de gestión

                        this.ddlVisitaduria.Items.Insert(0, new ListItem("Primera Visitaduría", "4"));
                        this.ddlVisitaduria.Items.Insert(0, new ListItem("Dirección de Orientación y Recepción de Quejas", "3"));
                        this.ddlVisitaduria.Items.Insert(0, new ListItem("Coordinación Penitenciaria", "10"));
                        this.ddlVisitaduria.Items.Insert(0, new ListItem("[Seleccione]", "0"));
                        break;

                    case "5": // Otra CEDH
                    case "6": // Comisión Nacional de los Derechos Humanos

                        this.ddlVisitaduria.Items.Insert(0, new ListItem("Primera Visitaduría", "4"));
                        this.ddlVisitaduria.Items.Insert(0, new ListItem("[Seleccione]", "0"));
                        break;

                    case "3": // Orientación
                    case "9": // Apoyo o colaboración

                        this.ddlVisitaduria.Items.Insert(0, new ListItem("", "0"));
                        this.ddlVisitaduria.Enabled = false;
                        break;

                    default: // No configurada

                        this.ddlVisitaduria.Enabled = false;
                        this.btnCrearFolio.Enabled = false;
                        this.btnCrearFolio.CssClass = "Button_General_Disabled";
                        break;
                }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 13
0
        void InsertExpediente()
        {
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();
            ENTSession oENTSession;

            BPQueja oBPQueja = new BPQueja();

            try
            {

                // Validaciones
                if (this.lblExpediente.Text.Trim() == "") { throw (new Exception("Es necesario generar el folio del expediente")); }

                // Obtener Sesion
                oENTSession = (ENTSession)this.Session["oENTSession"];

                // Formulario
                oENTQueja.UsuarioId = oENTSession.idUsuario;
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.AreaId = Int32.Parse(this.ddlVisitaduria.SelectedItem.Value);
                oENTQueja.CalificacionId = Int32.Parse(this.hddCalificacionId.Value);
                oENTQueja.NumeroFolio = this.lblExpediente.Text.Trim();

                // Transacción
                oENTResponse = oBPQueja.InsertExpediente(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 14
0
        void DeleteSolicitudCiudadano(Int32 CiudadanoId)
        {
            BPQueja oBPQueja = new BPQueja();

            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();
            ENTSession SessionEntity = new ENTSession();

            try
            {

                // Obtener la sesión
                SessionEntity = (ENTSession)Session["oENTSession"];

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.FuncionarioId = SessionEntity.FuncionarioId;
                oENTQueja.CiudadanoId = CiudadanoId;

                // Transacción
                oENTResponse = oBPQueja.DeleteSolicitudCiudadano(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { ScriptManager.RegisterStartupScript(this.Page, this.GetType(), Convert.ToString(Guid.NewGuid()), "alert('" + oENTResponse.sMessage + "');", true); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 15
0
        // Rutinas del programador
        void EnviarSolicitud()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTResponse oENTResponse = new ENTResponse();
            ENTQueja oENTQueja = new ENTQueja();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.EstatusId = 4; // Pendiente de aprobar Queja

                //Transacción
                oENTResponse = oBPQueja.UpdateSolicitudEstatus(oENTQueja);

                //Validación
                if (oENTResponse.GeneratesException) { throw new Exception(oENTResponse.sErrorMessage); }
                if (oENTResponse.sMessage != "") { throw new Exception(oENTResponse.sMessage); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 16
0
        void InsertSolicitudCiudadano()
        {
            BPQueja oBPQueja = new BPQueja();

            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();
            ENTSession SessionEntity = new ENTSession();

            String CiudadanoId;
            String CiudadanoNombre;

            try
            {

                // Obtener información del ciudadano del Autosuggest
                CiudadanoId = this.Request.Form[this.hddCiudadanoId.UniqueID];
                CiudadanoNombre = this.Request.Form[this.txtCiudadano.UniqueID];

                // Normalización
                if (CiudadanoId == "") { CiudadanoId = "0"; }
                CiudadanoNombre = CiudadanoNombre.Trim();

                // Validaciones
                if (CiudadanoNombre == "" ) { throw new Exception("El campo [Nombre del ciudadano] es requerido"); }
                if (this.ddlTipoParticipacion.SelectedItem.Value == "0") { throw new Exception("El campo [Tipo de Participación] es requerido"); }

                // Obtener la sesión
                SessionEntity = (ENTSession)Session["oENTSession"];

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.UsuarioId = SessionEntity.idUsuario;
                oENTQueja.CiudadanoId = Int32.Parse(CiudadanoId);
                oENTQueja.TipoParticipacionId = Int32.Parse(this.ddlTipoParticipacion.SelectedItem.Value);
                oENTQueja.Check = 1; // Validar el Nombre del control con el Id debido al Bug del Autosuggest
                oENTQueja.CheckNombre = CiudadanoNombre;
                oENTQueja.Presente = Int16.Parse((this.rblPresente.Items[0].Selected ? 1 : 0).ToString());

                // Transacción
                oENTResponse = oBPQueja.InsertSolicitudCiudadano(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { ScriptManager.RegisterStartupScript(this.Page, this.GetType(), Convert.ToString(Guid.NewGuid()), "alert('" + oENTResponse.sMessage + "');", true); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 17
0
        void SelectSolicitud()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);

                // Transacción
                oENTResponse = oBPQueja.SelectSolicitud_Detalle(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Formulario
                this.SolicitudNumero.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["SolicitudNumero"].ToString();
                this.AfectadoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Afectado"].ToString();

                this.CalificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionNombre"].ToString();
                this.EstatusaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["EstatusNombre"].ToString();
                this.FuncionarioLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FuncionarioNombre"].ToString();
                this.ContactoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FormaContactoNombre"].ToString();
                this.TipoSolicitudLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoSolicitudNombre"].ToString();
                this.ProblematicaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaNombre"].ToString();
                this.ProblematicaDetalleLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaDetalleNombre"].ToString();

                this.FechaRecepcionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaRecepcion"].ToString();
                this.FechaAsignacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaAsignacion"].ToString();
                this.FechaGestionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaInicioGestion"].ToString();
                this.FechaModificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaUltimaModificacion"].ToString();
                this.NivelAutoridadLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["NivelAutoridadNombre"].ToString();
                this.MecanismoAperturaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["MecanismoAperturaNombre"].ToString();

                this.LugarHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["LugarHechosNombre"].ToString();
                this.DireccionHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["DireccionHechos"].ToString();
                this.ObservacionesLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Observaciones"].ToString();

                // Seleccionar indicadores
                for (int k = 0; k < this.chkIndicadorGenero.Items.Count; k++) {
                    this.chkIndicadorGenero.Items[k].Selected = (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorGenero.Items[k].Value).Length == 0 ? false : true);
                }

                for (int k = 0; k < this.chkIndicadorEdad.Items.Count; k++) {
                    this.chkIndicadorEdad.Items[k].Selected = (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorEdad.Items[k].Value).Length == 0 ? false : true);
                }

                for (int k = 0; k < this.chkIndicadorActividad.Items.Count; k++) {
                    this.chkIndicadorActividad.Items[k].Selected = (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorActividad.Items[k].Value).Length == 0 ? false : true);
                }

                for (int k = 0; k < this.chkIndicadorCondicion.Items.Count; k++) {
                    this.chkIndicadorCondicion.Items[k].Selected = (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorCondicion.Items[k].Value).Length == 0 ? false : true);
                }

                for (int k = 0; k < this.chkIndicadorComunidades.Items.Count; k++) {
                    this.chkIndicadorComunidades.Items[k].Selected = (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorComunidades.Items[k].Value).Length == 0 ? false : true);
                }

                for (int k = 0; k < this.chkIndicadorVictimas.Items.Count; k++) {
                    this.chkIndicadorVictimas.Items[k].Selected = (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorVictimas.Items[k].Value).Length == 0 ? false : true);
                }

                for (int k = 0; k < this.chkIndicadorTemas.Items.Count; k++) {
                    this.chkIndicadorTemas.Items[k].Selected = (oENTResponse.dsResponse.Tables[6].Select("IndicadorId=" + this.chkIndicadorTemas.Items[k].Value).Length == 0 ? false : true);
                }

            }catch (Exception ex){
                throw (ex);
            }
        }
        // Rutinas el programador
        void RechazarCalificacion()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTResponse oENTResponse = new ENTResponse();
            ENTQueja oENTQueja = new ENTQueja();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.EstatusId = 3; // En proceso de Queja

                //Transacción
                oENTResponse = oBPQueja.UpdateSolicitudEstatus(oENTQueja);

                //Validación
                if (oENTResponse.GeneratesException) { throw new Exception(oENTResponse.sErrorMessage); }
                if (oENTResponse.sMessage != "") { throw new Exception(oENTResponse.sMessage); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 19
0
        // Rutinas el programador
        void InsertSolicitudIndicador()
        {
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            BPQueja oBPQueja = new BPQueja();
            DataRow rowIndicador;

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);

                // Indicadores seleccionados
                oENTQueja.tblIndicador = new DataTable("tblIndicador");
                oENTQueja.tblIndicador.Columns.Add("IndicadorId", typeof(Int32));

                // Listado de Indicadores
                for (int k = 0; k < this.chkIndicadorGenero.Items.Count; k++) {

                    if(this.chkIndicadorGenero.Items[k].Selected){

                        rowIndicador = oENTQueja.tblIndicador.NewRow();
                        rowIndicador["IndicadorId"] = this.chkIndicadorGenero.Items[k].Value;
                        oENTQueja.tblIndicador.Rows.Add(rowIndicador);
                    }
                }

                for (int k = 0; k < this.chkIndicadorEdad.Items.Count; k++) {

                    if(this.chkIndicadorEdad.Items[k].Selected){

                        rowIndicador = oENTQueja.tblIndicador.NewRow();
                        rowIndicador["IndicadorId"] = this.chkIndicadorEdad.Items[k].Value;
                        oENTQueja.tblIndicador.Rows.Add(rowIndicador);
                    }
                }

                for (int k = 0; k < this.chkIndicadorActividad.Items.Count; k++) {

                    if(this.chkIndicadorActividad.Items[k].Selected){

                        rowIndicador = oENTQueja.tblIndicador.NewRow();
                        rowIndicador["IndicadorId"] = this.chkIndicadorActividad.Items[k].Value;
                        oENTQueja.tblIndicador.Rows.Add(rowIndicador);
                    }
                }

                for (int k = 0; k < this.chkIndicadorCondicion.Items.Count; k++) {

                    if(this.chkIndicadorCondicion.Items[k].Selected){

                        rowIndicador = oENTQueja.tblIndicador.NewRow();
                        rowIndicador["IndicadorId"] = this.chkIndicadorCondicion.Items[k].Value;
                        oENTQueja.tblIndicador.Rows.Add(rowIndicador);
                    }
                }

                for (int k = 0; k < this.chkIndicadorComunidades.Items.Count; k++) {

                    if(this.chkIndicadorComunidades.Items[k].Selected){

                        rowIndicador = oENTQueja.tblIndicador.NewRow();
                        rowIndicador["IndicadorId"] = this.chkIndicadorComunidades.Items[k].Value;
                        oENTQueja.tblIndicador.Rows.Add(rowIndicador);
                    }
                }

                for (int k = 0; k < this.chkIndicadorVictimas.Items.Count; k++) {

                    if(this.chkIndicadorVictimas.Items[k].Selected){

                        rowIndicador = oENTQueja.tblIndicador.NewRow();
                        rowIndicador["IndicadorId"] = this.chkIndicadorVictimas.Items[k].Value;
                        oENTQueja.tblIndicador.Rows.Add(rowIndicador);
                    }
                }

                for (int k = 0; k < this.chkIndicadorTemas.Items.Count; k++) {

                    if(this.chkIndicadorTemas.Items[k].Selected){

                        rowIndicador = oENTQueja.tblIndicador.NewRow();
                        rowIndicador["IndicadorId"] = this.chkIndicadorTemas.Items[k].Value;
                        oENTQueja.tblIndicador.Rows.Add(rowIndicador);
                    }
                }

                // Transacción
                oENTResponse = oBPQueja.InsertSolicitudIndicador(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 20
0
        // Funciones el programador
        void InsertSolicitudFuncionario()
        {
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            BPQueja oBPQueja = new BPQueja();

            try
            {

                // Validaciones
                if (this.ddlFuncionario.SelectedItem.Value == "0") { throw (new Exception("Es necesario seleccionar un Funcionario")); }

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.FuncionarioId = Int32.Parse(this.ddlFuncionario.SelectedItem.Value);

                // Transacción
                oENTResponse = oBPQueja.InsertSolicitudFuncionario(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 21
0
        void DeleteSolicitudComentario(Int32 ComentarioId)
        {
            BPQueja oBPQueja = new BPQueja();

            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.ComentarioId = ComentarioId;

                // Transacción
                oENTResponse = oBPQueja.DeleteSolicitudComentario(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 22
0
        void SelectSolicitud()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);

                // Transacción
                oENTResponse = oBPQueja.SelectSolicitud_Detalle(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Formulario
                this.SolicitudNumero.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["SolicitudNumero"].ToString();
                this.AfectadoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Afectado"].ToString();

                this.CalificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionNombre"].ToString();
                this.EstatusaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["EstatusNombre"].ToString();
                this.FuncionarioLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FuncionarioNombre"].ToString();
                this.ContactoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FormaContactoNombre"].ToString();
                this.TipoSolicitudLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoSolicitudNombre"].ToString();

                this.FechaRecepcionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaRecepcion"].ToString();
                this.FechaAsignacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaAsignacion"].ToString();
                this.FechaGestionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaInicioGestion"].ToString();
                this.FechaModificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaUltimaModificacion"].ToString();

                this.LugarHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["LugarHechosNombre"].ToString();
                this.DireccionHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["DireccionHechos"].ToString();
                this.ObservacionesLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Observaciones"].ToString();

                // Datos de calificación
                this.ddlProblematica.SelectedValue = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaId"].ToString();
                SelectProblematicaDetalle();

                this.ddlProblematicaDetalle.SelectedValue = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaDetalleId"].ToString();
                this.ddlMecanismoApertura.SelectedValue = oENTResponse.dsResponse.Tables[1].Rows[0]["MecanismoAperturaId"].ToString();
                this.ddlNivelAutoridad.SelectedValue = oENTResponse.dsResponse.Tables[1].Rows[0]["NivelAutoridadId"].ToString();
                this.ddlCalificacion.SelectedValue = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionId"].ToString();

                this.chkMedioComunicacion.Checked = ( oENTResponse.dsResponse.Tables[1].Rows[0]["MediosDeComunicacion"].ToString() == "1" ? true : false);
                this.chkMedioComunicacion.Enabled = (oENTResponse.dsResponse.Tables[1].Rows[0]["MecanismoAperturaId"].ToString() == "2" ? true : false);

                if (oENTResponse.dsResponse.Tables[1].Rows[0]["TipoOrientacionId"].ToString() != "0") {

                    this.ddlTipoOrientacion.Enabled = true;
                    this.ddlTipoOrientacion.SelectedValue = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoOrientacionId"].ToString();
                }

                if (oENTResponse.dsResponse.Tables[7].Rows.Count  > 0) {

                    this.ddlCanalizacion.Enabled = true;

                    this.btnAgregarCanalizacion.Enabled = true;
                    this.btnAgregarCanalizacion.CssClass = "Button_General";

                    this.grdCanalizacion.DataSource = oENTResponse.dsResponse.Tables[7];
                    this.grdCanalizacion.DataBind();
                }

                this.ckeFundamento.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Fundamento"].ToString();

                // Script de Validación de cambio de estatus (Antes Queja)
                if (oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionId"].ToString() == "2"){
                    this.btnGuardar.Attributes.Add("onclick", " if ( document.getElementById('" + ddlCalificacion.ClientID + "').options[document.getElementById('" + ddlCalificacion.ClientID + "').selectedIndex].value != 2 ) { return confirm('Al cambiar la calificación se eliminarán todas las capturas de Voces realizadas en la solicitud, ¿Seguro que desea continuar?'); }");
                }

                //// Script de Validación de cambio de estatus (Antes Medidas Cautelares)
                //if (oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionId"].ToString() == "8"){
                //    this.btnGuardar.Attributes.Add("onclick", " if ( document.getElementById('" + ddlCalificacion.ClientID + "').options[document.getElementById('" + ddlCalificacion.ClientID + "').selectedIndex].value != 2 ) { return confirm('Al cambiar la calificación se eliminarán todas las capturas de Autoridades realizadas en la solicitud, ¿Seguro que desea continuar?'); }");
                //}

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 23
0
        void InsertSolicitudComentario()
        {
            BPQueja oBPQueja = new BPQueja();

            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();
            ENTSession SessionEntity = new ENTSession();

            try
            {

                // Validaciones
                if (this.ckeComentario.Text.Trim() == "") { throw (new Exception("Es necesario ingresar un comentario")); }

                // Obtener sesión
                SessionEntity = (ENTSession)Session["oENTSession"];

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);
                oENTQueja.UsuarioId = SessionEntity.idUsuario;
                oENTQueja.Comentario = this.ckeComentario.Text.Trim();
                oENTQueja.MedidaPreventiva = Int16.Parse((this.chkMedidaPreventiva.Checked ? 1 : 0).ToString());

                // Transacción
                oENTResponse = oBPQueja.InsertSolicitudComentario(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 24
0
        void SelectSolicitud()
        {
            BPQueja oBPQueja = new BPQueja();
            ENTQueja oENTQueja = new ENTQueja();
            ENTResponse oENTResponse = new ENTResponse();

            try
            {

                // Formulario
                oENTQueja.SolicitudId = Int32.Parse(this.hddSolicitudId.Value);

                // Transacción
                oENTResponse = oBPQueja.SelectSolicitud_Detalle(oENTQueja);

                // Errores y Warnings
                if (oENTResponse.GeneratesException) { throw (new Exception(oENTResponse.sErrorMessage)); }
                if (oENTResponse.sMessage != "") { throw (new Exception(oENTResponse.sMessage)); }

                // Formulario
                this.SolicitudNumero.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["SolicitudNumero"].ToString();
                this.AfectadoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Afectado"].ToString();

                this.CalificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["CalificacionNombre"].ToString();
                this.EstatusaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["EstatusNombre"].ToString();
                this.FuncionarioLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FuncionarioNombre"].ToString();
                this.ContactoLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FormaContactoNombre"].ToString();
                this.TipoSolicitudLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["TipoSolicitudNombre"].ToString();
                this.ProblematicaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaNombre"].ToString();
                this.ProblematicaDetalleLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["ProblematicaDetalleNombre"].ToString();

                this.FechaRecepcionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaRecepcion"].ToString();
                this.FechaAsignacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaAsignacion"].ToString();
                this.FechaGestionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaInicioGestion"].ToString();
                this.FechaModificacionLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["FechaUltimaModificacion"].ToString();
                this.NivelAutoridadLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["NivelAutoridadNombre"].ToString();
                this.MecanismoAperturaLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["MecanismoAperturaNombre"].ToString();

                this.LugarHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["LugarHechosNombre"].ToString();
                this.DireccionHechosLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["DireccionHechos"].ToString();
                this.ObservacionesLabel.Text = oENTResponse.dsResponse.Tables[1].Rows[0]["Observaciones"].ToString();

                // Documentos
                this.gvDocumento.DataSource = oENTResponse.dsResponse.Tables[3];
                this.gvDocumento.DataBind();

            }catch (Exception ex){
                throw (ex);
            }
        }
Esempio n. 25
0
        public void PresentaReporte(string TipoReporte, DateTime FechaInicial, DateTime FechaFinal, int AreaId)
        {
            ENTResponse oResponse = new ENTResponse();
            System.Data.DataSet ds = new System.Data.DataSet();

            try
            {
                switch (TipoReporte)
                {
                    case "rptVisitaduriaGeneralpage":

                        // Declara Entidad y Buiseness
                        ENTVisitaduria entGVis = new ENTVisitaduria();
                        BPVisitaduria bssGVis = new BPVisitaduria();

                        // Asigna valores
                        entGVis.FechaDesde = FechaInicial.ToString("yyyy-MM-dd");
                        entGVis.FechaHasta = FechaFinal.ToString("yyyy-MM-dd");
                        entGVis.AreaId = AreaId;

                        //// Consulta reporte
                        oResponse = bssGVis.RptGeneralVisitaduria(entGVis);

                        oResponse.dsResponse.Tables[0].TableName = "tblExpPeriodo_I";
                        oResponse.dsResponse.Tables[1].TableName = "tblExpMedidaCautelar_II";
                        oResponse.dsResponse.Tables[2].TableName = "tblExpSolicitudGestion_III";
                        oResponse.dsResponse.Tables[3].TableName = "tblExpVisitaduriaGeneral_IV";
                        oResponse.dsResponse.Tables[4].TableName = "tblExpConcluidos_V";
                        oResponse.dsResponse.Tables[5].TableName = "tblExpNivelAutoridadVI";
                        oResponse.dsResponse.Tables[6].TableName = "tblPersonasAtendidasVII";
                        oResponse.dsResponse.Tables[7].TableName = "tblEntrevistas_VIII";
                        oResponse.dsResponse.Tables[8].TableName = "tblSupervisores_IX";
                        oResponse.dsResponse.Tables[9].TableName = "tblResultados_X";
                        oResponse.dsResponse.Tables[10].TableName = "tblDatosGenerales";

                        rptVisGeneral rptVisitaduriaGeneral = new rptVisGeneral();
                        rptVisitaduriaGeneral.SetDataSource(oResponse.dsResponse);
                        //// Presenta reporte
                        crViewer.ReportSource = rptVisitaduriaGeneral;
                        break;

                    case "rptEstadisticaPresidencia":
                        // Declara Entidad y Buiseness
                        ENTQueja entEstadisticaPresindecia = new ENTQueja();
                        BPQueja bssEstadisticaPresindecia = new BPQueja();

                        // Asigna valores
                        entEstadisticaPresindecia.FechaDesde = FechaInicial.ToString("yyyy-MM-dd");
                        entEstadisticaPresindecia.FechaHasta = FechaFinal.ToString("yyyy-MM-dd");

                        // Consulta reporte
                        oResponse = bssEstadisticaPresindecia.RptEstadisticaPresidencia(entEstadisticaPresindecia);

                        oResponse.dsResponse.Tables[0].TableName = "tblEncabezado_0";
                        oResponse.dsResponse.Tables[1].TableName = "tblEncabezado_I";
                        oResponse.dsResponse.Tables[2].TableName = "tblIntervenciones_II";
                        oResponse.dsResponse.Tables[3].TableName = "tblAsignacionExpediente_III";
                        oResponse.dsResponse.Tables[4].TableName = "tblMecanismoApertura_IV";
                        oResponse.dsResponse.Tables[5].TableName = "tblAsignaionExpQuejas_V";
                        oResponse.dsResponse.Tables[6].TableName = "tblAsignacionExpCautelares_VI";
                        oResponse.dsResponse.Tables[7].TableName = "tblAsignacionExpGestion_VII";
                        oResponse.dsResponse.Tables[8].TableName = "tblQuejasVulnerabilidad_VIII";
                        oResponse.dsResponse.Tables[9].TableName = "tblListadoExpGeneral_IX";
                        oResponse.dsResponse.Tables[10].TableName = "tblListadoCautelares_X";
                        oResponse.dsResponse.Tables[11].TableName = "tblSolicitudesGestion_XI";
                        oResponse.dsResponse.Tables[12].TableName = "tblExpQuejaAutoridad_XII";
                        oResponse.dsResponse.Tables[13].TableName = "tblDiligenciasYEntrevistas_XIII";
                        oResponse.dsResponse.Tables[14].TableName = "tblGrupoPersonasRelacionadas_XIV";
                        oResponse.dsResponse.Tables[15].TableName = "tblOrigenPersonasRelacionadas_XV";
                        oResponse.dsResponse.Tables[16].TableName = "tblDatosGenerales";

                        rptEstadisticaPresidencia rptCREstadisticaPresidencia = new rptEstadisticaPresidencia();
                        rptCREstadisticaPresidencia.SetDataSource(oResponse.dsResponse);
                        crViewer.ReportSource = rptCREstadisticaPresidencia;
                        break;

                    case "rptIntegralVictimas":
                        // Declara Entidad y Buiseness
                        ENTAtencion entIntegralVictimas = new ENTAtencion();
                        BPAtencion bssIntegralVictimas = new BPAtencion();

                        // Asigna valores
                        entIntegralVictimas.FechaDesde = FechaInicial.ToString("yyyy-MM-dd");
                        entIntegralVictimas.FechaHasta = FechaFinal.ToString("yyyy-MM-dd");

                        // Consulta reporte
                        oResponse = bssIntegralVictimas.RptIntegralVictimas(entIntegralVictimas);

                        oResponse.dsResponse.Tables[0].TableName = "tblDMFPrevioLesiones_I";
                        oResponse.dsResponse.Tables[1].TableName = "tblDMFPrevioLesionesPorGenero_II";
                        oResponse.dsResponse.Tables[2].TableName = "tblDMFPrevioLesionesEstatus_III";
                        oResponse.dsResponse.Tables[3].TableName = "tblDictamenPsicologico_163_IV";
                        oResponse.dsResponse.Tables[4].TableName = "tblDictamenPsicologico_163_PorGenero_V";
                        oResponse.dsResponse.Tables[5].TableName = "tblOpinionMedica_VI";
                        oResponse.dsResponse.Tables[6].TableName = "tblDesgloseDictamen_VII";
                        oResponse.dsResponse.Tables[7].TableName = "tblAcompanamientoEmocional_VIII";
                        oResponse.dsResponse.Tables[7].TableName = "tblClimaLaboral_IX";
                        oResponse.dsResponse.Tables[9].TableName = "tblDatosGenerales";

                        //rptEstadisticaPresidencia rptCR = new rptEstadisticaPresidencia();
                        rptIntegralVictimas rptCRIntegralVictimas = new rptIntegralVictimas();
                        rptCRIntegralVictimas.SetDataSource(oResponse.dsResponse);
                        crViewer.ReportSource = rptCRIntegralVictimas;
                        break;
                }
            }
            catch
            { }
            finally
            { }
        }