@@ -97,7 +97,7 @@
-
+
@@ -203,7 +203,7 @@
diff --git a/AF/RepDepreciacion.aspx.vb b/AF/RepDepreciacion.aspx.vb
index 3a0e849b6..00cdc75ca 100644
--- a/AF/RepDepreciacion.aspx.vb
+++ b/AF/RepDepreciacion.aspx.vb
@@ -30,17 +30,15 @@ Partial Class AF_RepDepreciacion
Dim ObjInventario As New ClsInventarios
Dim ObjConta As New ClsContabilidad(ObjInventario.IniciaTransacSQL())
Dim ErrorMovInv As Boolean = False
- Dim ConceptoPoliza As String = String.Format("Depreciacion - {0}", txtFechaI.Text)
+ Dim ConceptoPoliza As String = String.Format("Depreciación - {0}", txtFechaI.Text)
Dim CveSubProyecto As Integer = DdlSubProyecto.SelectedValue.ToEntero
Dim CvePrePoliza = ObjConta.AddPrePolizas("Depreciacion", 74, 0, 0, 1, txtFechaI.Text.ToDate, ConceptoPoliza, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
-
-
For Each RowsDt As GridViewRow In GvDatos.Rows
CveActivoFijo = RowsDt.DataKey("CveActivoFijo").ToEntero
Dim MontoDepreciacion As Decimal = RowsDt.FCLiteral("LtlDepreciacionMensual").Text.ToDecimal
If MontoDepreciacion > 0 And CveActivoFijo <> 0 Then
- Dim ConceptoPolizaDetalle As String = String.Format("Depreciacion - {0} - {1}", txtFechaI.Text, RowsDt.FCLiteral("LtlDescripcion").Text)
+ Dim ConceptoPolizaDetalle As String = String.Format("Depreciación - {0} - {1}", txtFechaI.Text, RowsDt.FCLiteral("LtlDescripcion").Text)
If CvePrePoliza > 0 Then
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, -MontoDepreciacion, -MontoDepreciacion, 270, ConceptoPolizaDetalle, ConceptoPolizaDetalle, 0, CveActivoFijo:=CveActivoFijo, CveSubProyecto:=CveSubProyecto) Then
diff --git a/Acumuladores/RepAcumuladoresVigencia.aspx b/Acumuladores/RepAcumuladoresVigencia.aspx
index 2ec474f82..1fdbabe12 100644
--- a/Acumuladores/RepAcumuladoresVigencia.aspx
+++ b/Acumuladores/RepAcumuladoresVigencia.aspx
@@ -30,12 +30,16 @@
+
+
+
+
-
+
-
+
@@ -92,7 +96,7 @@
-
+
diff --git a/Acumuladores/RepAcumuladoresVigencia.aspx.cs b/Acumuladores/RepAcumuladoresVigencia.aspx.cs
index 1d388aa4c..da9ed60da 100644
--- a/Acumuladores/RepAcumuladoresVigencia.aspx.cs
+++ b/Acumuladores/RepAcumuladoresVigencia.aspx.cs
@@ -61,10 +61,14 @@ public partial class Acumuladores_RepAcumuladoresVigencia : ClsPaginas
private void CargaCombos()
{
CargarCentrosDeCosto(null, DdlSubProyecto, null, LblSubProyecto);
- DdlClasificaciones.DataSource = get_GlobalDTClasificaciones(UsuarioActual.CveEmpresa);
+ DdlClasificaciones.DataSource = get_GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltraParametros("Categoria = 'ACUMULADORES'");
DdlClasificaciones.DataBind();
DdlClasificaciones.Items.Insert(0, new ListItem("Todos", "-1"));
- }
+
+ DdlMarcas.DataSource = get_GlobalDTGralMarcas(UsuarioActual.CveEmpresa);
+ DdlMarcas.DataBind();
+ DdlMarcas.Items.Insert(0, new ListItem("Todas", "-1"));
+ }
protected void BtnConsultar_Click(object sender, EventArgs e)
{
@@ -76,7 +80,7 @@ public partial class Acumuladores_RepAcumuladoresVigencia : ClsPaginas
{
ClsAcumuladores ObjAcum = new ClsAcumuladores();
- if (ObjAcum.GetVigencias(txtFechaI.Text.ToDate(), txtFechaF.Text.ToDate(), DdlClasificaciones.SelectedValue.ToEntero(), UsuarioActual.CveEmpresa, DdlSubProyecto.SelectedValue.ToEntero()))
+ if (ObjAcum.GetVigencias(txtFechaI.Text.ToDate(), txtFechaF.Text.ToDate(), DdlMarcas.SelectedValue.ToEntero(), DdlClasificaciones.SelectedValue.ToEntero(), UsuarioActual.CveEmpresa, DdlSubProyecto.SelectedValue.ToEntero()))
{
GvAcum.DataSource = ObjAcum.DtResultados;
}
diff --git a/App_Code/ClsAcumuladores.vb b/App_Code/ClsAcumuladores.vb
index 354172fa2..8c9eb613c 100644
--- a/App_Code/ClsAcumuladores.vb
+++ b/App_Code/ClsAcumuladores.vb
@@ -1315,11 +1315,12 @@ Public Class ClsAcumuladores
End Function
#Region "VIGENCIA ACUMULADORES"
- Public Function GetVigencias(FechaInicio As Date, FechaFin As Date, CveClasificacion As Integer, CveEmpresa As Integer, CveSubProyecto As Integer) As Boolean
+ Public Function GetVigencias(FechaInicio As Date, FechaFin As Date, CveMarca As Integer, CveClasificacion As Integer, CveEmpresa As Integer, CveSubProyecto As Integer) As Boolean
Dim Retorno As Boolean = False
SqlDataAdapter("PA_Inv_ProductosFechasComprasSerie")
With SqlAdapter.SelectCommand.Parameters
+ .Add("@CveMarca", SqlDbType.Int).Value = CveMarca
.Add("@CveClasificacion", SqlDbType.Int).Value = CveClasificacion
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
.Add("@FechaIni", SqlDbType.Date).Value = FechaInicio
diff --git a/App_Code/ClsCompras.vb b/App_Code/ClsCompras.vb
index 70baf2423..912ad3e9f 100644
--- a/App_Code/ClsCompras.vb
+++ b/App_Code/ClsCompras.vb
@@ -197,7 +197,7 @@ Public Class ClsCompras
Optional CveOC As Integer = -1, Optional CveCajaChica As Integer = -1, Optional CvePersonal As Integer = -1, Optional NumeroReembolso As String = "-1", Optional CveProveedorSucursal As Integer = -1,
Optional AplicoPromocion As Boolean = False, Optional PorcentajeIVA As Double = 0, Optional CveMetodoPago As Integer = -1, Optional CveRetIVAConcepto As Integer = -1, Optional CveConceptoContableAlmacen As Integer = -1,
Optional CveRetISRConcepto As Integer = -1, Optional NoDeducible As Boolean = False, Optional CveTipoCompra As Integer = -1, Optional TotalOriginal As Double = 0, Optional CveTipoConcepto As Integer = 1, Optional CveFactura As Integer = -1,
- Optional CveContrato As Integer = -1, Optional EsImportacion As Boolean = False) As Boolean
+ Optional CveContrato As Integer = -1, Optional EsImportacion As Boolean = False, Optional CveSubProyecto As Integer = -1) As Boolean
Dim Retorno As Boolean = False
@@ -250,6 +250,7 @@ Public Class ClsCompras
.Add("@CveFactura", SqlDbType.Int).Value = CveFactura
.Add("@CveContrato", SqlDbType.Int).Value = CveContrato
.Add("@EsImportacion", SqlDbType.Bit).Value = EsImportacion
+ .Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
End With
@@ -274,7 +275,7 @@ Public Class ClsCompras
Public Function UpdateCompra(Descripcion As String, FolioSecundario As String, FechaVencimiento As Date, AplicaNotaCredito As Boolean, Observaciones As String, CveEstatusCompra As Integer,
Descuento As Double, SubTotal As Double, IVA As Double, Total As Double, CveUsuario As Integer, CveCompra As Integer, Optional CveCajaChica As Integer = -1, Optional CvePersonal As Integer = -1,
Optional CveProveedorSucursal As Integer = -1, Optional PorcentajeIVA As Double = 0, Optional NumeroReembolso As String = "", Optional CveTipoCompra As Integer = -1, Optional NoDeducible As Boolean = False,
- Optional CveFactura As Integer = -1, Optional CveContrato As Integer = -1, Optional CveRetIVAConcepto As Integer = -1, Optional CveRetISRConcepto As Integer = -1) As Boolean
+ Optional CveFactura As Integer = -1, Optional CveContrato As Integer = -1, Optional CveRetIVAConcepto As Integer = -1, Optional CveRetISRConcepto As Integer = -1, Optional CveSubProyecto As Integer = -1) As Boolean
Dim Retorno As Boolean = False
@@ -307,6 +308,8 @@ Public Class ClsCompras
.Add("@CveRetIVAConcepto", SqlDbType.Int).Value = CveRetIVAConcepto
.Add("@CveRetISRConcepto", SqlDbType.Int).Value = CveRetISRConcepto
+
+ .Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
End With
Try
@@ -3273,3 +3276,4 @@ Public Class ClsCompras
End Class
+
diff --git a/App_Code/ClsContabilidad.vb b/App_Code/ClsContabilidad.vb
index 7be58e7ef..952337c9a 100644
--- a/App_Code/ClsContabilidad.vb
+++ b/App_Code/ClsContabilidad.vb
@@ -3871,7 +3871,7 @@ Public Class ClsContabilidad
Return Retorno
End Function
- Public Function GetBalanzaComprobacion(FechaI As Date, FechaF As Date, TipoCuentas As Integer, TipoReporte As Integer, CveSubProyecto As String, CveEmpresa As Integer, Optional Sat As Integer = 0, Optional NivelCuenta As Integer = -1) As Boolean
+ Public Function GetBalanzaComprobacion(FechaI As Date, FechaF As Date, TipoCuentas As Integer, TipoReporte As Integer, CveProyecto As Integer, CveSubProyecto As Integer, CveEmpresa As Integer, Optional Sat As Integer = 0, Optional NivelCuenta As Integer = -1) As Boolean
Dim Retorno = False
@@ -3882,6 +3882,7 @@ Public Class ClsContabilidad
.Add("@FechaF", SqlDbType.Date).Value = FechaF
.Add("@TipoCuentas", SqlDbType.Int).Value = TipoCuentas
.Add("@TipoReporte", SqlDbType.Int).Value = TipoReporte
+ .Add("@CveProyecto", SqlDbType.Int).Value = CveProyecto
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@SAT", SqlDbType.Int).Value = Sat
@@ -6567,7 +6568,7 @@ Public Class ClsContabilidad
#Region "ESTADO RESULTADOS HORIZONTAL"
- Public Function GetEstadosMensual(FechaI As Date, FechaF As Date, CveSubProyecto As Integer, Divisor As Integer, CveEmpresa As Integer, CveUsuario As Integer, Optional Tipo As Integer = 1) As Boolean
+ Public Function GetEstadosMensual(FechaI As Date, FechaF As Date, CveProyecto As Integer, CveSubProyecto As Integer, Divisor As Integer, CveEmpresa As Integer, CveUsuario As Integer, Optional Tipo As Integer = 1) As Boolean
Dim Retorno = False
DataAdapter("PA_Conta2_EstadoResultadosMensual")
@@ -6576,6 +6577,7 @@ Public Class ClsContabilidad
.Add("@FechaI", SqlDbType.Date).Value = FechaI
.Add("@FechaF", SqlDbType.Date).Value = FechaF
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
+ .Add("@CveProyecto", SqlDbType.Int).Value = CveProyecto
.Add("@Divisor", SqlDbType.Int).Value = Divisor
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
@@ -6595,7 +6597,7 @@ Public Class ClsContabilidad
Return Retorno
End Function
- Public Function GetEstadosMensualHorizontal(FechaI As Date, FechaF As Date, CveSubProyecto As Integer, Divisor As Integer, CveEmpresa As Integer, CveUsuario As Integer, Optional Tipo As Integer = 1) As Boolean
+ Public Function GetEstadosMensualHorizontal(FechaI As Date, FechaF As Date, CveProyecto As Integer, CveSubProyecto As Integer, Divisor As Integer, CveEmpresa As Integer, CveUsuario As Integer, Optional Tipo As Integer = 1) As Boolean
Dim Retorno = False
DataAdapter("PA_Conta2_EstadoResultadosMensualHorizontal")
@@ -6604,6 +6606,7 @@ Public Class ClsContabilidad
.Add("@FechaI", SqlDbType.Date).Value = FechaI
.Add("@FechaF", SqlDbType.Date).Value = FechaF
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
+ .Add("@CveProyecto", SqlDbType.Int).Value = CveProyecto
.Add("@Divisor", SqlDbType.Int).Value = Divisor
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
@@ -6652,7 +6655,7 @@ Public Class ClsContabilidad
End Function
- Public Function GetEstadosAnualHorizontal(FechaI As Date, FechaF As Date, CveSubProyecto As Integer, Divisor As Integer, CveEmpresa As Integer, CveUsuario As Integer, Optional Tipo As Integer = 1, Optional Periodo As Integer = 12) As Boolean
+ Public Function GetEstadosAnualHorizontal(FechaI As Date, FechaF As Date, CveProyecto As Integer, CveSubProyecto As Integer, Divisor As Integer, CveEmpresa As Integer, CveUsuario As Integer, Optional Tipo As Integer = 1, Optional Periodo As Integer = 12) As Boolean
Dim Retorno = False
DataAdapter("PA_Conta2_EstadoResultadosAnualHorizontal")
@@ -6661,6 +6664,7 @@ Public Class ClsContabilidad
.Add("@FechaI", SqlDbType.Date).Value = FechaI
.Add("@FechaF", SqlDbType.Date).Value = FechaF
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
+ .Add("@CveProyecto", SqlDbType.Int).Value = CveProyecto
.Add("@Divisor", SqlDbType.Int).Value = Divisor
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
@@ -6682,7 +6686,7 @@ Public Class ClsContabilidad
End Function
- Public Function GetEstadosSubProyectoHorizontal(FechaI As Date, FechaF As Date, CveSubProyecto As Integer, Divisor As Integer, CveEmpresa As Integer, CveUsuario As Integer, Optional Tipo As Integer = 1) As Boolean
+ Public Function GetEstadosSubProyectoHorizontal(FechaI As Date, FechaF As Date, CveProyecto As Integer, CveSubProyecto As Integer, Divisor As Integer, CveEmpresa As Integer, CveUsuario As Integer, Optional Tipo As Integer = 1) As Boolean
Dim Retorno = False
DataAdapter("PA_Conta2_EstadoResultadosSubProyectolHorizontal")
@@ -6691,6 +6695,7 @@ Public Class ClsContabilidad
.Add("@FechaI", SqlDbType.Date).Value = FechaI
.Add("@FechaF", SqlDbType.Date).Value = FechaF
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
+ .Add("@CveProyecto", SqlDbType.Int).Value = CveProyecto
.Add("@Divisor", SqlDbType.Int).Value = Divisor
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
diff --git a/App_Code/ClsGenerales.vb b/App_Code/ClsGenerales.vb
index 10c90cc59..d24033dfe 100644
--- a/App_Code/ClsGenerales.vb
+++ b/App_Code/ClsGenerales.vb
@@ -1576,7 +1576,7 @@ Public Class ClsGenerales
Return Retorno
End Function
- Public Function AddCuentasDepositos(BancoNombre As String, Plaza As String, Sucursal As String, Cuenta As String, CLABE As String, CIE As String, SWIFT As String, Referencia As String, RefCrediProveedor As String, CveUsuario As Integer, CveMoneda As Integer,
+ Public Function AddCuentasDepositos(BancoNombre As String, Plaza As String, Sucursal As String, Cuenta As String, CLABE As String, CIE As String, SWIFT As String, Referencia As String, RefCrediProveedor As String, CveUsuario As Integer, CveMoneda As Integer, CveEmpresa As Integer,
Optional CveProveedor As Integer = -1, Optional CveCliente As Integer = -1, Optional CvePersonal As Integer = -1, Optional CveColectiva As Integer = -1, Optional CveUsuarioModifico As Integer = -1,
Optional Correo As String = "", Optional BBVAAlias As String = "-1", Optional EstatusPagoElectronico As Boolean = False, Optional EstatusPagoElectronicoGrupos As Boolean = False, Optional CveSATBanco As Integer = -1,
Optional ConceptoCIE As String = "-1") As Boolean
@@ -1585,6 +1585,7 @@ Public Class ClsGenerales
DataAdapter("PA_Gral_CuentasDepositosAdd")
With SqlAdapter.SelectCommand.Parameters
+ .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveProveedor", SqlDbType.Int).Value = CveProveedor
.Add("@CveColectiva", SqlDbType.Int).Value = CveColectiva
.Add("@CvePersonal", SqlDbType.Int).Value = CvePersonal
@@ -1626,14 +1627,16 @@ Public Class ClsGenerales
Return Retorno
End Function
- Public Function RemoveCuentasDepositos(CveCuentaDeposito As Integer, Optional CveUsuarioModifico As Integer = -1) As Boolean
+ Public Function RemoveCuentasDepositos(CveCuentaDeposito As Integer, CveEmpresa As Integer, CveUsuarioModifico As Integer) As Boolean
Dim Retorno As Boolean = False
- DataAdapter("PA_Gral_CuentasDepositosRemove")
-
- SqlAdapter.SelectCommand.Parameters.Add("@CveCuentaDeposito", SqlDbType.Int).Value = CveCuentaDeposito
- SqlAdapter.SelectCommand.Parameters.Add("@CveUsuarioModifico", SqlDbType.Int).Value = CveUsuarioModifico
-
+ DataAdapter("PA_Gral_CuentasDepositosRemove")
+ With SqlAdapter.SelectCommand.Parameters
+ .Add("@CveCuentaDeposito", SqlDbType.Int).Value = CveCuentaDeposito
+ .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
+ .Add("@CveUsuarioModifico", SqlDbType.Int).Value = CveUsuarioModifico
+ End With
+
Try
SqlAdapter.Fill(Data)
Retorno = True
@@ -1655,8 +1658,9 @@ Public Class ClsGenerales
DataAdapter("PA_Gral_CuentasDepositosPersonalUpdate")
- With SqlAdapter.SelectCommand.Parameters
- .Add("@CveCuentaDeposito", SqlDbType.Int).Value = CveCuentaDeposito
+ With SqlAdapter.SelectCommand.Parameters
+ .Add("@CveCuentaDeposito", SqlDbType.Int).Value = CveCuentaDeposito
+ .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@BancoNombre", SqlDbType.VarChar).Value = BancoNombre
.Add("@Cuenta", SqlDbType.VarChar).Value = Cuenta
.Add("@CLABE", SqlDbType.VarChar).Value = CLABE
@@ -1685,14 +1689,15 @@ Public Class ClsGenerales
End Function
Public Function UpdateCuentasDepositos(CveCuentaDeposito As Integer, BancoNombre As String, Plaza As String, Sucursal As String, Cuenta As String, CLABE As String, CIE As String, SWIFT As String, Referencia As String,
- RefCrediProveedor As String, Predeterminada As Boolean, Estatus As Boolean, CveMoneda As Integer, Optional CveUsuarioModifico As Integer = -1, Optional Correo As String = "",
+ RefCrediProveedor As String, Predeterminada As Boolean, Estatus As Boolean, CveMoneda As Integer, CveEmpresa As Integer, Optional CveUsuarioModifico As Integer = -1, Optional Correo As String = "",
Optional BBVAAlias As String = "-1", Optional EstatusPagoElectronico As Boolean = False, Optional EstatusPagoElectronicoGrupos As Boolean = False, Optional CveSATBanco As Integer = -1,
Optional ConceptoCIE As String = "-1") As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Gral_CuentasDepositosUpdate")
- With SqlAdapter.SelectCommand.Parameters
+ With SqlAdapter.SelectCommand.Parameters
+ .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@BancoNombre", SqlDbType.VarChar).Value = BancoNombre
.Add("@Plaza", SqlDbType.VarChar).Value = Plaza
.Add("@Sucursal", SqlDbType.VarChar).Value = Sucursal
diff --git a/App_Code/ClsInventarios.vb b/App_Code/ClsInventarios.vb
index 0ff33a38c..a86c1393f 100644
--- a/App_Code/ClsInventarios.vb
+++ b/App_Code/ClsInventarios.vb
@@ -136,6 +136,7 @@ Public Class ClsInventarios
Public Property Modulo As String
Public Property ConAplicacion As Boolean
Public Property CveInventarioFisicoPadre As Integer
+ Public Property CveFolioGarantia As Integer
@@ -875,7 +876,7 @@ Public Class ClsInventarios
ResponsableCarga = dr("ResponsableCarga").ToString
ResponsableRecibio = dr("ResponsableRecibio").ToString
Modulo = dr("Modulo").ToString
-
+ CveFolioGarantia = dr("CveFolioGarantia").ToString.ToEntero
Retorno = True
End If
@@ -985,7 +986,7 @@ Public Class ClsInventarios
Optional CveMovimientoRelacionado As Integer = -1, Optional TipoCambio As Double = -1, Optional CveVendedor As Integer = -1, Optional CveCliente As Integer = -1, Optional MovimientoFijo As Boolean = False, Optional CveContrato As Integer = -1,
Optional CveProveedor As Integer = -1, Optional Remision As String = "", Optional CveClienteSucursal As Integer = -1, Optional DepartamentoEntrega As String = "", Optional PedidoContrato As String = "", Optional GastoIndirecto As Double = -1, Optional CveChofer As Integer = -1, Optional CveCamion As Integer = -1, Optional Placa As String = "",
Optional FechaEntrega As String = "", Optional EspecifUnidad As String = "", Optional ResponsableCarga As String = "", Optional ResponsableRecibio As String = "", Optional Identificacion As String = "", Optional Domicilio As String = "",
- Optional Telefono As String = "", Optional Ciudad As String = "", Optional Licencia As String = "", Optional Modulo As String = "", Optional CveOP As Integer = -1) As Integer
+ Optional Telefono As String = "", Optional Ciudad As String = "", Optional Licencia As String = "", Optional Modulo As String = "", Optional CveOP As Integer = -1, Optional CveFolioGarantia As Integer = -1) As Integer
Dim Retorno As Integer = -1
@@ -1045,6 +1046,7 @@ Public Class ClsInventarios
.Add("@Licencia", SqlDbType.VarChar).Value = Licencia
.Add("@Modulo", SqlDbType.VarChar).Value = Modulo
.Add("@CveOP", SqlDbType.Int).Value = CveOP
+ .Add("@CveFolioGarantia", SqlDbType.Int).Value = CveFolioGarantia
End With
Try
diff --git a/App_Code/ClsPaginas.vb b/App_Code/ClsPaginas.vb
index e8c582654..18f5f4656 100644
--- a/App_Code/ClsPaginas.vb
+++ b/App_Code/ClsPaginas.vb
@@ -577,7 +577,7 @@ Public Class ClsPaginas
Dim AppNombre As String = $"GlobalDTProveedoresCuentas-{CveEmpresa}"
If HttpContext.Current.Application(AppNombre) Is Nothing Then
Using ObjProveedoresBancos As New ClsGenerales
- If ObjProveedoresBancos.GetCuentasDepositos(CveEmpresa:=CveEmpresa, CveProveedor:=-1, CveCliente:=-2, CvePersonal:=-2) Then Application(AppNombre) = ObjProveedoresBancos.DtResultados
+ If ObjProveedoresBancos.GetCuentasDepositos(CveEmpresa:=CveEmpresa, CveProveedor:=-2) Then Application(AppNombre) = ObjProveedoresBancos.DtResultados
End Using
End If
Dim filtros As New List(Of String)
@@ -602,7 +602,7 @@ Public Class ClsPaginas
Dim AppNombre As String = $"GlobalDTCuentasDepositosClientes-{CveEmpresa}"
If Application(AppNombre) Is Nothing Then
Dim P As New ClsGenerales
- If P.GetCuentasDepositos(CveEmpresa:=CveEmpresa, CveCliente:=-1, CveProveedor:=-2, CvePersonal:=-2) Then Application(AppNombre) = P.DtResultados
+ If P.GetCuentasDepositos(CveEmpresa:=CveEmpresa, CveCliente:=-2) Then Application(AppNombre) = P.DtResultados
P.Dispose()
End If
Dim Str As New StringBuilder
@@ -834,7 +834,7 @@ Public Class ClsPaginas
End If
Dim filtros As New List(Of String)
If CveCategoria <> -1 Then filtros.Add($"CveCategoria = {CveCategoria}")
- If UsoClasificacion <> -1 Then filtros.Add($"UsoClasificacion = {UsoClasificacion}")
+ If UsoClasificacion <> -1 Then filtros.Add($"UsoClasificacion IN ({UsoClasificacion},3) ")
If CveClasificacion <> -1 Then filtros.Add($"CveClasificacion = {CveClasificacion}")
If filtros.Count > 0 Then
Dim Dv As New DataView(DirectCast(HttpContext.Current.Application(AppNombre), DataTable), String.Join(" AND ", filtros), "", DataViewRowState.CurrentRows)
diff --git a/App_Code/ClsRH.vb b/App_Code/ClsRH.vb
index e48f19d44..7606b0287 100644
--- a/App_Code/ClsRH.vb
+++ b/App_Code/ClsRH.vb
@@ -330,7 +330,8 @@ Public Class ClsRH
End Function
Public Function AddAsistenciasInasistencias(Tipo As String, AplicaFalta As Boolean, AplicaAsistencia As Boolean, CveUsuario As Integer, CveEmpresa As Integer,
- chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo As Boolean, chkAplicaAguinaldo As Boolean, chkAplicaUtilidades As Boolean) As Boolean
+ chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo As Boolean, chkAplicaAguinaldo As Boolean,
+ chkAplicaUtilidades As Boolean, aplicaPago As Integer, aplicaPagoDoble As Integer, aplicaPrimaVac As Integer) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_RH_AsistenciasInasistenciasAdd")
@@ -347,6 +348,9 @@ Public Class ClsRH
.Add("@AplicaRetardo", SqlDbType.Bit).Value = chkAplicaRetardo
.Add("@AplicaAguinaldo", SqlDbType.Bit).Value = chkAplicaAguinaldo
.Add("@AplicaUtilidades", SqlDbType.Bit).Value = chkAplicaUtilidades
+ .Add("@AplicaPago", SqlDbType.Int).Value = aplicaPago
+ .Add("@AplicaPagoDoble", SqlDbType.Int).Value = aplicaPagoDoble
+ .Add("@AplicaPrimaVac", SqlDbType.Int).Value = aplicaPrimaVac
End With
@@ -367,7 +371,8 @@ Public Class ClsRH
End Function
Public Function UpdateAsistenciasInasistencias(Tipo As String, AplicaFalta As Boolean, AplicaAsistencia As Boolean, Estatus As Boolean, CveAI As Integer,
-chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo As Boolean, chkAplicaAguinaldo As Boolean, chkAplicaUtilidades As Boolean) As Boolean
+ chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo As Boolean, chkAplicaAguinaldo As Boolean, chkAplicaUtilidades As Boolean,
+ aplicaPago As Integer, aplicaPagoDoble As Integer, aplicaPrimaVac As Integer) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_RH_AsistenciasInasistenciasUpdate")
@@ -384,6 +389,9 @@ chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo
.Add("@AplicaRetardo", SqlDbType.Bit).Value = chkAplicaRetardo
.Add("@AplicaAguinaldo", SqlDbType.Bit).Value = chkAplicaAguinaldo
.Add("@AplicaUtilidades", SqlDbType.Bit).Value = chkAplicaUtilidades
+ .Add("@AplicaPago", SqlDbType.Int).Value = aplicaPago
+ .Add("@AplicaPagoDoble", SqlDbType.Int).Value = aplicaPagoDoble
+ .Add("@AplicaPrimaVac", SqlDbType.Int).Value = aplicaPrimaVac
End With
Try
diff --git a/App_Code/LogicNominas.vb b/App_Code/LogicNominas.vb
index f6fb9490b..640d0d915 100644
--- a/App_Code/LogicNominas.vb
+++ b/App_Code/LogicNominas.vb
@@ -144,7 +144,8 @@ Public Class LogicNominas
Dim SalarioDiarioSS As Double = 0
Dim ClaveEstado As String = ""
Dim MetodoPagoFijo As Boolean
-
+ Dim totalDb As Decimal
+ Dim subTotalDb As Decimal
Dim CodigoPostal As String = ""
Dim ObjIncapacidades As New List(Of CFDINominaIncapacidades)
@@ -157,6 +158,8 @@ Public Class LogicNominas
Dim drow As DataRow = objNomina.DtResultados.Rows(0)
CvePersonal = drow("CvePersonal").ToString().ToEntero()
CvePeriodo = drow("CvePeriodo").ToString().ToEntero()
+ totalDb = drow("Total").ToString().ToDecimal()
+ subTotalDb = drow("SubTotal").ToString().ToDecimal()
cfdi.Nomina.Antiguedad = drow("Antiguedad").ToString().ToEntero()
cfdi.Nomina.UltimoSueldoOrdinario = drow("UltimoSueldoOrdinario").ToString().ToDecimal()
Serie = objNomina.Serie
@@ -438,9 +441,9 @@ Public Class LogicNominas
cfdi.Comprobante.Serie = Serie
cfdi.Comprobante.Folio = Folio
cfdi.Comprobante.Fecha = Now
- cfdi.Comprobante.SubTotal = cfdi.Nomina.TotalPercepciones.ToString().ToDecimal() + cfdi.Nomina.TotalOtrosPagos.ToString().ToDecimal()
+ cfdi.Comprobante.SubTotal = subTotalDb 'cfdi.Nomina.TotalPercepciones.ToString().ToDecimal() + cfdi.Nomina.TotalOtrosPagos.ToString().ToDecimal()
cfdi.Comprobante.Descuentos = cfdi.Nomina.TotalDeducciones.ToString().ToDecimal()
- cfdi.Comprobante.Total = cfdi.Comprobante.SubTotal - cfdi.Comprobante.Descuentos 'cfdi.Nomina.TotalPercepciones + cfdi.Nomina.TotalOtrosPagos - cfdi.Nomina.TotalDeducciones
+ cfdi.Comprobante.Total = totalDb 'cfdi.Comprobante.SubTotal - cfdi.Comprobante.Descuentos 'cfdi.Nomina.TotalPercepciones + cfdi.Nomina.TotalOtrosPagos - cfdi.Nomina.TotalDeducciones
cfdi.Comprobante.MotivoDescuento = "" '"Deducciones nómina"
cfdi.Comprobante.Moneda = "MXN"
cfdi.Comprobante.TipoComprobante = "N"
diff --git a/Bancos/IE.aspx.vb b/Bancos/IE.aspx.vb
index d2b1a1088..7b28e1a9d 100644
--- a/Bancos/IE.aspx.vb
+++ b/Bancos/IE.aspx.vb
@@ -1146,20 +1146,17 @@ Partial Class Bancos_IE
Else
If DdlTipoTransaccion.SelectedValue = "9" Then
- Dim Dep As New ClsGenerales
- If Dep.GetCuentasDepositos(CveProveedor:=ObjIE.CveProveedor) Then
- DdlCuentaDeposito.DataSource = Dep.DtResultados.FiltraParametros(" Estatus = 'True' ")
- If Dep.DtResultados.Rows.Count > 0 Then
+ Dim dtc As DataTable = GlobalDTProveedoresCuentas(UsuarioActual.CveEmpresa, CveProveedor:=CveProveedor)
+
+ If dtc IsNot Nothing Then
+ DdlCuentaDeposito.DataSource = dtc.FiltraParametros(" Estatus = 'True' ")
+ If dtc.Rows.Count > 0 Then
trCuentaDeposito.Visible = True
DdlCuentaDeposito.Items.Insert(0, New ListItem("Seleccione una cuenta", "-1"))
- 'ElseIf Dep.DtResultados.Rows.Count = 1 Then
- ' TrCuentaDepositado.Visible = True
- ' LitTextoDepositado.Text = "Cuenta Depósito"
- ' LitDepositado.Text = Dep.DtResultados.Rows(0)("CuentaDeposito").ToString
- 'End If
+
End If
End If
- Dep.Dispose()
+
DdlCuentaDeposito.DataBind()
UpCuentaDeposito.Update()
End If
@@ -1167,9 +1164,6 @@ Partial Class Bancos_IE
End If
LnkComplementoPago.Visible = True
-
-
-
If ObjIE.CveEstatusIE = 1 AndAlso ObjIE.CveIECancelado > 0 Then
'cuando es cheque devuelto
TabCancelacion.Visible = True
@@ -1185,8 +1179,6 @@ Partial Class Bancos_IE
End If
-
-
'DATOS DE CANCELACION
If ObjIE.CveEstatusIE = 2 OrElse (ObjIE.CveEstatusIE = 1 AndAlso ObjIE.CveIECancelacion > 0) Then
TabCancelacion.Visible = True
@@ -1327,8 +1319,6 @@ Partial Class Bancos_IE
End If
-
- RecargaGlobalCuentasBancarias()
ObjIE.Dispose()
ObjIE2.Dispose()
UPPP.Update()
@@ -3968,7 +3958,6 @@ Partial Class Bancos_IE
End If
Msg.Clear()
- RecargaGlobalCuentasBancarias()
ObjIE.Dispose()
ObjMov.Dispose()
If ObjComp IsNot Nothing Then ObjComp.Dispose()
@@ -5206,15 +5195,23 @@ Partial Class Bancos_IE
'If DdlTipoTransaccion.SelectedValue.Contiene("2", "9") Then ' transferencias y layout
trCuentaDeposito.Visible = False
+ Dim dtc As DataTable = Nothing
- Dim Dep As New ClsGenerales
- If Dep.GetCuentasDepositos(CveProveedor:=CveProveedor, CveCliente:=CveCliente, CvePersonal:=CvePersonal) Then
+ If CveProveedor > 0 Then
+ dtc = GlobalDTProveedoresCuentas(UsuarioActual.CveEmpresa, CveProveedor:=CveProveedor)
+ ElseIf CveCliente > 0 Then
+ dtc = GlobalDTCuentasDepositosClientes(UsuarioActual.CveEmpresa, CveCliente:=CveCliente)
+ End If
+
+
+ ' If Dep.GetCuentasDepositos(CveProveedor:=CveProveedor, CveCliente:=CveCliente, CvePersonal:=CvePersonal) Then
+ If dtc IsNot Nothing Then
If DdlTipoTransaccion.SelectedValue = "9" And CveIE <= -1 Then
- DdlCuentaDeposito.DataSource = Dep.DtResultados.FiltraParametros("EstatusPagoElectronico = 'True' AND Estatus ='True'")
+ DdlCuentaDeposito.DataSource = dtc.FiltraParametros("EstatusPagoElectronico = 'True' AND Estatus ='True'")
- If Dep.DtResultados.FiltraParametros("EstatusPagoElectronico = 'True' AND Estatus ='True'").Rows.Count > 0 Then
+ If dtc.FiltraParametros("EstatusPagoElectronico = 'True' AND Estatus ='True'").Rows.Count > 0 Then
trCuentaDeposito.Visible = True
DdlCuentaDeposito.Items.Insert(0, New ListItem("Seleccione una cuenta", "-1"))
Else
@@ -5223,10 +5220,9 @@ Partial Class Bancos_IE
DdlCuentaDeposito.Items.Insert(0, New ListItem("Seleccione una cuenta", "-1"))
ElseIf DdlTipoTransaccion.SelectedValue = "17" And CveIE <= -1 Then
+ If dtc.Rows.Count > 0 Then
- If Dep.DtResultados.Rows.Count > 0 Then
-
- DdlCuentaDeposito.DataSource = Dep.DtResultados.FiltraParametros(" Estatus = 'True' ")
+ DdlCuentaDeposito.DataSource = dtc.FiltraParametros(" Estatus = 'True' ")
trCuentaDeposito.Visible = True
BtnGuardar.ToolTip = ""
@@ -5242,15 +5238,14 @@ Partial Class Bancos_IE
UpGuardar.Update()
Else
- DdlCuentaDeposito.DataSource = Dep.DtResultados.FiltraParametros("Estatus ='True'")
- If Dep.DtResultados.Rows.Count > 0 Then
+ DdlCuentaDeposito.DataSource = dtc.FiltraParametros("Estatus ='True'")
+ If dtc.Rows.Count > 0 Then
trCuentaDeposito.Visible = True
DdlCuentaDeposito.Items.Insert(0, New ListItem("Seleccione una cuenta", "-1"))
End If
End If
-
Else
If DdlTipoTransaccion.SelectedValue.Contiene("9", "17") And CveIE <= -1 Then
@@ -5265,9 +5260,8 @@ Partial Class Bancos_IE
UpGuardar.Update()
-
End If
- Dep.Dispose()
+
'If DdlTipoTransaccion.SelectedValue = "9" AndAlso DdlCuentaDeposito.Items.Count = 0 Then
' BtnIEGuardar.Enabled = False
@@ -5280,7 +5274,7 @@ Partial Class Bancos_IE
' trCuentaDeposito.Visible = False
' DdlCuentaDeposito.Items.Clear()
'End If
- RecargaGlobalCuentasBancarias()
+
UpCuentaDeposito.Update()
UpDatos.Update()
End Sub
@@ -5305,18 +5299,6 @@ Partial Class Bancos_IE
End Sub
- 'Recaga CuentasBancarias de Proveedor
- Private Sub RecargaGlobalCuentasBancarias(Optional ByVal CveCuenta As Integer = -1)
- If CveProveedor > 0 Then
- GlobalDTProveedoresCuentas(UsuarioActual.CveEmpresa, -1) = Nothing
- 'Dim ObjCuentasBancos As New ClsGenerales
-
- 'If ObjCuentasBancos.GetCuentasDepositos(CveEmpresa:=UsuarioActual.CveEmpresa) Then
- ' GlobalDTProveedoresCuentas(-1, True) = ObjCuentasBancos.DtResultados
- 'End If
- 'ObjCuentasBancos.Dispose()
- End If
- End Sub
Protected Sub DdlCuentaDeposito_SelectedIndexChanged(sender As Object, e As EventArgs)
Dim Dep As New ClsGenerales
@@ -6640,7 +6622,6 @@ Partial Class Bancos_IE
trCuentaDeposito.Visible = True
DdlCuentaDeposito.Enabled = True
-
Dim Dep As New ClsGenerales
If Dep.GetCuentasDepositos(CveCliente:=CveCliente) Then
@@ -6651,15 +6632,12 @@ Partial Class Bancos_IE
DdlCuentaDeposito.Items.Insert(0, New ListItem("Seleccione una cuenta", "-1"))
End If
-
End If
Dep.Dispose()
DdlCuentaDeposito.DataBind()
UpCuentaDeposito.Update()
-
-
End If
End Sub
diff --git a/Bancos/PagoAcreedor.aspx.cs b/Bancos/PagoAcreedor.aspx.cs
index 7079468f1..ca0559b4b 100644
--- a/Bancos/PagoAcreedor.aspx.cs
+++ b/Bancos/PagoAcreedor.aspx.cs
@@ -277,7 +277,7 @@ public partial class Bancos_PagoAcreedor : ClsPaginas
int CveConceptoContablePago = 42;
int CveConceptoContableBancoComplementario = 204;
int CveConceptoContablePrestamoComplementario = 202;
- int CvePlantillaPoliza = 21;
+ int CvePlantillaPoliza = 43;
int CvePrePoliza = 0;
int CveMonedaPago = get_GlobalDTBancosCuentas(-1, CveEmpresa: UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveMoneda", $"CveEmpresa = {UsuarioActual.CveEmpresa} AND CveCuenta = {DdlCuenta.SelectedValue.ToEntero()}").ToEntero();
int FolioFijo = 0;
@@ -704,7 +704,7 @@ public partial class Bancos_PagoAcreedor : ClsPaginas
int CveConceptoContablePrestamo = 41;
int CveConceptoContableBancoComplementario = 204;
int CveConceptoContablePrestamoComplementario = 202;
- int CvePlantillaPoliza = 45;
+ int CvePlantillaPoliza = 44;
int CvePrePoliza = 0;
int CveMoneda = get_GlobalDTBancosCuentas(-1, CveEmpresa: UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveMoneda", $"CveEmpresa = {UsuarioActual.CveEmpresa} AND CveCuenta = {DdlCuentaPrestamo.SelectedValue.ToEntero()}").ToEntero();
int FolioFijo = 0;
diff --git a/Bancos/ProveedoresAbonar.aspx.vb b/Bancos/ProveedoresAbonar.aspx.vb
index 660e1a514..d96237c96 100644
--- a/Bancos/ProveedoresAbonar.aspx.vb
+++ b/Bancos/ProveedoresAbonar.aspx.vb
@@ -650,16 +650,14 @@ Partial Class Bancos_ProveedoresAbonar
Exit Sub
End If
- Dim Dep As New ClsGenerales
- If Dep.GetCuentasDepositos(CveProveedor:=CveProveedor) Then
- Dim Row = Dep.DtResultados.FiltroPrimero(String.Format("CveCuentaDeposito = {0}", DdlCuentaDeposito.SelectedValue.ToEntero))
+ Dim dtc As DataTable = GlobalDTProveedoresCuentas(UsuarioActual.CveEmpresa, CveProveedor:=CveProveedor)
+ If dtc IsNot Nothing Then
+ Dim Row = dtc.FiltroPrimero(String.Format("CveCuentaDeposito = {0}", DdlCuentaDeposito.SelectedValue.ToEntero))
If Row IsNot Nothing AndAlso Row("Estatus").ToString = "False" Then
Alert("La cuenta depósito del proveedor esta inactiva.", TipoMensaje.MsgAdvertencia)
- Dep.Dispose()
Exit Sub
End If
End If
- Dep.Dispose()
'proceso que restringue solo el pago de apartir del dia de hoy y como limite fin de mes
If UsuarioActual.TienePermisoProceso(105) AndAlso (TxtFechaDocumento.Text.ToDate < Now.Date Or TxtFechaDocumento.Text.ToDate > Now.LastDayOfMonth) Then
@@ -1310,22 +1308,22 @@ Partial Class Bancos_ProveedoresAbonar
#Region " CUENTAS DEPOSITOS"
Private Sub CargaCuentasDepositos()
DdlCuentaDeposito.Items.Clear()
- ' If DdlTipoTransaccion.SelectedValue.Contiene("2", "9") Then ' transferencias y layout
+
trCuentaDeposito.Visible = False
- Dim Dep As New ClsGenerales
- If Dep.GetCuentasDepositos(CveProveedor:=CveProveedor) Then
+ Dim dtc As DataTable = GlobalDTProveedoresCuentas(UsuarioActual.CveEmpresa, CveProveedor:=CveProveedor)
+ If dtc IsNot Nothing Then
- If Dep.DtResultados.FiltraParametros("Estatus ='True'").Rows.Count > 0 Then
+ If dtc.FiltraParametros("Estatus ='True'").Rows.Count > 0 Then
If DdlTipoTransaccion.SelectedValue = "9" Then
- If Dep.DtResultados.Rows.Count > 0 Then
- DdlCuentaDeposito.DataSource = Dep.DtResultados.FiltraParametros("EstatusPagoElectronico = 'True' AND Estatus ='True'")
+ If dtc.Rows.Count > 0 Then
+ DdlCuentaDeposito.DataSource = dtc.FiltraParametros("EstatusPagoElectronico = 'True' AND Estatus ='True'")
DdlCuentaDeposito.Items.Insert(0, New ListItem("Seleccione una cuenta", "-1"))
End If
- If Dep.DtResultados.FiltraParametros("EstatusPagoElectronico = 'True' AND Estatus ='True'").Rows.Count > 0 Then
+ If dtc.FiltraParametros("EstatusPagoElectronico = 'True' AND Estatus ='True'").Rows.Count > 0 Then
trCuentaDeposito.Visible = True
DdlCuentaDeposito.Items.Insert(0, New ListItem("Seleccione una cuenta", "-1"))
Else
@@ -1335,45 +1333,28 @@ Partial Class Bancos_ProveedoresAbonar
ElseIf DdlTipoTransaccion.SelectedValue = "17" Then
-
- If Dep.DtResultados.Rows.Count > 0 Then
-
- DdlCuentaDeposito.DataSource = Dep.DtResultados.FiltraParametros(" Estatus ='True'")
+ If dtc.Rows.Count > 0 Then
+ DdlCuentaDeposito.DataSource = dtc.FiltraParametros(" Estatus ='True'")
DdlCuentaDeposito.Items.Insert(0, New ListItem("Seleccione una cuenta", "-1"))
-
trCuentaDeposito.Visible = True
BtnIEGuardar.ToolTip = ""
Else
-
BtnIEGuardar.Enabled = False
BtnIEGuardar.ToolTip = "El proveedor no tiene cuentas deposito"
Alert("El proveedor no tiene cuentas deposito.", TipoMensaje.MsgAdvertencia)
-
End If
-
-
UpGuardar.Update()
Else
- DdlCuentaDeposito.DataSource = Dep.DtResultados.FiltraParametros("Estatus ='True'")
- If Dep.DtResultados.Rows.Count > 0 Then
+ DdlCuentaDeposito.DataSource = dtc.FiltraParametros("Estatus ='True'")
+ If dtc.Rows.Count > 0 Then
trCuentaDeposito.Visible = True
DdlCuentaDeposito.Items.Insert(0, New ListItem("Seleccione una cuenta", "-1"))
End If
End If
-
DdlCuentaDeposito.DataBind()
-
-
- 'If DdlCuentaDeposito.Items.Count > 1 Then
- ' DdlCuentaDeposito.SelectedIndex = 1
- 'End If
-
-
Else
-
If DdlTipoTransaccion.SelectedValue.Contiene("9", "17") Then
-
BtnIEGuardar.Enabled = False
BtnIEGuardar.ToolTip = "El proveedor no tiene cuentas deposito"
Alert("El proveedor no tiene cuentas deposito.", TipoMensaje.MsgAdvertencia)
@@ -1382,17 +1363,11 @@ Partial Class Bancos_ProveedoresAbonar
BtnIEGuardar.Enabled = True
BtnIEGuardar.ToolTip = ""
End If
-
UpGuardar.Update()
-
End If
-
-
Else
-
If DdlTipoTransaccion.SelectedValue = "17" Then
-
BtnIEGuardar.Enabled = False
BtnIEGuardar.ToolTip = "El proveedor no tiene cuentas deposito"
Else
@@ -1402,11 +1377,8 @@ Partial Class Bancos_ProveedoresAbonar
End If
UpGuardar.Update()
-
-
End If
- Dep.Dispose()
'Else
' trCuentaDeposito.Visible = False
' DdlCuentaDeposito.Items.Clear()
@@ -1428,28 +1400,27 @@ Partial Class Bancos_ProveedoresAbonar
Protected Sub DdlCuentaDeposito_SelectedIndexChanged(sender As Object, e As EventArgs)
- Dim Dep As New ClsGenerales
+ Dim dtc As DataTable = GlobalDTProveedoresCuentas(UsuarioActual.CveEmpresa, CveProveedor:=CveProveedor)
+ If dtc IsNot Nothing AndAlso dtc.Rows.Count = 1 Then
- If Dep.GetCuentasDepositos(CveProveedor:=CveProveedor, CveCuentaDeposito:=DdlCuentaDeposito.SelectedValue.ToEntero) AndAlso Dep.DtResultados.Rows.Count = 1 Then
+ If dtc.Rows.Count > 0 Then
- If Dep.DtResultados.Rows.Count > 0 Then
-
- If Dep.DtResultados.Rows(0)("TieneCIE").ToString.ToEntero = 1 Then
+ If dtc.Rows(0)("TieneCIE").ToString.ToEntero = 1 Then
TrReferenciaCIE.Visible = True
- TxtReferenciaCIE.Text = Dep.DtResultados.Rows(0)("Referencia").ToString
- TxtConceptoCIE.Text = Dep.DtResultados.Rows(0)("ConceptoCIE").ToString
+ TxtReferenciaCIE.Text = dtc.Rows(0)("Referencia").ToString
+ TxtConceptoCIE.Text = dtc.Rows(0)("ConceptoCIE").ToString
- OriReferenciaCIE = Dep.DtResultados.Rows(0)("Referencia").ToString
- OriConceptoCIE = Dep.DtResultados.Rows(0)("ConceptoCIE").ToString
+ OriReferenciaCIE = dtc.Rows(0)("Referencia").ToString
+ OriConceptoCIE = dtc.Rows(0)("ConceptoCIE").ToString
Else
TrReferenciaCIE.Visible = False
End If
- If Boolean.Parse(Dep.DtResultados.Rows(0)("EstatusPagoElectronicoGrupos").ToString) = True AndAlso Dep.DtResultados.Rows(0)("CveSATBanco").ToString.ToEntero <= 0 Then
+ If Boolean.Parse(dtc.Rows(0)("EstatusPagoElectronicoGrupos").ToString) = True AndAlso dtc.Rows(0)("CveSATBanco").ToString.ToEntero <= 0 Then
Alert("Es necesario establecer el banco de la cuenta deposito", TipoMensaje.MsgAdvertencia)
BtnIEGuardar.Enabled = False
@@ -1466,7 +1437,6 @@ Partial Class Bancos_ProveedoresAbonar
TrReferenciaCIE.Visible = False
End If
- Dep.Dispose()
UpCuentaDeposito.Update()
UpGuardar.Update()
End Sub
diff --git a/Compras/Compras.aspx b/Compras/Compras.aspx
index c7021722e..02dc29703 100644
--- a/Compras/Compras.aspx
+++ b/Compras/Compras.aspx
@@ -5521,6 +5521,7 @@
+
@@ -6789,6 +6790,9 @@
$('#TxtDeudoresOtrosGastosIngresos').val(txtOtrIngEgs.value);
}
+
+
+
diff --git a/Compras/Compras.aspx.vb b/Compras/Compras.aspx.vb
index 81769821a..b4fcf4384 100644
--- a/Compras/Compras.aspx.vb
+++ b/Compras/Compras.aspx.vb
@@ -11,6 +11,7 @@ Imports Newtonsoft.Json
Imports Extensiones
Imports System.Activities.Expressions
Imports iText.Barcodes.Dmcode
+Imports Microsoft.Reporting.WebForms
Partial Class Compras_Compras
Inherits ClsPaginas
@@ -3199,10 +3200,10 @@ Partial Class Compras_Compras
'Tiene Importacion
If dr("EsImportacion").ToString = "True" Then
- chkImportacion.Checked = True
- Else
- chkImportacion.Checked = False
- End If
+ chkImportacion.Checked = True
+ Else
+ chkImportacion.Checked = False
+ End If
CargaComplementosPago()
CargaGvBitacora()
InventarioMov()
@@ -4203,6 +4204,13 @@ Partial Class Compras_Compras
'------------------ INICIA VALIDACIONES ------------------
+ Dim CveSubProyectoPrincipal As Integer = AsignarSubProyectoPrincipal()
+
+ If Not CveSubProyectoPrincipal > 0 Then
+ Alert("Falta asignar Proyecto a la compra", TipoMensaje.MsgAdvertencia)
+ End If
+
+
If Not ValidaVinculacionNotaFactura() Then
Alert("Se requiere que la nota este aplciada a las facturas", TipoMensaje.MsgAdvertencia)
Exit Sub
@@ -4920,7 +4928,8 @@ Partial Class Compras_Compras
TxtRedondeo.Text.ToDouble, TxtTotal.Text.ToDouble, TxtFecha.Text.Trim.ToDate, DdlMoneda.SelectedValue.ToEntero, TipoCambio, TxtFechaPago.Text.Trim.ToDate, ChkAplicaNotaCredito.Checked, TxtObsFact.Text.Trim, CveEstatusFactura,
CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, IdPoliza, CveCajaChica:=CveCajaChica, CvePersonal:=CvePersonal, NumeroReembolso:=NumeroReembolso, CveProveedorSucursal:=DdlProveedorSucursal.SelectedValue.ToEntero,
AplicoPromocion:=ChkOCPromocion.Checked, PorcentajeIVA:=PorcentajeIVA, CveMetodoPago:=CveMetodoPago, CveRetIVAConcepto:=If(DdlRetIVAConcepto.Items.Count > 0, DdlRetIVAConcepto.SelectedValue.ToEntero, -1), CveConceptoContableAlmacen:=CveConceptoContableAlmacen,
- CveRetISRConcepto:=If(DdlRetISRConcepto.Items.Count > 0, DdlRetISRConcepto.SelectedValue.ToEntero, -1), NoDeducible:=EsNoDeducible, CveTipoCompra:=DdlTipoCompra.SelectedValue.ToEntero, TotalOriginal:=TotalOriginal, CveTipoConcepto:=CveTipoConcepto, EsImportacion:=EsImportacion, CveFactura:=CveFactura) Then
+ CveRetISRConcepto:=If(DdlRetISRConcepto.Items.Count > 0, DdlRetISRConcepto.SelectedValue.ToEntero, -1), NoDeducible:=EsNoDeducible, CveTipoCompra:=DdlTipoCompra.SelectedValue.ToEntero, TotalOriginal:=TotalOriginal, CveTipoConcepto:=CveTipoConcepto,
+ EsImportacion:=EsImportacion, CveFactura:=CveFactura, CveSubProyecto:=CveSubProyectoPrincipal) Then
ViewState("CveCompra") = ObjCompras.CveCompra
If ObjCompras.DtResultados.Rows.Count > 0 Then ViewState("CompraFolio") = ObjCompras.DtResultados.Rows(0)("vFolio").ToString
@@ -6014,7 +6023,7 @@ Partial Class Compras_Compras
For Each Row As DataRow In DTPlatilla.Rows
- Dim CveSubProyectoInsertar As Integer = -1
+ Dim CveSubProyectoInsertar As Integer = CveSubProyectoPrincipal
Dim ConceptoContable As Integer = Row("CveConcepto").ToString.ToEntero
Dim TipoMovimiento As Boolean = If(Row("TipoMovto").ToString = "True", True, False)
@@ -6226,7 +6235,7 @@ Partial Class Compras_Compras
Case 25 'IEPS X Acreditar
If Not DdlTipoComprobante.SelectedValue.Contiene("Ant") Then
- CveSubProyectoInsertar = CveSubProyecto
+ 'CveSubProyectoInsertar = CveSubProyecto
importeMovimiento = CompraActual.IEPS
importeMN = Math.Round(importeMovimiento, 2) * tipoCambioActual * Multiplicador
If tipoCambioActual > 1 Then Concepto += $" TC{tipoCambioActual} ${importeMovimiento.FormatoNumero(2)}"
@@ -6322,7 +6331,7 @@ Partial Class Compras_Compras
Case 64 'Ganancia
- CveSubProyectoInsertar = CveSubProyecto
+ 'CveSubProyectoInsertar = CveSubProyecto
If CveSubProyectoInsertar <= 0 Then
ErrorPrepoliza = True
Alert("Concepto ganancia cambiaria sin sub proyecto", TipoMensaje.MsgAdvertencia)
@@ -7415,7 +7424,7 @@ Partial Class Compras_Compras
Else
Dim usacomplementariaAnticipo As Boolean = False
- usacomplementariaAnticipo = If(Ant.TCCompra > 1 And not UsuarioActual.CveEmpresa.Contiene(13,83), True, False)
+ usacomplementariaAnticipo = If(Ant.TCCompra > 1 And Not UsuarioActual.CveEmpresa.Contiene(13, 83), True, False)
Dim TipoCambioAnt As Decimal = Ant.TCCompra
Dim ImporteAnt As Decimal = importeMovimiento
@@ -8116,7 +8125,12 @@ Partial Class Compras_Compras
End If
If UsuarioActual.TienePermisoProceso(354) Then 'visualizar la póliza al registros
- Msg.AppendFormat("
Ver Póliza. ", CvePrePoliza)
+ Dim TempParametros = Encripta(String.Format("OP=PREPO&CvePrePoliza={0}", CvePrePoliza))
+ Msg.Append($" Descargar PDF ")
+
+
+
End If
If CveMovimientoInventario > 0 Then
@@ -8125,8 +8139,10 @@ Partial Class Compras_Compras
Msg.AppendFormat("Imprimir Entrada Almacen", TempParametros)
End If
- If Not ObjCompras.UpdateCompraPrePoliza(TxtFecha.Text.ToDate, PolizaFolio.ToString, IdPoliza, CvePrePoliza, CveCompra, 0) Then
- TieneError = True
+ If UsuarioActual.Empresa.TipoContabilidad = 2 Then
+ If Not ObjCompras.UpdateCompraPrePoliza(TxtFecha.Text.ToDate, PolizaFolio.ToString, IdPoliza, CvePrePoliza, CveCompra, 0) Then
+ TieneError = True
+ End If
End If
If EntregaDirecta Then
@@ -8220,6 +8236,39 @@ Partial Class Compras_Compras
End If
End Sub
+ Private Function AsignarSubProyectoPrincipal() As Integer
+
+ Dim CveSubProyectoPrincioal As Integer = -1
+
+ Dim DTSubProyectoPrincipal As New DataTable
+
+ DTSubProyectoPrincipal.Columns.Add("CveSubProyecto", GetType(Integer))
+ DTSubProyectoPrincipal.Columns.Add("Total", GetType(Decimal))
+
+
+ For Each dRow As DataRow In TmpDT.FiltraParametros("", "", {"CveSubProyecto"}).Rows
+
+ Dim CveSubProyectoActual As Integer = dRow("CveSubProyecto").ToString.ToEntero
+
+ If CveSubProyectoActual > 0 Then
+
+ Dim nRow = DTSubProyectoPrincipal.NewRow
+ nRow("CveSubProyecto") = dRow("CveSubProyecto").ToString.ToEntero
+ nRow("Total") = TmpDT.SUMD("Total", $"CveSubProyecto={CveSubProyectoActual}")
+ DTSubProyectoPrincipal.Rows.Add(nRow)
+ End If
+ Next
+
+
+ If DTSubProyectoPrincipal.Rows.Count > 0 Then
+ DTSubProyectoPrincipal = DTSubProyectoPrincipal.FiltraParametros("", "Total DESC ")
+ CveSubProyectoPrincioal = DTSubProyectoPrincipal.FiltroPrimeroValor("CveSubProyecto").ToEntero
+ End If
+
+ Return CveSubProyectoPrincioal
+
+ End Function
+
Private Function ValidaVinculacionNotaFactura() As Boolean
Dim Respuesta As Boolean = False
@@ -8825,6 +8874,12 @@ Partial Class Compras_Compras
Protected Sub BtnActualizar_Click(sender As Object, e As EventArgs) Handles BtnActualizar.Click
+ Dim CveSubProyectoPrincipal As Integer = AsignarSubProyectoPrincipal()
+ If Not CveSubProyectoPrincipal > 0 Then
+ Alert("Falta asignar Proyecto a la compra", TipoMensaje.MsgAdvertencia)
+ End If
+
+
If CveFactura > 0 Then
If Not AjustaCombustibles() Then
Exit Sub
@@ -8907,7 +8962,7 @@ Partial Class Compras_Compras
If ObjCompra.UpdateCompra(TxtDescripcion.Text.Trim, TxtFolioSecundario.Text.Trim, TxtFechaPago.Text.ToDate, ChkAplicaNotaCredito.Checked, TxtObsFact.Text.Trim, CveEstatusFactura,
TxtDescuento.Text.ToDouble, TxtSubTotal.Text.ToDouble, TxtIVA.Text.ToDouble, TxtTotal.Text.ToDouble,
UsuarioActual.CveUsuario, CveCompra, CveCajaChica:=DdlRembolsoCajaChica.SelectedValue.ToEntero, CvePersonal:=DdlRembolsoPersonal.SelectedValue.ToEntero, CveProveedorSucursal:=If(DdlProveedorSucursal.SelectedValue.ToEntero > 0, DdlProveedorSucursal.SelectedValue.ToEntero, -1), PorcentajeIVA:=PorcentajeIVA, NumeroReembolso:=TxtRembolsoNumero.Text,
- CveTipoCompra:=DdlTipoCompra.SelectedValue.ToEntero, NoDeducible:=EsNoDeducible, CveRetIVAConcepto:=TmpCveRetIVAConcepto, CveRetISRConcepto:=TmpCveRetISRConcepto) Then
+ CveTipoCompra:=DdlTipoCompra.SelectedValue.ToEntero, NoDeducible:=EsNoDeducible, CveRetIVAConcepto:=TmpCveRetIVAConcepto, CveRetISRConcepto:=TmpCveRetISRConcepto, CveSubProyecto:=CveSubProyectoPrincipal) Then
If Not ComparaDatatables() Then
@@ -13503,10 +13558,10 @@ Partial Class Compras_Compras
For Each Dr As GridViewRow In GVDevolucion.Rows
'CveAlmacen = Dr.DataKey("CveAlmacen").ToString.ToEntero
- cantidad = Dr.FCTextBox("TxtCantidad").Text.ToDecimal
- If cantidad > 0 Then
+ Cantidad = Dr.FCTextBox("TxtCantidad").Text.ToDecimal
+ If Cantidad > 0 Then
realizadevolucion = True
- subtotaldevolucion += Dr.DataKey("PU").ToString.ToDecimal * cantidad
+ subtotaldevolucion += Dr.DataKey("PU").ToString.ToDecimal * Cantidad
End If
Next
'si no esta vinculado a nc simplemente me lo brinco
@@ -20600,6 +20655,9 @@ Partial Class Compras_Compras
'End Function
+
+
+
End Class
diff --git a/Compras/PopUpVerFactura.aspx.vb b/Compras/PopUpVerFactura.aspx.vb
index 2480da969..870d9223e 100644
--- a/Compras/PopUpVerFactura.aspx.vb
+++ b/Compras/PopUpVerFactura.aspx.vb
@@ -1442,6 +1442,16 @@ Partial Class PopUpVerFactura
End If
End If
+
+
+
+ 'IMPRIME VALE
+ If UrlParametros("OP").ToString = "PREPO" Then
+ If UrlParametros("CVEPREPOLIZA") IsNot Nothing AndAlso UrlParametros("CVEPREPOLIZA").ToString.ToEntero > 0 Then
+ ImprimeImPrimePrePolizaS(UrlParametros("CVEPREPOLIZA").ToString.ToEntero)
+ End If
+ End If
+
End Sub
Private Function Parametros(Cadena As String) As Hashtable
@@ -6866,4 +6876,177 @@ Partial Class PopUpVerFactura
End Sub
#End Region
+
+#Region "OP PREPO"
+
+
+ Public Sub ImprimeImPrimePrePolizaS(CvePrePoliza As Integer)
+
+
+
+
+ If Not CvePrePoliza > 0 Then
+ Exit Sub
+ End If
+
+
+ 'ObjContabilidad.Dispose()
+
+ Dim rutaArchivo As String = ""
+ Dim params As New List(Of ReportParameter)
+ Dim Bytes As Byte() = Nothing
+ Dim DtDetalle As New DataTable
+ Dim CveTipoPolizaImp As Integer = 0
+ Dim FolioPoliza As String = ""
+ Dim ConceptoPolizaImp As String = ""
+ Dim CveMonedaImp As Integer = 0
+ Dim TipoPolizaString = ""
+
+ Dim ObjContabilidad As New ClsContabilidad
+
+ Dim TipoPolImp As String = ""
+
+
+ If ObjContabilidad.GetPrePoliza(CvePrePoliza, UsuarioActual.CveEmpresa) Then
+
+ Dim dr As DataRow = ObjContabilidad.DtResultados.FiltroPrimero("")
+
+ If dr IsNot Nothing Then
+
+ TipoPolImp = If(dr("CveTipoPoliza").ToString.ToEntero = 1, "Ingreso", If(dr("CveTipoPoliza").ToString.ToEntero = 2, "Egreso", "Diario"))
+ CveTipoPolizaImp = dr("CveTipoPoliza").ToString.ToEntero
+ ConceptoPolizaImp = dr("Concepto").ToString
+ FolioPoliza = dr("FolioPoliza").ToString
+ CveMonedaImp = dr("CveMoneda").ToString.ToEntero
+
+ Else
+ Alert("El documento solicitado no existe, favor de revisar su búsqueda.", TipoMensaje.MsgAdvertencia)
+ End If
+
+ End If
+
+ ObjContabilidad.Dispose()
+
+ Select Case CveTipoPolizaImp
+ Case 1
+ TipoPolizaString = "I"
+ Exit Select
+ Case 2
+ TipoPolizaString = "E"
+ Exit Select
+ Case Else
+ TipoPolizaString = "D"
+ Exit Select
+ End Select
+
+ If UsuarioActual.Empresa.Funcionalidad(282).ToEntero = 1 Then
+
+
+ Dim Archivo As System.IO.FileInfo
+
+ Dim ImpresionPersonalizada As Integer = UsuarioActual.Empresa.Funcionalidad(282).ToEntero
+
+ Archivo = New System.IO.FileInfo(String.Format("{0}Formatos/PolizasResumen.rdlc", UsuarioActual.Empresa.Ruta))
+ Dim Logo As New System.IO.FileInfo(String.Format("{0}Logo.png", UsuarioActual.Empresa.Ruta))
+
+ Dim ObjConta As New ClsContabilidad
+
+ If ObjConta.GetPrePolizasDetalleResumen(CvePrePoliza, UsuarioActual.CveEmpresa, ImpresionPersonalizada) AndAlso ObjConta.DtResultados.Rows.Count > 0 Then
+
+ Dim dr As DataRow
+ DtDetalle = ObjConta.DtResultados '.FiltraParametros("Contabilizable = 1", "Orden")
+ dr = DtDetalle.Rows(0)
+
+ params.Add(New ReportParameter("Empresa", UsuarioActual.Empresa.Empresa))
+ params.Add(New ReportParameter("TipoPoliza", TipoPolImp))
+ params.Add(New ReportParameter("Finicio", dr("Fecha").ToString.ToDate().ToString("dd/MM/yyyy")))
+ params.Add(New ReportParameter("FFin", dr("Fecha").ToString.ToDate().ToString("dd/MM/yyyy")))
+
+ params.Add(New ReportParameter("Fecha", dr("Fecha").ToString.ToDate().ToString("dd/MM/yyyy")))
+
+ params.Add(New ReportParameter("Numero", FolioPoliza))
+ params.Add(New ReportParameter("Moneda", If(CveMonedaImp = 2, "Dolar", "Peso Mexicano")))
+ params.Add(New ReportParameter("CodigoPostal", ""))
+
+ params.Add(New ReportParameter("UsuarioRegistro", UsuarioActual.Usuario))
+ params.Add(New ReportParameter("ConceptoPoliza", ConceptoPolizaImp))
+
+ params.Add(New ReportParameter("Folio", FolioPoliza))
+
+
+ If Logo.Exists Then
+ params.Add(New ReportParameter("pImg", $"file://{Logo.FullName}"))
+ Else
+ params.Add(New ReportParameter("pImg", ""))
+ End If
+
+
+ If Archivo.Exists Then
+ rutaArchivo = Archivo.FullName
+ Else
+ rutaArchivo = $"{DirectorioEmpresas}Grales\Formatos\PolizasResumen.rdlc"
+ End If
+
+
+ End If
+ ObjConta.Dispose()
+
+
+ Else
+
+ Dim Archivo = New System.IO.FileInfo(String.Format("{0}Formatos/Polizas.rdlc", UsuarioActual.Empresa.Ruta))
+ params = New List(Of ReportParameter)
+
+ Dim ObjConta As New ClsContabilidad
+ 'If ObjPoliza.GetPoliza(IdPoliza, -1, -1, -1, -1) AndAlso ObjPoliza.DtResultados.Rows.Count > 0 Then
+ If ObjConta.GetPrePolizasDetalle(CvePrePoliza, UsuarioActual.CveEmpresa) AndAlso ObjConta.DtResultados.Rows.Count > 0 Then
+
+ Dim dr As DataRow
+ DtDetalle = ObjConta.DtResultados.FiltraParametros("Contabilizable = 1", "Orden")
+ dr = DtDetalle.Rows(0)
+ Dim ruta As String = ""
+
+ params.Add(New ReportParameter("Empresa", UsuarioActual.Empresa.Empresa))
+ params.Add(New ReportParameter("TipoPoliza", dr("TipoPoliza").ToString))
+ params.Add(New ReportParameter("Finicio", dr("Fecha").ToString.ToDate.ToShortDateString))
+ params.Add(New ReportParameter("FFin", dr("Fecha").ToString.ToDate.ToShortDateString))
+
+ If UsuarioActual.CveEmpresa.Contiene(141) Then
+ params.Add(New ReportParameter("Fecha", dr("Fecha").ToString.ToDate.ToString("dd/MM/yyyy hh:mm:ss")))
+ Else
+ params.Add(New ReportParameter("Fecha", dr("Fecha").ToString.ToDate.ToShortDateString))
+ End If
+
+ FolioPoliza = dr("FolioPoliza").ToString
+ params.Add(New ReportParameter("Numero", dr("FolioPoliza").ToString))
+ params.Add(New ReportParameter("Moneda", If(CveMonedaImp = 2, "Dolar", "Peso Mexicano")))
+ params.Add(New ReportParameter("CodigoPostal", ""))
+
+ If UsuarioActual.CveEmpresa.Contiene(119, 141) Then
+ params.Add(New ReportParameter("UsuarioRegistro", GlobalDTUsuarios(dr("CveUsuario").ToString.ToEntero).FiltroPrimeroValor("Nombre")))
+ End If
+ If UsuarioActual.CveEmpresa.Contiene(140, 141) Then
+ params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
+ End If
+
+ If Archivo.Exists Then
+ rutaArchivo = UsuarioActual.Empresa.Ruta & "Formatos/Polizas.rdlc"
+ Else
+ rutaArchivo = "Empresas/Grales/Formatos/Polizas.rdlc"
+ End If
+ End If
+ ObjConta.Dispose()
+ End If
+
+
+ ImprimirPDF(rutaArchivo, DtDetalle, params, $"P{TipoPolizaString}{FolioPoliza}", Formato:="PDF")
+
+
+
+
+ End Sub
+
+
+#End Region
+
End Class
diff --git a/Compras/Proveedores.aspx b/Compras/Proveedores.aspx
index 5f998a8ad..715520321 100644
--- a/Compras/Proveedores.aspx
+++ b/Compras/Proveedores.aspx
@@ -202,168 +202,193 @@
-
-
-
-
-
-
Código:
-
-
-
-
-
-
-
-
Razón Social:
-
-
-
-
-
-
-
-
-
-
Nombre Comercial:
-
-
-
-
-
-
-
-
-
-
Nombre Corto:
-
-
-
-
-
-
-
-
Dirección:
-
-
-
-
-
-
-
-
Codigo Postal:
-
-
-
-
-
-
-
-
-
RFC:
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
Teléfono Empresa:
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
- <%-- --%>
- <%-- --%>
-
-
-
-
-
-
Contacto:
-
-
-
-
-
-
-
-
Celular Contacto:
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
- <%--
- --%>
-
-
-
-
-
-
-
Clasificación Proveedor:
-
-
-
-
-
-
-
Responsable:
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
Tipo de Proveedor:
-
-
- <%----%>
+
+
+
+
+
+
+
+
+
+
-
-
-
-
Moneda Preferente:
-
-
-
-
-
-
Nivel de confianza al proveedor:
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
-
-
Regimen Fiscal:
-
-
-
-
+
-
-
-
-
+
Estatus SAT:
@@ -371,7 +396,9 @@
-
+
+
+
@@ -3629,67 +3656,97 @@
Cuenta Bancaria
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
<%----%>
-
+
+
-
+
+
+
+
-
+
+
+
+
+
-
+
+
-
+
+
diff --git a/Compras/Proveedores.aspx.vb b/Compras/Proveedores.aspx.vb
index fe3667f6a..b542189c3 100644
--- a/Compras/Proveedores.aspx.vb
+++ b/Compras/Proveedores.aspx.vb
@@ -506,6 +506,7 @@ Partial Class Compras_Proveedores
CargaAnticipos(CveProveedorSucursal)
CargaBancos(CveProveedorSucursal)
CargaProveedorSucursales()
+ CargaCuentasBancarias()
CargaOC()
CargaDocs()
@@ -632,12 +633,17 @@ Partial Class Compras_Proveedores
If UsuarioActual.Empresa.Funcionalidad(565) = "1" Then
TrConfianzaProveedor.Visible = True
+ CondiguraConfiazaProveedor()
End If
If UsuarioActual.TienePermisoProceso(273) Then
GvA.Columns(5).Visible = True
End If
+
+
+
+
End If
Dim script As String = String.Format("$({0}).removeClass({1});$({0}).removeClass({2}); $({0}).addClass({3});$({0}).text(""{4}"");", """#CXPContador""", """badge-success""", """badge-danger""", If(CountCuentasxPagar > 0, """badge-danger""", """badge-success"""), CountCuentasxPagar.ToString)
@@ -649,6 +655,19 @@ Partial Class Compras_Proveedores
RegisterPostBackControl()
End Sub
+ Private Sub CondiguraConfiazaProveedor()
+
+ '1 Dedicado
+ '2 Proveedor que requiere Cotización
+
+ If Not UsuarioActual.TienePermisoProceso(355) Then
+ If Not DdlConfianzaProveedor.SelectedValue.ToEntero = 1 Then
+ DdlConfianzaProveedor.Items.Remove(New ListItem("Proveedor dedicado", "1"))
+ End If
+ End If
+
+ End Sub
+
Private Sub CargaRegimenFiscal()
DdlRegimenFiscal.DataSource = GlobalDTRegimenesFiscales
DdlRegimenFiscal.DataBind()
@@ -1729,7 +1748,7 @@ Partial Class Compras_Proveedores
''Agregar Cuentas Bancarias
If TempDTCuentasBancos.Rows.Count > 0 Then
For Each row As DataRow In TempDTCuentasBancos.Rows
- If Not ObjCuentasDeposito.AddCuentasDepositos(row("BancoNombre").ToString, row("Plaza").ToString, row("Sucursal").ToString, row("Cuenta").ToString, row("CLABE").ToString, row("CIE").ToString, row("SWIFT").ToString, row("Referencia").ToString, row("RefCrediProveedor").ToString, UsuarioActual.CveUsuario, row("CveMoneda").ToString.ToEntero,
+ If Not ObjCuentasDeposito.AddCuentasDepositos(row("BancoNombre").ToString, row("Plaza").ToString, row("Sucursal").ToString, row("Cuenta").ToString, row("CLABE").ToString, row("CIE").ToString, row("SWIFT").ToString, row("Referencia").ToString, row("RefCrediProveedor").ToString, UsuarioActual.CveUsuario, row("CveMoneda").ToString.ToEntero, UsuarioActual.CveEmpresa,
CveProveedor:=NuevoCveProveedor, Correo:=row("Correo").ToString, BBVAAlias:=row("BBVAAlias").ToString,
EstatusPagoElectronico:=Boolean.Parse(row("EstatusPagoElectronico").ToString), EstatusPagoElectronicoGrupos:=Boolean.Parse(row("EstatusPagoElectronicoGrupos").ToString), CveSATBanco:=row("CveSATBanco").ToString.ToEntero) Then
ErrorBancos = True
@@ -3091,37 +3110,30 @@ Partial Class Compras_Proveedores
' CargaCuentasBancarias()
'End Sub
Private Sub CargaCuentasBancarias()
- Dim ObjCuentasBancos As New ClsGenerales
+
ViewState("OrdenCuentasBancos") = ""
DTCuentasBancos = New DataTable
TempDTCuentasBancos = New DataTable
- If ObjCuentasBancos.GetCuentasDepositos(CveProveedor) Then
- DTCuentasBancos.Merge(ObjCuentasBancos.DtResultados)
- Else
- Alert("No se pudieron cargar las cuentas bancarias. Por favor intente nuevamente.", TipoMensaje.MsgAdvertencia)
+ If CveProveedor > 0 Then
+ Dim ObjCuentasBancos As New ClsGenerales
+ If ObjCuentasBancos.GetCuentasDepositos(CveProveedor, CveEmpresa:=UsuarioActual.CveEmpresa) Then
+ DTCuentasBancos.Merge(ObjCuentasBancos.DtResultados)
+ Else
+ Alert("No se pudieron cargar las cuentas bancarias. Por favor intente nuevamente.", TipoMensaje.MsgAdvertencia)
+ End If
+ ObjCuentasBancos.Dispose()
End If
+
If CveProveedor < 0 Then
'Alert("No hay proveedor", TipoMensaje.MsgInformacion)
TempDTCuentasBancos = DTCuentasBancos.Clone
- 'Esconde columna estatus
- 'THEstatus.Visible = False
- 'THEstatusTexto.Visible = False
- 'GvBancosCuentas.Columns(11).Visible = False 'Es la columna estatus CheckBox
-
- 'Mexicanada para acomadar las columnas'
- 'TDEstatusLayout.Visible = False
- 'TDEstatusTexto.Visible = False
-
End If
- ObjCuentasBancos.Dispose()
CargaPSGridCuentasBancos(ViewState("OrdenCuentasBancos").ToString)
- RecargaGlobalCuentasBancarias()
-
End Sub
Protected Sub LbAgregarCuentaBanco_Click(sender As Object, e As EventArgs)
@@ -3213,21 +3225,22 @@ Partial Class Compras_Proveedores
CveMoneda As Integer, Moneda As String, Estatus As Boolean, Correo As String, BBVAAlias As String, EstatusPagoElectronico As Boolean, EstatusPagoElectronicoGrupos As Boolean, CveSATBanco As Integer,
ConceptoCIE As String)
- Dim ObjCuentasBancos As New ClsGenerales
+
If Modalidad = "A" Then
If CveProveedor > 0 Then
-
- If ObjCuentasBancos.AddCuentasDepositos(NombreBanco, Plaza, NumeroSucursal, NumeroCuenta, CLABE, ConvenioCIE, SWIFT, Referencia, RefCrediProveedor, UsuarioActual.CveUsuario, CveMoneda, CveProveedor:=CveProveedor,
+ Dim ObjCuentasBancos As New ClsGenerales
+ If ObjCuentasBancos.AddCuentasDepositos(NombreBanco, Plaza, NumeroSucursal, NumeroCuenta, CLABE, ConvenioCIE, SWIFT, Referencia, RefCrediProveedor, UsuarioActual.CveUsuario, CveMoneda, UsuarioActual.CveEmpresa, CveProveedor:=CveProveedor,
Correo:=Correo, BBVAAlias:=BBVAAlias, EstatusPagoElectronico:=EstatusPagoElectronico, EstatusPagoElectronicoGrupos:=EstatusPagoElectronicoGrupos, CveSATBanco:=CveSATBanco, ConceptoCIE:=ConceptoCIE) Then
DTCuentasBancos.Clear()
DTCuentasBancos.Merge(ObjCuentasBancos.DtResultados.FiltraParametros(String.Format("CveProveedor = {0}", CveProveedor)))
Alert("Cuenta Bancaria agregada con éxito.", TipoMensaje.MsgInformacion)
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivAddCuentasBancarias"))
+ CargaCuentasBancarias()
Else
Alert("Error al registrar la cuenta bancaria. Por favor intente nuevamente", TipoMensaje.MsgError)
End If
-
+ ObjCuentasBancos.Dispose()
Else
Dim Row As DataRow
Row = TempDTCuentasBancos.NewRow
@@ -3261,17 +3274,19 @@ Partial Class Compras_Proveedores
If CveProveedor > 0 Then
-
+ Dim ObjCuentasBancos As New ClsGenerales
If ObjCuentasBancos.UpdateCuentasDepositos(GvBancosCuentas.DataKeys(CveCuentaBancaria)("CveCuentaDeposito").ToString.ToEntero, NombreBanco, Plaza, NumeroSucursal, NumeroCuenta, CLABE, ConvenioCIE, SWIFT, Referencia, RefCrediProveedor,
- False, Estatus, CveMoneda, Correo:=Correo, BBVAAlias:=BBVAAlias, EstatusPagoElectronico:=EstatusPagoElectronico, EstatusPagoElectronicoGrupos:=EstatusPagoElectronicoGrupos, CveSATBanco:=CveSATBanco,
+ False, Estatus, CveMoneda, UsuarioActual.CveEmpresa, Correo:=Correo, BBVAAlias:=BBVAAlias, EstatusPagoElectronico:=EstatusPagoElectronico, EstatusPagoElectronicoGrupos:=EstatusPagoElectronicoGrupos, CveSATBanco:=CveSATBanco,
ConceptoCIE:=ConceptoCIE) Then
DTCuentasBancos.Clear()
DTCuentasBancos.Merge(ObjCuentasBancos.DtResultados.FiltraParametros(String.Format("CveProveedor = {0}", CveProveedor)))
Alert("Cuenta actualizada con éxito.", TipoMensaje.MsgInformacion)
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivAddCuentasBancarias"))
+ CargaCuentasBancarias()
Else
Alert("Error al actualizar la cuenta bancaria. Por favor intente nuevamente.", TipoMensaje.MsgError)
End If
+ ObjCuentasBancos.Dispose()
Else
@@ -3301,7 +3316,7 @@ Partial Class Compras_Proveedores
End If
End If
- ObjCuentasBancos.Dispose()
+
LimpiaCuentasBancarias()
CargaPSGridCuentasBancos(ViewState("OrdenCuentasBancos").ToString)
RecargaGlobalCuentasBancarias()
@@ -3387,166 +3402,12 @@ Partial Class Compras_Proveedores
End If
End Sub
- ''Protected Sub GvBancosCuentas_RowEditing(sender As Object, e As System.Web.UI.WebControls.GridViewEditEventArgs) Handles GvBancosCuentas.RowEditing
- '' Dim id As Integer = e.NewEditIndex
- '' GvBancosCuentas.EditIndex = id
- '' CargaPSGridCuentasBancos(ViewState("OrdenCuentasBancos").ToString)
-
- '' 'Dim x As String = GvBancosCuentas.SelectedRowStyle("EstatusPagoElectronico")
-
- '' 'If CBool(e.Row.DBCampo("EstatusPagoElectronico")) AndAlso e.Row.DBCampo("Referencia").ToString <> "" Then
-
- '' 'End If
-
- ''End Sub
- 'Protected Sub GvBancosCuentas_RowCancelingEdit(sender As Object, e As System.Web.UI.WebControls.GridViewCancelEditEventArgs) Handles GvBancosCuentas.RowCancelingEdit
- ' GvBancosCuentas.EditIndex = -1
- ' CargaPSGridCuentasBancos(ViewState("OrdenCuentasBancos").ToString)
- 'End Sub
- 'Protected Sub GvBancosCuentas_RowUpdating(sender As Object, e As System.Web.UI.WebControls.GridViewUpdateEventArgs) Handles GvBancosCuentas.RowUpdating
-
- ' Dim NombreBanco = GvBancosCuentas.Rows(e.RowIndex).FCTextBox("TxtNombreBanco").Text.Trim
- ' Dim NumeroSucursal = GvBancosCuentas.Rows(e.RowIndex).FCTextBox("TxtNumeroSucursal").Text.Trim
- ' Dim CLABE = GvBancosCuentas.Rows(e.RowIndex).FCTextBox("TxtCLABE").Text.Trim
- ' Dim SWIFT = GvBancosCuentas.Rows(e.RowIndex).FCTextBox("TxtSWIFT").Text.Trim
- ' Dim Plaza = GvBancosCuentas.Rows(e.RowIndex).FCTextBox("TxtPlaza").Text.Trim
- ' Dim NumeroCuenta = GvBancosCuentas.Rows(e.RowIndex).FCTextBox("TxtNumeroCuenta").Text.Trim
- ' Dim ConvenioCIE = GvBancosCuentas.Rows(e.RowIndex).FCTextBox("TxtConvenioCIE").Text.Trim
- ' Dim Referencia = GvBancosCuentas.Rows(e.RowIndex).FCTextBox("TxtReferencia").Text.Trim
- ' Dim RefCrediProveedor = GvBancosCuentas.Rows(e.RowIndex).FCTextBox("TxtRefCrediProveedor").Text.Trim
- ' Dim CveMoneda = GvBancosCuentas.Rows(e.RowIndex).FCDropDownList("DdlMoneda").SelectedValue.ToString.ToEntero
- ' Dim Moneda = GvBancosCuentas.Rows(e.RowIndex).FCDropDownList("DdlMoneda").SelectedItem.Text
- ' Dim Estatus = GvBancosCuentas.Rows(e.RowIndex).FCCheckBox("ChkEstatus").Checked
-
- ' Dim EsBancomer = False
-
- ' If NombreBanco.ToUpper.Contains("BBVA") Or NombreBanco.ToUpper.Contains("BANCOMER") Or (CLABE.Length = 18 AndAlso CLABE.Substring(0, 3) = "012") Then
- ' EsBancomer = True
- ' End If
-
- ' ''COMENTADO PARA PERMITIR ENTRADA DE UNA CUENTA A PROVEEDOR, 22 DE SEPTIEMBRE, ISRAEL PIÑA
- ' 'If EsBancomer AndAlso (CLABE.Length <> 18 AndAlso Not CLABE.Substring(0, 3) = "012") Then
- ' ' Alert("La CLABE ingresada no pertenece a BANCOMER.", TipoMensaje.MsgAdvertencia)
- ' ' Exit Sub
- ' 'End If
-
- ' ''CLABE SIEMPRE OBLIGATORIA CUANDO NO ES BANCOMER CON CIE
- ' 'If (CLABE.Trim.Length <> 18 And Not EsBancomer) Or (EsBancomer And ConvenioCIE.Trim.Length <> 6 And CLABE.Trim.Length <> 18) Then
- ' ' Alert("La CLABE es obligatoria y debe tener una longitud de 18 dígitos. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
- ' ' Exit Sub
- ' 'End If
-
- ' 'QUE TENGA ALGUN DATO DE TIPO DE CUENTA
- ' If NumeroCuenta.Length = 0 AndAlso CLABE.Length = 0 AndAlso SWIFT.Length = 0 AndAlso ConvenioCIE.Length = 0 Then
- ' Alert("Debe especificar al menos un numero de cuenta.", TipoMensaje.MsgAdvertencia)
- ' Exit Sub
- ' End If
-
- ' 'SI CLABE TIENE ALGO DEBE TENER UNA LOGITUD EXACTA DE 18
- ' If CLABE.Trim.Length <> 0 AndAlso CLABE.Trim.Length <> 18 Then
- ' Alert("La CLABE debe tener una longitud de 18 dígitos. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
- ' Exit Sub
- ' End If
-
- ' If UsuarioActual.CveEmpresa = 66 Then
- ' 'CLABE SIEMPRE OBLIGATORIA SI NO ES BANCOMER
- ' If CLABE.Trim.Length <> 18 And CLABE.Trim.Length = 0 And Not EsBancomer And SWIFT.Length = 0 Then
- ' Alert("La CLABE es obligatoria y debe tener una longitud de 18 dígitos. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
- ' Exit Sub
- ' End If
-
- ' 'SI CUENTA TIENE ALGO Y BANCO BANCOMER DEBE TENER UNA LOGITUD EXACTA DE 10
- ' If NumeroCuenta.Trim.Length <> 0 AndAlso NumeroCuenta.Trim.Length <> 10 AndAlso EsBancomer Then
- ' Alert("El número de cuenta debe tener una longitud de 10 dígitos. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
- ' Exit Sub
- ' End If
-
- ' 'SI CIE TIENE ALGO REFERENCIA OBLIGATORIA
- ' If ConvenioCIE.Trim.Length <> 0 And Referencia.Trim.Length < 3 Then
- ' Alert("Cuando se ingresa Convenio CIE se debe especificar una referencia. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
- ' Exit Sub
- ' End If
-
- ' 'CUANDO SEA "BBVA" O "BANCOMER" DEBE TENER "CIE" O "CUENTA"
- ' If EsBancomer AndAlso Not (NumeroCuenta.Trim.Length = 10 Or ConvenioCIE.Trim.Length <> 0) Then
- ' Alert("Para cuentas BBVA BANCOMER es obligatorio el Número de Cuenta o CIE.", TipoMensaje.MsgAdvertencia)
- ' Exit Sub
- ' End If
- ' Else
- ' 'SI CIE TIENE ALGO DEBE TENER UNA LOGITUD MINIMA DE 5
- ' If ConvenioCIE.Trim.Length <> 0 And ConvenioCIE.Trim.Length < 5 Then
- ' Alert("El Convenio CIE debe tener una longitud de al menos 5 dígitos. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
- ' Exit Sub
- ' End If
- ' End If
-
-
-
- ' Dim ObjCuentasBancos As New ClsGenerales
- ' If CveProveedor > 0 Then
- ' If ObjCuentasBancos.UpdateCuentasDepositos(GvBancosCuentas.DataKeys(e.RowIndex)("CveCuentaDeposito").ToString.ToEntero, NombreBanco, Plaza, NumeroSucursal, NumeroCuenta, CLABE, ConvenioCIE, SWIFT, Referencia, RefCrediProveedor, False, Estatus, CveMoneda) Then
- ' DTCuentasBancos.Clear()
- ' DTCuentasBancos.Merge(ObjCuentasBancos.DtResultados.FiltraParametros(String.Format("CveProveedor = {0}", CveProveedor)))
- ' Alert("Cuenta actualizada con éxito.", TipoMensaje.MsgInformacion)
- ' Else
- ' Alert("Error al actualizar la cuenta bancaria. Por favor intente nuevamente.", TipoMensaje.MsgError)
- ' End If
- ' Else
- ' Dim index = GvBancosCuentas.Rows(e.RowIndex).DataKey("CveCuentaDeposito").ToString.ToEntero - 1
- ' Dim Row As DataRow = TempDTCuentasBancos.Rows(index)
- ' Row("BancoNombre") = NombreBanco
- ' Row("Sucursal") = NumeroSucursal
- ' Row("CLABE") = CLABE
- ' Row("SWIFT") = SWIFT
- ' Row("Plaza") = Plaza
- ' Row("Cuenta") = NumeroCuenta
- ' Row("CIE") = ConvenioCIE
- ' Row("Referencia") = Referencia
- ' Row("RefCrediProveedor") = RefCrediProveedor
- ' Row("CveMoneda") = CveMoneda
- ' Row("Moneda") = Moneda
- ' Row("Estatus") = Estatus
- ' TempDTCuentasBancos.AcceptChanges()
- ' End If
-
- ' ObjCuentasBancos.Dispose()
-
- ' GvBancosCuentas.EditIndex = -1
- ' CargaPSGridCuentasBancos(ViewState("OrdenCuentasBancos").ToString)
- ' RecargaGlobalCuentasBancarias()
- 'End Sub
- 'Protected Sub GvBancosCuentas_RowDeleting(sender As Object, e As System.Web.UI.WebControls.GridViewDeleteEventArgs) Handles GvBancosCuentas.RowDeleting
- ' Dim ObjCuentasBancos As New ClsGenerales
-
- ' If CveProveedor > 0 Then
- ' If ObjCuentasBancos.RemoveCuentasDepositos(GvBancosCuentas.DataKeys(e.RowIndex)("CveCuentaDeposito").ToString.ToEntero) Then
- ' DTCuentasBancos.Clear()
- ' DTCuentasBancos.Merge(ObjCuentasBancos.DtResultados.FiltraParametros(String.Format("CveProveedor = {0}", CveProveedor)))
-
- ' Alert("Cuenta Bancaria borrada con éxito.", TipoMensaje.MsgInformacion)
- ' Else
- ' Alert("No se pudo borrar la Cuenta Bancaria. Por favor intente nuevamente.", TipoMensaje.MsgError)
- ' End If
- ' Else
- ' Dim index = GvBancosCuentas.Rows(e.RowIndex).DataKey("CveCuentaDeposito").ToString.ToEntero - 1
- ' TempDTCuentasBancos.Rows.RemoveAt(index)
- ' End If
-
- ' If ObjCuentasBancos.GetCuentasDepositos Then
- ' GlobalDTProveedoresCuentas(CveProveedor, True) = ObjCuentasBancos.DtResultados
- ' End If
-
- ' CargaPSGridCuentasBancos(ViewState("OrdenCuentasBancos").ToString)
- ' ObjCuentasBancos.Dispose()
- ' RecargaGlobalCuentasBancarias()
- 'End Sub
-
Public Sub Delete_Click(sender As Object, e As EventArgs)
Dim GvRow As GridViewRow = DirectCast(DirectCast(sender, LinkButton).NamingContainer, GridViewRow)
Dim ObjCuentasBancos As New ClsGenerales
If CveProveedor > 0 Then
- If ObjCuentasBancos.RemoveCuentasDepositos(GvRow.DataKey("CveCuentaDeposito").ToEntero) Then
+ If ObjCuentasBancos.RemoveCuentasDepositos(GvRow.DataKey("CveCuentaDeposito").ToEntero, UsuarioActual.CveEmpresa, UsuarioActual.CveUsuario) Then
DTCuentasBancos.Clear()
DTCuentasBancos.Merge(ObjCuentasBancos.DtResultados.FiltraParametros(String.Format("CveProveedor = {0}", CveProveedor)))
@@ -3567,12 +3428,7 @@ Partial Class Compras_Proveedores
Private Sub RecargaGlobalCuentasBancarias(Optional ByVal CveCuenta As Integer = -1)
If CveProveedor > 0 Then
GlobalDTProveedoresCuentas(UsuarioActual.CveEmpresa, -1) = Nothing
- 'Dim ObjCuentasBancos As New ClsGenerales
- 'If ObjCuentasBancos.GetCuentasDepositos() Then
- ' GlobalDTProveedoresCuentas(UsuarioActual.CveEmpresa, -1, True) = ObjCuentasBancos.DtResultados
- 'End If
- 'ObjCuentasBancos.Dispose()
End If
End Sub
@@ -6277,7 +6133,7 @@ Partial Class Compras_Proveedores
Protected Sub ChkPagoElectronico_CheckedChanged(sender As Object, e As EventArgs)
If ChkPagoElectronico.Checked Then
- Alert("Se está activando manualmente el pago por Layout BBVA. Recuerde que la alta se realiza directo en la platoforma", TipoMensaje.MsgAdvertencia)
+ Alert("Se está activando manualmente el pago por Layout BBVA. Recuerde que la alta se realiza directo en la plataforma", TipoMensaje.MsgAdvertencia)
End If
End Sub
diff --git a/Contabilidad/RegPrePolizaS.aspx.vb b/Contabilidad/RegPrePolizaS.aspx.vb
index d8eee866b..4b02bd7d4 100644
--- a/Contabilidad/RegPrePolizaS.aspx.vb
+++ b/Contabilidad/RegPrePolizaS.aspx.vb
@@ -1,6 +1,7 @@
Imports System.Data
Imports System.Net.NetworkInformation
+Imports ADSNetLibrary.SIGAPI.Models.OC.Response
'Imports DocumentFormat.OpenXml
Imports Extensiones
Imports GemBox.Spreadsheet
@@ -311,6 +312,7 @@ Partial Class ContabilidadC_RegPrePolizaS
+
Exit Sub
ElseIf Request("CvePrePolizaOrigen") IsNot Nothing AndAlso IsNumeric(Request("CvePrePolizaOrigen")) AndAlso Request("CvePrePolizaOrigen").ToEntero > 0 Then
@@ -2734,8 +2736,8 @@ Partial Class ContabilidadC_RegPrePolizaS
End If
-
End Sub
+
Private Sub ImprimirPolizaPDF(IdPoliza As Integer)
'Dim ObjPoliza As New ClsContPAQi(UsuarioActual.Empresa)
@@ -2787,12 +2789,6 @@ Partial Class ContabilidadC_RegPrePolizaS
End If
-
-
-
-
-
-
'Return String.Format("{0}\{1}\{2}.pdf", AppDomain.CurrentDomain.BaseDirectory, Tick, IdPoliza.ToString)
ObjConta.Dispose()
@@ -3246,8 +3242,6 @@ Partial Class ContabilidadC_RegPrePolizaS
Dim Logo As New System.IO.FileInfo(String.Format("{0}Logo.png", UsuarioActual.Empresa.Ruta))
-
-
Dim ObjConta As New ClsContabilidad
'If ObjPoliza.GetPoliza(IdPoliza, -1, -1, -1, -1) AndAlso ObjPoliza.DtResultados.Rows.Count > 0 Then
If ObjConta.GetPrePolizasDetalleResumen(CvePrePoliza, UsuarioActual.CveEmpresa, ImpresionPersonalizada) AndAlso ObjConta.DtResultados.Rows.Count > 0 Then
@@ -3327,5 +3321,6 @@ Partial Class ContabilidadC_RegPrePolizaS
'End Sub
+
End Class
diff --git a/Contabilidad/RepIVA.aspx.cs b/Contabilidad/RepIVA.aspx.cs
index b3f6be587..4c8bbe71f 100644
--- a/Contabilidad/RepIVA.aspx.cs
+++ b/Contabilidad/RepIVA.aspx.cs
@@ -201,17 +201,17 @@ public partial class Contabilidad_RepIVA : ClsPaginas
if (GvT.Rows.Count > 0 || GvA.Rows.Count > 0)
{
System.IO.FileInfo Imagen;
- String logouri = "";
+ // String logouri = "";
if (UsuarioActual.CveEmpresa.Contiene(119))
{
Imagen = new System.IO.FileInfo(String.Format("{0}/Logo.jpg", UsuarioActual.Empresa.Ruta));
- logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.jpg", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa);
+ //logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.jpg", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa);
}
else
{
Imagen = new System.IO.FileInfo($"{UsuarioActual.Empresa.Ruta}/Logo.png");
- logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.png", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa);
+ //logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.png", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa);
}
List para = new List();
@@ -220,7 +220,7 @@ public partial class Contabilidad_RepIVA : ClsPaginas
para.Add(new CrystalParametro("Filtros", $"Filtros: {FechaI}{FechaF}{TipoMov}"));
if (Imagen.Exists)
{
- para.Add(new CrystalParametro("LogoPath", logouri));
+ para.Add(new CrystalParametro("LogoPath", Imagen.FullName));
}
else
{
diff --git a/Contabilidad2/RepBalanzaComprobacion.aspx b/Contabilidad2/RepBalanzaComprobacion.aspx
index 91061853e..faff6a40a 100644
--- a/Contabilidad2/RepBalanzaComprobacion.aspx
+++ b/Contabilidad2/RepBalanzaComprobacion.aspx
@@ -76,10 +76,16 @@
-
-
-
-
+
+ Proyecto:
+
+
+
+
+
+ SubProyecto:
+
+
diff --git a/Contabilidad2/RepBalanzaComprobacion.aspx.vb b/Contabilidad2/RepBalanzaComprobacion.aspx.vb
index dd4ae56f2..d21e100cb 100644
--- a/Contabilidad2/RepBalanzaComprobacion.aspx.vb
+++ b/Contabilidad2/RepBalanzaComprobacion.aspx.vb
@@ -1,6 +1,7 @@
Option Explicit On
Option Strict On
+Imports System
Imports System.Data
Imports Extensiones
Imports Microsoft.Reporting.WebForms
@@ -53,6 +54,23 @@ Partial Class Contabilidad2_RepBalanzaComprobacion
End Set
End Property
+ Private Property CveProyecto As Integer
+ Get
+ CveProyecto = ViewState("CveProyecto").ToString.ToEntero
+ End Get
+ Set(value As Integer)
+ ViewState("CveProyecto") = value
+ End Set
+ End Property
+ Private Property CveSubProyecto As Integer
+ Get
+ CveSubProyecto = ViewState("CveSubProyecto").ToString.ToEntero
+ End Get
+ Set(value As Integer)
+ ViewState("CveSubProyecto") = value
+ End Set
+ End Property
+
#End Region
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
@@ -85,23 +103,27 @@ Partial Class Contabilidad2_RepBalanzaComprobacion
If Not ErrorParametros Then
CargaDatos()
End If
- Else
- DdlSubproyecto.DataSource = GlobalDTSubProyectos(-1, -1, UsuarioActual.CveEmpresa, -1)
- DdlSubproyecto.DataBind()
+ CargarCentrosDeCosto(DdlProyecto, DdlSubproyecto, LblProyecto, LblSubProyecto)
End If
End Sub
+ Protected Sub DdlProyecto_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlProyecto.SelectedIndexChanged
+ CargarSubProyecto(DdlSubproyecto, DdlProyecto.SelectedValue, "Todos")
+ End Sub
+
#Region "CARGA DATOS Y GRID"
Private Sub CargaDatos()
' Dim ObjConta As New ClsContPAQi(UsuarioActual.Empresa)
Dim ObjConta As New ClsContabilidad
- Dim CveSubProyecto As String = DdlSubproyecto.SelectedValue.ToString
+
+ CveSubProyecto = DdlSubproyecto.SelectedValue.ToEntero.ToEntero
+ CveProyecto = DdlProyecto.SelectedValue.ToEntero.ToEntero
Dim TipoReporte = DdlTipoReporte.SelectedValue.ToEntero
- If ObjConta.GetBalanzaComprobacion(FechaInicio, FechaFin, DdlTipoCuentas.SelectedValue.ToEntero, TipoReporte, CveSubProyecto, UsuarioActual.CveEmpresa, 0, DdlNivel.SelectedValue.ToEntero) Then
+ If ObjConta.GetBalanzaComprobacion(FechaInicio, FechaFin, DdlTipoCuentas.SelectedValue.ToEntero, TipoReporte, CveProyecto, CveSubProyecto, UsuarioActual.CveEmpresa, 0, DdlNivel.SelectedValue.ToEntero) Then
DtDatos = ObjConta.DtResultados
@@ -170,7 +192,7 @@ Partial Class Contabilidad2_RepBalanzaComprobacion
e.Row.FCLabel("LbSaldoActual").Visible = True
e.Row.FCLabel("LbSaldoActual").Text = String.Format("{0} {1}", e.Row.DBCampo("SaldoAD").FormatoNumero, e.Row.DBCampo("SaldoAA").FormatoNumero)
Else
- If ModoImpresion Then e.Row.Cells(5).Text = e.Row.FCHyperLink("HLSaldoActual").Text Else e.Row.FCHyperLink("HLSaldoActual").NavigateUrl = String.Format("/Contabilidad2/RepMovimientosAuxiliaresCatalogo.aspx?CveCuenta={0}&FI={1}&FF={2}", e.Row.DBCampo("ID"), FechaInicio.ToShortDateString, FechaFin.ToShortDateString)
+ If ModoImpresion Then e.Row.Cells(5).Text = e.Row.FCHyperLink("HLSaldoActual").Text Else e.Row.FCHyperLink("HLSaldoActual").NavigateUrl = String.Format("/Contabilidad2/RepMovimientosAuxiliaresCatalogo.aspx?CveCuenta={0}&FI={1}&FF={2}&CveProyecto={3}&CveSubProyecto={4}", e.Row.DBCampo("ID"), FechaInicio.ToShortDateString, FechaFin.ToShortDateString, CveProyecto, CveSubProyecto)
End If
End If
End Sub
diff --git a/Contabilidad2/RepEstadoResultadosHorizontal.aspx b/Contabilidad2/RepEstadoResultadosHorizontal.aspx
index 30ee612d3..2062aebd0 100644
--- a/Contabilidad2/RepEstadoResultadosHorizontal.aspx
+++ b/Contabilidad2/RepEstadoResultadosHorizontal.aspx
@@ -1,4 +1,4 @@
-<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepEstadoResultadosHorizontal.aspx.vb" Inherits="Contabilidad_RepEstadoResultadosHorizontal" EnableEventValidation="false" %>
+<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepEstadoResultadosHorizontal.aspx.vb" Inherits="Contabilidad_RepEstadoResultadosHorizontal" EnableEventValidation="false" %>
@@ -9,11 +9,12 @@
width: 100%;
height: 500px;
}
- #chartdivgral{
+
+ #chartdivgral {
width: 100%;
min-height: 500px;
-
}
+
.fa.fa-bar-chart {
width: 16px;
height: 14px;
@@ -39,8 +40,8 @@
visibility: inherit;
}
- .table>tbody>tr>td{
- vertical-align:bottom;
+ .table > tbody > tr > td {
+ vertical-align: bottom;
}
@@ -68,7 +69,7 @@