consulta de las ventas correspondientes a los grupos de tamaños

This commit is contained in:
Antonio Gonzalez
2020-02-19 16:45:47 -07:00
parent 956c9e2299
commit 0b1963b098
3 changed files with 109 additions and 16 deletions

View File

@@ -49,7 +49,7 @@ Partial Class Acumuladores_RepEntradasUsadosClientes
Dim Acum As New ClsAcumuladores
If Acum.EntradasUsadosClientesRep(CveAlmacen, FechaI, FechaF, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) Then
GvDatos.DataSource = Acum.DtResultados.FiltraParametros("Codigo_Clientes <> 'Total:'") 'los renglones generados con esta caracteriztica son con un grouping set en la consulta, se pueden quitar
GvDatos.DataSource = Acum.DtResultados.FiltraParametros("Codigo_Clientes <> 'Total:'") 'los renglones generados con esta caracteriztica son con un grouping set en la consulta, se pueden quitar
DatosEntradasUsadosClientes = Acum.DtResultados.FiltraParametros("Codigo_Clientes <> 'Total:'")
End If
@@ -61,18 +61,11 @@ Partial Class Acumuladores_RepEntradasUsadosClientes
Protected Sub GvDatos_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvDatos.RowDataBound
If e.Row.RowType = DataControlRowType.DataRow Then
'If e.Row.DBCampo("EsHeader").ToString = "-1" Or e.Row.DBCampo("Codigo").ToString = "" Then
' e.Row.CssClass = "SubTotales2"
'End If
If e.Row.DBCampo("TipoHeader").ToString = "1" Then
e.Row.CssClass = "Totales"
ElseIf e.Row.DBCampo("TipoHeader").ToString = "2" Then
e.Row.CssClass = "SubTotales"
ElseIf e.Row.DBCampo("TipoHeader").ToString = "3" Then
e.Row.CssClass = "SubTotales2"
End If
End If
If e.Row.DBCampo("EsHeader").ToString = "-1" Or e.Row.DBCampo("Codigo").ToString = "" Then
e.Row.CssClass = "SubTotales2"
End If
End If
End Sub
Protected Sub BtnImprimir_Click(sender As Object, e As EventArgs)
@@ -96,4 +89,19 @@ Partial Class Acumuladores_RepEntradasUsadosClientes
End Sub
Public Sub CargarVentasGrupo(sender As Object, e As EventArgs)
Dim tempLink As LinkButton = CType(sender, LinkButton)
Dim renglon As GridViewRow = CType(tempLink.NamingContainer, GridViewRow)
LbCliente.Text = renglon.DataKey("NombreComercial")
LbTam.Text = renglon.DataKey("Codigo")
Dim ObjAcum As New ClsAcumuladores
If ObjAcum.GetUsadosClasificacionVentas(renglon.DataKey("CveCliente"), renglon.DataKey("Codigo"), TxtFechaI.Text, TxtFechaF.Text) Then
GvVentas.DataSource = ObjAcum.DtResultados
End If
ObjAcum.Dispose()
GvVentas.DataBind()
RegistraScript("$('#ModalVentasAvance').modal('show');RecargaAvances = true;")
End Sub
End Class