Correciones Portal clientes

This commit is contained in:
rakcsle
2022-03-23 12:37:24 -07:00
parent b3c996fc93
commit e0263602f8
2 changed files with 57 additions and 33 deletions

View File

@@ -271,6 +271,7 @@ Partial Class Ventas_PortalCliente
#Region "TAB HISTORIAL DE VENTAS"
Private Sub CargaHistorial(Optional SelectTop As Integer = 21, Optional CveClienteSucursal As Integer = -1)
Dim ObjClientes As New ClsClientes()
If ObjClientes.GetHistorialVentas(CveCliente, UsuarioActual.CveEmpresa, SelectTop, CveClienteSucursal:=CveClienteSucursal) Then
If ObjClientes.DtResultados.Rows.Count > 0 Then
@@ -291,6 +292,9 @@ Partial Class Ventas_PortalCliente
End If
ObjClientes.Dispose()
GVHistorial.DataBind()
RblTipo_SelectedIndexChanged(Nothing, Nothing)
End Sub
Protected Sub GVHistorial_RowDataBound(sender As Object, e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles GVHistorial.RowDataBound
@@ -1233,29 +1237,39 @@ Partial Class Ventas_PortalCliente
GVAnticiposHistorial.DataBind()
End Sub
Protected Sub GVAnticipos_RowDataBound(sender As Object, e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles GVAnticipos.RowDataBound, GVAnticiposHistorial.RowDataBound
If e.Row.RowType = DataControlRowType.DataRow Then
If e.Row.RowIndex = 0 Then
e.Row.Cells(0).ColumnSpan = 2
e.Row.Cells(0).HorizontalAlign = HorizontalAlign.Right
e.Row.FCLiteral("LtlFactura").Text = "Total" & " "
e.Row.BackColor = Drawing.Color.LightGray
e.Row.Cells(1).Visible = False
End If
Protected Sub GVAnticipos_RowDataBound(sender As Object, e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles GVAnticipos.RowDataBound, GVAnticiposHistorial.RowDataBound
If e.Row.RowType = DataControlRowType.DataRow Then
'If e.Row.RowIndex = 0 Then
' e.Row.Cells(0).ColumnSpan = 2
' e.Row.Cells(0).HorizontalAlign = HorizontalAlign.Right
' e.Row.FCLiteral("LtlFactura").Text = "Total" & " "
' e.Row.BackColor = Drawing.Color.LightGray
' e.Row.Cells(1).Visible = False
'End If
If e.Row.RowIndex = 1 Then
e.Row.Cells(0).Width = Unit.Pixel(60)
e.Row.Cells(1).Width = Unit.Pixel(100)
e.Row.Cells(2).Width = Unit.Pixel(80)
End If
If e.Row.DBCampo("CveVenta").ToString.ToEntero = 0 Then
e.Row.Cells(0).ColumnSpan = 2
e.Row.Cells(0).HorizontalAlign = HorizontalAlign.Right
e.Row.BackColor = Drawing.Color.LightGray
e.Row.Cells(1).Visible = False
End If
e.Row.Cells(2).HorizontalAlign = HorizontalAlign.Right
'If e.Row.DBCampo("Saldo").ToDouble < 0 Then e.Row.Cells(2).ForeColor = Drawing.Color.Red
'If e.Row.DBCampo("Saldo").ToDouble = 0 Then DirectCast(e.Row.FindControl("LtlAnticipos"), Literal).Text = ""
If e.Row.RowIndex > 0 Then
e.Row.FCLiteral("LtlFactura").Text = e.Row.DBCampo("Folio")
End If
e.Row.Cells(2).HorizontalAlign = HorizontalAlign.Right
'If e.Row.DBCampo("Saldo").ToDouble < 0 Then e.Row.Cells(2).ForeColor = Drawing.Color.Red
'If e.Row.DBCampo("Saldo").ToDouble = 0 Then DirectCast(e.Row.FindControl("LtlAnticipos"), Literal).Text = ""
'If e.Row.RowIndex > 0 Then
e.Row.FCLiteral("LtlFactura").Text = e.Row.DBCampo("Folio")
'End If
If CType(sender, GridView).ID = "GVAnticipos" Then
e.Row.Cells(2).Font.Bold = True