8 Validaciones de corte

This commit is contained in:
rakcsle
2025-01-27 10:11:45 -07:00
parent ed7a8c8820
commit 8d6691b83e
2 changed files with 86 additions and 6 deletions

View File

@@ -1349,9 +1349,10 @@
<div class="row">
<div class="col-md-12" >
<asp:GridView ID="GvEstadoCajas" runat="server" AutoGenerateColumns="False" ClientIDMode="Static" EmptyDataText="No se encontraron Anticipos del Cliente"
<asp:GridView ID="GvEstadoCajas" runat="server" AutoGenerateColumns="true" ClientIDMode="Static" EmptyDataText="No se encontraron Anticipos del Cliente"
OnRowDataBound="GvEstadoCajas_RowDataBound"
ToolTip="Listado de Anticipos" CssClass="GVAnticipos table table-striped table-hover Widthall mysmallbtn" data-height="300" GridLines="None"
DataKeyNames="">
DataKeyNames="CveCuenta">
<Columns>
</Columns>
</asp:GridView>
@@ -1362,8 +1363,8 @@
</div>
<div class="modal-footer">
<asp:Button ID="Button1" runat="server" Text="Aceptar" class="btn btn-primary" ValidationGroup="VGAnticiposClientes" />
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>
<%--<asp:Button ID="Button1" runat="server" Text="Aceptar" class="btn btn-primary" ValidationGroup="VGAnticiposClientes" />
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>--%>
</div>
</div>
</div>
@@ -1417,7 +1418,7 @@
</div>
</div>
<br />
<asp:GridView ID="GvCxC" runat="server" AutoGenerateColumns="False" ClientIDMode="Static" EmptyDataText="No se encontraron Anticipos del Cliente"
<asp:GridView ID="GvCxC" runat="server" AutoGenerateColumns="False" ClientIDMode="Static" EmptyDataText="No se encontraron Anticipos del Cliente"
CssClass=" table table-striped table-hover Widthall mysmallbtn" data-height="300" GridLines="None"
DataKeyNames=" CveVenta,PorcentajeIVA,TipoDocto,CveSubProyecto,CveMoneda,TipoCambio, Fecha,SerieFolio, SubTotal,IVA,Total,IEPS,RetIVA,RetISR, CveCliente,Saldo">
<Columns>

View File

@@ -167,6 +167,10 @@ Partial Class Ventas_PVCobranza
DivNoTimbradas.Visible = True
End If
If UsuarioActual.TienePermisoProceso(407) Then
LnkEstadosCaja.Visible = True
End If
End If
End Sub
@@ -3015,8 +3019,83 @@ Partial Class Ventas_PVCobranza
TxtImporteContado.Text = (LtlSaldo.Text.ToDecimal + SaldoCxC).FormatoNumero
RegistraScript("$('#divCxC').hide();", "AE21")
UPPCobranza.Update()
UPPTotalesContado.update
UPPTotalesContado.Update()
End Sub
Private Property DTEstadosCaja As DataTable
Get
If ViewState("DTEstadosCaja") Is Nothing Then
ViewState("DTEstadosCaja") = New DataTable
End If
Return DirectCast(ViewState("DTEstadosCaja"), DataTable)
End Get
Set(value As DataTable)
ViewState("DTEstadosCaja") = value
End Set
End Property
Protected Sub LnkEstadosCaja_Click(sender As Object, e As EventArgs)
GvEstadoCajas.DataSource = Nothing
DTEstadosCaja = New DataTable
Dim objPuntoVenta As New ClsPuntoVenta
Dim FechaInicio As Date = New Date(txtFechaI.Text.ToDate.Year, 1, 1)
Dim FechaFin As Date = New Date(FechaInicio.Year, 12, 31)
Dim CveCuenta As Integer = 197107
If objPuntoVenta.GetVta_EstadoCajas(CveCuenta, UsuarioActual.CveEmpresa, FechaInicio, FechaFin) Then
GvEstadoCajas.DataSource = objPuntoVenta.DtResultados
DTEstadosCaja = objPuntoVenta.DtResultados
End If
objPuntoVenta.Dispose()
GvEstadoCajas.DataBind()
UpDVEstadoCaja.Update()
RegistraScript("$('#DVEstadoCaja').modal()")
End Sub
Protected Sub GvEstadoCajas_RowDataBound(sender As Object, e As GridViewRowEventArgs)
If DTEstadosCaja.Rows.Count > 0 Then
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells(0).Visible = False
e.Row.Cells(1).Width = 300
End If
If e.Row.RowType = DataControlRowType.DataRow Then
e.Row.Cells(0).Visible = False
e.Row.Cells(1).Width = 300
e.Row.Cells(1).Attributes.Add("style", "white-space: nowrap;")
Dim IndexRow As Integer = e.Row.RowIndex
Dim CveCuenta As Integer = e.Row.DataKey("CveCuenta").ToEntero
For x = 2 To DTEstadosCaja.Columns.Count - 1
Dim Fecha As Date = DTEstadosCaja.Columns(x).ColumnName.ToString.ToDate
Dim Liga As String = $"../Contabilidad/RepMovimientosAuxiliaresCatalogo.aspx?CveCuenta={CveCuenta}&FI={Fecha.ToString("dd/MM/yyyy")}&FF={Fecha.ToString("dd/MM/yyyy")}&CveProyecto=-1&CveSubProyecto=-1&TP=1"
Dim Importe As Decimal = DTEstadosCaja.Rows(IndexRow)(x).ToString.ToDecimal
If Importe <> 0 Then
e.Row.Cells(x).Text = $"<a href='{Liga}' target='_blank' >{Importe.ToString("###,###,###.00")}</a>"
Else
e.Row.Cells(x).Text = ""
End If
Next
End If
End If
End Sub
End Class
Public Class MRespuestaSAT