Esempio n. 1
0
        private void loadInformeDiarioGanan(object sender, EventArgs e)
        {
            helpers ayudante = new helpers();
            string  sql      = @"SELECT idFactura, importeTotal, ROUND(importeTotal * 0.21, 2) as idEmpleado, 
            ROUND(importeTotal * 0.79, 2) as tipoPago FROM ventas WHERE CONVERT(DATE, fechaHora) = '" + ayudante.insertarFechaConFormato(DateTime.Now.ToString("dd/MM/yyyy")) + "';";

            ayudante.cargarReporte(sql, "DataSet1", informeDiarioGanan);
        }
Esempio n. 2
0
 private void onBtnBuscarClick(object sender, EventArgs e)
 {
     this.buscarVentas(cmbNomApe.GetItemText(cmbNomApe.SelectedItem), ayudante.insertarFechaConFormato(maskFechaDesde.Text), ayudante.insertarFechaConFormato(maskFechaHasta.Text), cmbTipoPago.SelectedIndex + 1);
 }
Esempio n. 3
0
        private void consultar(object sender, EventArgs e)
        {
            helpers ayudante = new helpers();

            if (!ayudante.esFechaValida(txtFecha.Text))
            {
                MessageBox.Show("Fecha invalida!");
                return;
            }
            string sql = @"SELECT idFactura, importeTotal, ROUND(importeTotal * 0.21, 2) as idEmpleado, 
            ROUND(importeTotal * 0.79, 2) as tipoPago FROM ventas WHERE CONVERT(DATE, fechaHora) = '" + ayudante.insertarFechaConFormato(txtFecha.Text) + "';";

            ayudante.cargarReporte(sql, "DataSet1", informeDiarioGanan);
        }
Esempio n. 4
0
 private string insertarFechaConFormato(string fecha)
 {
     return(ayudante.insertarFechaConFormato(fecha));
 }