void procesarPagoRecibos() { using (SqlConnection conn = new SqlConnection(ConfigurationManager.ConnectionStrings["connDB"].ConnectionString)) { try { SqlCommand cmd = new SqlCommand(); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.Add("@JSONRecibos", SqlDbType.VarChar).Value = JSONRecibos; cmd.CommandText = "SPPagarRecibos"; cmd.Connection = conn; conn.Open(); GridViewRecibosPagos.DataSource = cmd.ExecuteReader(); GridViewRecibosPagos.DataBind(); ccConversor(1, 1); } catch (SqlException ex) { ShowMessage(ex.Errors[0].Message); ccConversor(1, 1); } } botonVolver1.Visible = true; botonVolver1.Text = "Volver al Menu Principal"; GridViewRecibosPendientes.Visible = false; GridViewRecibosPendientes2.Visible = false; labelTitulo.Visible = true; ButtonCancelar.Visible = false; ButtonPagar.Visible = false; labelTitulo.InnerText = "Pago Realizado con éxito."; //Monto Total: +calcularTotalPagado(); }
public void verRecibosDeComprobante() { using (SqlConnection conn = new SqlConnection(ConfigurationManager.ConnectionStrings["connDB"].ConnectionString)) { SqlCommand cmd = new SqlCommand(); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.Add("@InId", SqlDbType.Int).Value = Int64.Parse(labelAux); cmd.CommandText = "SPSRecibosDeComprobantePago"; cmd.Connection = conn; conn.Open(); GridViewRecibosPagos.DataSource = cmd.ExecuteReader(); GridViewRecibosPagos.DataBind(); labelTitulo.InnerText = "Recibos"; labelTitulo.Visible = true; } }
public void verRecibosPagos() { using (SqlConnection conn = new SqlConnection(ConfigurationManager.ConnectionStrings["connDB"].ConnectionString)) { try { SqlCommand cmd = new SqlCommand(); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.Add("@InNumFinca", SqlDbType.VarChar).Value = labelID; cmd.CommandText = "SPSReciboPagos"; cmd.Connection = conn; conn.Open(); GridViewRecibosPagos.DataSource = cmd.ExecuteReader(); GridViewRecibosPagos.DataBind(); botonVolver1.Visible = true; ButtonArregloPago.Visible = false; panelCC.Visible = true; } catch (SqlException ex) { ShowMessage(ex.Errors[0].Message); } } }