This commit is contained in:
2023-06-30 18:09:55 -07:00
6 changed files with 2388 additions and 2231 deletions

View File

@@ -3,7 +3,7 @@ Option Strict On
Imports System.Data
Imports Extensiones
Imports Microsoft.Reporting.WebForms
Imports Microsoft.Reporting.WebForms
Partial Class Bancos_RepEgresosSinComprobante
Inherits ClsPaginas
@@ -59,6 +59,8 @@ Partial Class Bancos_RepEgresosSinComprobante
DdlProveedores.SelectedValue = "-1"
CargaDatos()
TxtConcepto.Text = "Saldo de Egresos por comprobar"
CargarCentrosDeCosto(Nothing, DdlSubProyecto, Nothing, LblSubproyecto, AplicaTodos:="Selecione uno")
End If
End Sub
@@ -169,14 +171,19 @@ Partial Class Bancos_RepEgresosSinComprobante
End Sub
Private Sub LnkHabilitarSaldar_Click(sender As Object, e As EventArgs) Handles LnkHabilitarSaldar.Click
For Each gr As GridViewRow In GvESC.Rows
If gr.DataKey("CveIE") <> "" Then
gr.FCCheckBox("Chk").Visible = True
LnkSaldar.Visible = True
LnkHabilitarSaldar.Visible = False
UPDatos.Update()
End If
Next
TxtConcepto.Text = "Saldo de Egresos por comprobar"
DVSaldar.Visible = True
UpSaldar.Update()
End Sub
Private Sub LnkHabilitarSaldoFyE_Click(sender As Object, e As EventArgs) Handles LnkHabilitarSaldarFyE.Click
For Each gr As GridViewRow In GvPersonal.Rows
@@ -191,25 +198,34 @@ Partial Class Bancos_RepEgresosSinComprobante
Protected Sub LnkSaldar_Click(sender As Object, e As EventArgs)
Dim Contador As Integer = 0
For Each gr As GridViewRow In GvESC.Rows
If gr.FCCheckBox("Chk").Checked Then
Contador += 1
End If
Next
If Not Contador > 0 Then
Alert("No se hay movimientos seleccionados")
Exit Sub
End If
Dim ObjConta As New ClsContabilidad
Dim ObjProveedor As New ClsCompProveedores(ObjConta.IniciaTransacSQL())
Dim EsContabilizable As Boolean = If(UsuarioActual.CveEmpresa.Contiene(13, 83), False, True)
Dim CvePrePoliza As Integer = 0
Dim MsgError As String = ""
Try
Dim Contador As Integer = 0
For Each gr As GridViewRow In GvESC.Rows
If gr.FCCheckBox("Chk").Checked Then
Contador += 1
End If
Next
If Contador > 0 Then
CvePrePoliza = ObjConta.AddPrePolizas("Bancos/RepEgresosSinComprobante", 6, 0, 0, 1, Now,
"Saldo de Egresos por comprobar", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
TxtConcepto.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
For Each gr As GridViewRow In GvESC.Rows
If gr.FCCheckBox("Chk").Checked Then
@@ -282,8 +298,10 @@ Partial Class Bancos_RepEgresosSinComprobante
If MsgError = "" Then
LnkSaldar.Visible = False
LnkHabilitarSaldar.Visible = True
'LnkSaldar.Visible = False
'LnkHabilitarSaldar.Visible = True
DVSaldar.Visible = False
ObjConta.Commit()
CargaDatos()
Alert(String.Format("Los movimientos se saldaron correctamente <br/> <a href='/Contabilidad/RegPrePolizas.aspx?CvePrePoliza={0}' class='Texto'>Ver Póliza</a>", CvePrePoliza), TipoMensaje.MsgInformacion)