private void CargaDatos()
        {
            try
            {
                GestionPagadoraBE IEntity = new GestionPagadoraBE();
                IEntity.OPCION     = 1;
                IEntity.IdPagadora = Codigo;
                DataSet ds = new GestionPagadoraBL().ProcesarGestionPagadora(IEntity);

                if (ds.Tables[0].Rows.Count > 0)
                {
                    txtvcRuc.Text                = ds.Tables[0].Rows[0]["vcRuc"].ToString();
                    txtvcPagadora.Text           = ds.Tables[0].Rows[0]["vcPagadora"].ToString();
                    txtvTipoEmpresa.Text         = ds.Tables[0].Rows[0]["vTipoEmpresa"].ToString();
                    txtvPagWeb.Text              = ds.Tables[0].Rows[0]["vPagWeb"].ToString();
                    txtIdSector_tt_Dsc.Text      = ds.Tables[0].Rows[0]["IdSector_tt_Dsc"].ToString();
                    txtPorcjSector.Text          = ds.Tables[0].Rows[0]["PorcjSector"].ToString();
                    txtPorcjCartera.Text         = ds.Tables[0].Rows[0]["PorcjCartera"].ToString();
                    txtvFacebook.Text            = ds.Tables[0].Rows[0]["vFacebook"].ToString();
                    txtvTwitter.Text             = ds.Tables[0].Rows[0]["vTwitter"].ToString();
                    txtnLinea.Text               = Convert.ToDecimal(ds.Tables[0].Rows[0]["nLinea"].ToString()).ToString("N2");
                    txtnSaldo.Text               = Convert.ToDecimal(ds.Tables[0].Rows[0]["nSaldo"].ToString()).ToString("N2");
                    txtnUtilizado.Text           = Convert.ToDecimal(ds.Tables[0].Rows[0]["nUtilizado"].ToString()).ToString("N2");
                    txtPorcjUso.Text             = Convert.ToDecimal(ds.Tables[0].Rows[0]["PorcjUso"].ToString()).ToString("N");
                    txtUltActivacion.Text        = ds.Tables[0].Rows[0]["UltActivacion"].ToString();
                    txtIdEstadoLinea_tt_Dsc.Text = ds.Tables[0].Rows[0]["IdEstadoLinea_tt_Dsc"].ToString();
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
Exemple #2
0
        private void btnAceptar_Click(object sender, EventArgs e)
        {
            try
            {
                int Count = 0;
                if (dgvSocios.RowCount > 0)
                {
                    foreach (DataGridViewRow row in dgvSocios.Rows)
                    {
                        DataGridViewCheckBoxCell chk = (DataGridViewCheckBoxCell)row.Cells["ChkSel"];
                        if (Convert.ToBoolean(chk.Value))
                        {
                            GestionPagadoraBE IEntity = new GestionPagadoraBE()
                            {
                                OPCION  = 7,
                                USUARIO = General.General.GetUsuario,
                                IdSocio = row.Cells["IdSocio"].Value.ToString(),
                            };
                            new GestionPagadoraBL().ProcesarGestionPagadora(IEntity);
                            Count++;
                        }
                    }

                    if (Count > 0)
                    {
                        MessageBox.Show("Se Proceso Correctamente", "Mensaje", MessageBoxButtons.OK, MessageBoxIcon.Information);
                        Dispose();
                    }
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
        private void CargarDatos()
        {
            try
            {
                GestionPagadoraBE IEntity = new GestionPagadoraBE();
                IEntity.OPCION     = 5;
                IEntity.IdPagadora = Codigo;
                DataSet ds = new GestionPagadoraBL().ProcesarGestionPagadora(IEntity);

                dgvSectores.DataSource = ds.Tables[0];
                ChartPie.Series[0].Points.Clear();
                ChartPie.Series[0].ChartType = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.Pie;
                ChartPie.Titles.Add("Uso de Líneas por Sector").Font = new System.Drawing.Font("Arial", 16, FontStyle.Bold);
                ChartPie.ChartAreas[0].BackColor = Color.Transparent;
                ChartPie.ChartAreas[0].AxisX.LabelStyle.Enabled = true;
                ChartPie.Series[0]["PieLabelStyle"]             = "Disabled"; //Deshabilitar los labels

                foreach (DataRow dr in ds.Tables[0].Rows)
                {
                    DataPoint point = new DataPoint();
                    point.SetValueXY(dr["IdSector_tt_Dsc"].ToString(), decimal.Parse(dr["Saldo"].ToString()));
                    point.ToolTip = string.Format("{0} : {1}%", dr["IdSector_tt_Dsc"].ToString(), decimal.Parse(dr["Porj"].ToString()).ToString("N2"));
                    ChartPie.Series[0].Points.Add(point);
                    //ChartPie.Series[0].Points.AddXY(dr["IdSector_tt_Dsc"].ToString(), decimal.Parse(dr["Saldo"].ToString()));
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
Exemple #4
0
        private void btnInfFinanciera_Click(object sender, EventArgs e)
        {
            DialogResult dialogResult = 0;

            try
            {
                dialogResult = MessageBox.Show("Seguro de solicitar información financiera?", "Confirme", MessageBoxButtons.YesNo, MessageBoxIcon.Question);

                if (dialogResult == DialogResult.Yes)
                {
                    GestionPagadoraBE IEntity = new GestionPagadoraBE();
                    IEntity.OPCION     = 8;
                    IEntity.IdPagadora = oIdPagadora;
                    IEntity.FlgOrigen  = _FlgOrigen;
                    DataSet ds = new GestionPagadoraBL().ProcesarGestionPagadora(IEntity);
                    MessageBox.Show("Se Envió Correctamente", "Mensaje", MessageBoxButtons.OK, MessageBoxIcon.Information);

                    //    CompromisoComBE CompromisoComBE = new CompromisoComBE()
                    //    {
                    //        OPCION = 3,
                    //        USUARIO = General.General.GetUsuario,
                    //        IdCompromiso = dgvCompromisoCom.CurrentRow.Cells["IdCompromiso"].Value.ToString(),
                    //    };

                    //    CompromisoComBL.ProcesarCompromisoCom(CompromisoComBE);
                    //    MessageBox.Show("Se Proceso Correctamente", "Mensaje", MessageBoxButtons.OK, MessageBoxIcon.Information);
                    //    btnBuscar.PerformClick();
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
Exemple #5
0
 private void CargarDatos()
 {
     try
     {
         GestionPagadoraBE oEntity = new GestionPagadoraBE();
         oEntity.OPCION     = 6;
         oEntity.IdPagadora = Codigo;
         DataSet ds = new DataSet();
         ds = new GestionPagadoraBL().ProcesarGestionPagadora(oEntity);
         dgvSocios.DataSource = ds.Tables[0];
         lblRegistros.Text    = ds.Tables[0].Rows.Count + " registro(s)";
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
Exemple #6
0
 private void btnBuscar_Click(object sender, EventArgs e)
 {
     try
     {
         GestionPagadoraBE oEntity = new GestionPagadoraBE();
         oEntity.OPCION           = 2;
         oEntity.IdGestor         = cboEjecutivo.SelectedValue.ToString();
         oEntity.vcPagadora       = txtvcPagadora.Text.Trim();
         oEntity.IdEstadoLinea_tt = cboIdEstadoLinea_tt.SelectedValue.ToString();
         DataSet ds = new DataSet();
         ds = new GestionPagadoraBL().ProcesarGestionPagadora(oEntity);
         dgvGestionPagadora.DataSource = ds.Tables[0];
         lblRegistros.Text             = ds.Tables[0].Rows.Count + " registro(s)";
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
        private void CargarPndCobro()
        {
            try
            {
                GestionPagadoraBE IEntity = new GestionPagadoraBE();
                IEntity.OPCION     = 3;
                IEntity.IdPagadora = Codigo;
                DataSet ds = new GestionPagadoraBL().ProcesarGestionPagadora(IEntity);

                if (ds.Tables[0].Rows.Count > 0)
                {
                    dgvPendienteCobro.DataSource = ds.Tables[0];
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
 public DataSet ProcesarGestionPagadora(GestionPagadoraBE BE)
 {
     DataSet dsResult;
     try
     {
         cmd = db.GetStoredProcCommand("dbo.GestionPagadora");
         cmd.CommandTimeout = 0;
         db.AddInParameter(cmd, "OPCION", DbType.Int32, BE.OPCION);
         db.AddInParameter(cmd, "IdPagadora", DbType.String, BE.IdPagadora);
         db.AddInParameter(cmd, "IdSocio", DbType.String, BE.IdSocio);
         db.AddInParameter(cmd, "vcPagadora", DbType.String, BE.vcPagadora);
         db.AddInParameter(cmd, "IdGestor", DbType.String, BE.IdGestor);
         db.AddInParameter(cmd, "TipCam", DbType.Decimal, BE.TipCam);
         db.AddInParameter(cmd, "IdEstadoLinea_tt", DbType.String, BE.IdEstadoLinea_tt);
         db.AddInParameter(cmd, "FlgOrigen", DbType.Int32, BE.FlgOrigen); 
         dsResult = db.ExecuteDataSet(cmd);
     }
     catch (Exception ex)
     {
         throw new Exception(ex.Message);
     }
     return dsResult;
 }
 public DataSet ProcesarGestionPagadora(GestionPagadoraBE BE)
 {
     return(GestionPagadoraDA.ProcesarGestionPagadora(BE));
 }