RepOrigen Aplicacion , seleimina PolizasImpresion.aspx de contabilidad 2
This commit is contained in:
@@ -81,6 +81,16 @@ Partial Class Contabilidad_RepOrigenAplicacion
|
||||
|
||||
TabContainer_ActiveTabChanged(TabContainer, EventArgs.Empty)
|
||||
|
||||
|
||||
If UsuarioActual.Empresa.UsaContabilidadSIG Then
|
||||
|
||||
TabMensual.Enabled = False
|
||||
TabAnual.Enabled = False
|
||||
TdFI.Visible = False
|
||||
tdTipoReporte.Visible = False
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -139,23 +149,48 @@ Partial Class Contabilidad_RepOrigenAplicacion
|
||||
|
||||
#Region " NORMAL "
|
||||
Private Sub CargaDatos()
|
||||
Dim ObjConta As New ClsContPAQi(UsuarioActual.Empresa)
|
||||
|
||||
Dim FechaInicio = If(TxtFechaDel.Text = "" Or TxtFechaDel.Text = "__/__/____", Date.Now, TxtFechaDel.Text.ToDate)
|
||||
Dim FechaFin = If(TxtFechaAl.Text = "" Or TxtFechaAl.Text = "__/__/____", Date.Now, TxtFechaAl.Text.ToDate)
|
||||
|
||||
If ObjConta.GetOrigenAplicacion(FechaInicio, FechaFin) Then
|
||||
DtDatos = ObjConta.DtResultados
|
||||
LnkExcel.Visible = False
|
||||
|
||||
If UsuarioActual.Empresa.UsaContabilidadSIG Then
|
||||
Dim ObjConta As New ClsContabilidad
|
||||
|
||||
If ObjConta.GetRepOrigenAplicacion(TxtFechaAl.Text.ToDate, UsuarioActual.CveEmpresa) Then
|
||||
GvDatos.DataSource = ObjConta.DtResultados
|
||||
|
||||
If ObjConta.DtResultados.Rows.Count > 0 Then
|
||||
LnkExcel.Visible = True
|
||||
End If
|
||||
Else
|
||||
GvDatos.DataSource = Nothing
|
||||
End If
|
||||
ObjConta.Dispose()
|
||||
GvDatos.DataBind()
|
||||
|
||||
Else
|
||||
DtDatos = Nothing
|
||||
Alert("Ocurrio un error al cargar los datos de origen y aplicación", TipoMensaje.MsgError)
|
||||
End If
|
||||
ObjConta.Dispose()
|
||||
|
||||
Dim ObjConta As New ClsContPAQi(UsuarioActual.Empresa)
|
||||
|
||||
Dim FechaInicio = If(TxtFechaDel.Text = "" Or TxtFechaDel.Text = "__/__/____", Date.Now, TxtFechaDel.Text.ToDate)
|
||||
Dim FechaFin = If(TxtFechaAl.Text = "" Or TxtFechaAl.Text = "__/__/____", Date.Now, TxtFechaAl.Text.ToDate)
|
||||
|
||||
If ObjConta.GetOrigenAplicacion(FechaInicio, FechaFin) Then
|
||||
DtDatos = ObjConta.DtResultados
|
||||
|
||||
|
||||
If DtDatos IsNot Nothing Then
|
||||
CargaGrid()
|
||||
Else
|
||||
DtDatos = Nothing
|
||||
Alert("Ocurrio un error al cargar los datos de origen y aplicación", TipoMensaje.MsgError)
|
||||
End If
|
||||
ObjConta.Dispose()
|
||||
|
||||
|
||||
If DtDatos IsNot Nothing Then
|
||||
CargaGrid()
|
||||
End If
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub CargaGrid()
|
||||
@@ -334,4 +369,7 @@ Partial Class Contabilidad_RepOrigenAplicacion
|
||||
#End Region
|
||||
|
||||
|
||||
Protected Sub LnkExcel_Click(sender As Object, e As EventArgs)
|
||||
GvDatos.ExportToExcel2("RepOrigenAplicacion.xlsx")
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
Reference in New Issue
Block a user