From 87f727d4b8e1399b7703e60b4b30d4c0b21fa62a Mon Sep 17 00:00:00 2001 From: rrene Date: Wed, 28 Jun 2023 08:21:37 -0700 Subject: [PATCH 01/31] =?UTF-8?q?--=20que=20entre=20a=20la=20p=C3=A1gina?= =?UTF-8?q?=20provisionalmente=20sin=20importar=20el=20tipo=20conta?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Contabilidad2/RepAnexoCatalogo.aspx.vb | 6 +++--- Contabilidad2/RepMovimientosAuxiliaresCatalogo.aspx.vb | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Contabilidad2/RepAnexoCatalogo.aspx.vb b/Contabilidad2/RepAnexoCatalogo.aspx.vb index 8d064fb20..b22362481 100644 --- a/Contabilidad2/RepAnexoCatalogo.aspx.vb +++ b/Contabilidad2/RepAnexoCatalogo.aspx.vb @@ -82,9 +82,9 @@ Partial Class AC2_RepAnexoCatalogo Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load If Not Page.IsPostBack Then - If UsuarioActual.Empresa.TipoContabilidad = 2 AndAlso UsuarioActual.CveEmpresa <> 119 Then - Response.Redirect($"/Contabilidad/RepAnexoCatalogo.aspx") - End If + 'If UsuarioActual.Empresa.TipoContabilidad = 2 AndAlso UsuarioActual.CveEmpresa <> 119 Then + ' Response.Redirect($"/Contabilidad/RepAnexoCatalogo.aspx") + 'End If Dim ErrorParametros = True DtDatos = Nothing diff --git a/Contabilidad2/RepMovimientosAuxiliaresCatalogo.aspx.vb b/Contabilidad2/RepMovimientosAuxiliaresCatalogo.aspx.vb index 8ad1afab7..f5a336676 100644 --- a/Contabilidad2/RepMovimientosAuxiliaresCatalogo.aspx.vb +++ b/Contabilidad2/RepMovimientosAuxiliaresCatalogo.aspx.vb @@ -97,9 +97,9 @@ Partial Class Conta_RepMovimientosAuxiliaresCatalogo Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load If Not Page.IsPostBack Then - If UsuarioActual.Empresa.TipoContabilidad = 2 AndAlso UsuarioActual.CveEmpresa <> 119 Then - Response.Redirect($"/Contabilidad/RepMovimientosAuxiliaresCatalogo.aspx") - End If + 'If UsuarioActual.Empresa.TipoContabilidad = 2 AndAlso UsuarioActual.CveEmpresa <> 119 Then + ' Response.Redirect($"/Contabilidad/RepMovimientosAuxiliaresCatalogo.aspx") + 'End If Dim ErrorParametros = True From 6880840885ef6823fa11888c9097e9a0485ab8fa Mon Sep 17 00:00:00 2001 From: rrene Date: Thu, 29 Jun 2023 10:25:13 -0700 Subject: [PATCH 02/31] -- cambio en nombre. del archivo de descarga de universo de productos. -- cambio de texto Varras a Barras --- Inventarios/InventarioFisicoDetalle.aspx | 6 +++--- Inventarios/InventarioFisicoDetalle.aspx.vb | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Inventarios/InventarioFisicoDetalle.aspx b/Inventarios/InventarioFisicoDetalle.aspx index b5d900cdb..53d938d26 100644 --- a/Inventarios/InventarioFisicoDetalle.aspx +++ b/Inventarios/InventarioFisicoDetalle.aspx @@ -208,7 +208,7 @@
- +
@@ -223,10 +223,10 @@
- +
- +
diff --git a/Inventarios/InventarioFisicoDetalle.aspx.vb b/Inventarios/InventarioFisicoDetalle.aspx.vb index 0848c497a..6bee3fa74 100644 --- a/Inventarios/InventarioFisicoDetalle.aspx.vb +++ b/Inventarios/InventarioFisicoDetalle.aspx.vb @@ -687,13 +687,13 @@ Partial Class Inventarios_InventarioFisicoDetalle worksheet.Columns(i).AutoFit(1, worksheet.Rows(0), worksheet.Rows(worksheet.Rows.Count - 1)) Next - NombreArchivo = "Productos" + NombreArchivo = "Productos-" + lbTitulo.Text workbook.Save(Response, $"{NombreArchivo}.xlsx", SaveOptions.XlsxDefault) End Sub #End Region - Protected Sub BtnBuscarCodVarras_Click(sender As Object, e As EventArgs) - Dim CodigoBarras As String = If(TxtConCodigoVarras.Text.Trim <> "", TxtConCodigoVarras.Text.Trim, "-1").Replace("'", "''") + Protected Sub BtnBuscarCodBarras_Click(sender As Object, e As EventArgs) + Dim CodigoBarras As String = If(TxtConCodigoBarras.Text.Trim <> "", TxtConCodigoBarras.Text.Trim, "-1").Replace("'", "''") LblContador.Text = "No se encontraron resultados" Using Inventarios As New ClsInventarios If Inventarios.GetInventarioFisicoContador(CveInventarioFisico, ddlUsuario.SelectedValue.ToString.ToEntero, CodigoBarras) Then From 7af32f0769aee412c65f4cb371bbeeb6482a6d9f Mon Sep 17 00:00:00 2001 From: Oscar Irigoyen Date: Thu, 29 Jun 2023 15:39:50 -0700 Subject: [PATCH 03/31] custom js 20 megas drop zone --- RH/CatTurno.aspx | 92 ++++++++++++++++++++++++++++------------------- Scripts/custom.js | 2 +- 2 files changed, 56 insertions(+), 38 deletions(-) diff --git a/RH/CatTurno.aspx b/RH/CatTurno.aspx index 7ce26474e..48e358b47 100644 --- a/RH/CatTurno.aspx +++ b/RH/CatTurno.aspx @@ -74,7 +74,7 @@ - + @@ -112,49 +112,67 @@
-
- - - - - - - -
-
- - - - - - - + + +
+
+
+ + + + + + + +
+
+
+
+ + + + + + + +
+
- + + +
-
- - - - - - - -
+ + +
+
+
+ + + + + + + +
+
+
+
+ + + + + + + +
+
+
-
- - - - - - - -
diff --git a/Scripts/custom.js b/Scripts/custom.js index 53b314349..d14dfa838 100644 --- a/Scripts/custom.js +++ b/Scripts/custom.js @@ -1099,7 +1099,7 @@ function ADDropzone(txtid) { var urldown = txt.data('urldown'); if ((urldown) && (urldown != "")) { } else { urldown = domain + "/Ashx/SIGWeb.ashx"; } var urlget = txt.data('urlget'); if ((urlget) && (urlget != "")) { } else { urlget = domain + "/temp/"; } - var maxFilesize = txt.data('maxfilesize'); if (maxFilesize) { } else { maxFilesize = 10; } + var maxFilesize = txt.data('maxfilesize'); if (maxFilesize) { } else { maxFilesize = 20; } var maxFile = txt.attr('data-maxFile'); if (maxFile) { } else { maxFile = null; } var mydiv = $("
"); var mypaste = $("
") From 48edc7963a1787a7c39bf586e6a90b3c18cf0824 Mon Sep 17 00:00:00 2001 From: Jonathan Alexis Perez Morales Date: Thu, 29 Jun 2023 16:52:56 -0700 Subject: [PATCH 04/31] --Correcion en proceso de cancelacion de compras --- Compras/Compras.aspx.vb | 320 ++++++++++++++++++++-------------------- 1 file changed, 162 insertions(+), 158 deletions(-) diff --git a/Compras/Compras.aspx.vb b/Compras/Compras.aspx.vb index 0478b39c0..35bab8940 100644 --- a/Compras/Compras.aspx.vb +++ b/Compras/Compras.aspx.vb @@ -6613,9 +6613,6 @@ Partial Class Compras_Compras Concepto = $"{NombreProveedor} {TxtSerie.Text} - {TxtFolio.Text}" - If Not ObjCompras.UpdateEstatusAlmacen(CveCompra, 2, UsuarioActual.CveUsuario) Then - ErrorMovInv = True - End If If importeMovimiento > 0 Or TxtTotal.Text.ToDecimal = 0 Then RegistroCuentaPuente = True @@ -13692,74 +13689,11 @@ Partial Class Compras_Compras End If End If ObjComprasComprobacion.Dispose() - Dim cvemovimientoentrada As Integer = -1 - - - 'DEVOLUCIÓN AUTOMATICA - If CheckDevAuto.Checked Then - Dim ErrorMovInv As Boolean = False - - Dim folio As Integer - Dim fecha As Date = TxtFechaCancelacion.Text.ToDate - Dim importeconcepto As Decimal - Dim ObjInventario As New ClsInventarios - Dim ObjCompra As New ClsCompras - Dim tbmovs As DataTable = Nothing - Dim TmpDT As DataTable = Nothing - Dim TipoCambioGuardar As Decimal = 1 - Dim tcvealmacen As Integer = 0 - - If ObjCompra.GetCompraDetalle(CveCompra, UsuarioActual.CveEmpresa) Then - If ObjCompra.DtResultados.Rows.Count > 0 Then - TmpDT = ObjCompra.DtResultados - End If - End If - - If ObjInventario.GetInv_ComprasMov(CveCompra, UsuarioActual.CveEmpresa) Then - If ObjInventario.DtResultados.Rows.Count > 0 Then - tbmovs = ObjInventario.DtResultados - End If - End If - - If DdlMoneda.SelectedValue.ToEntero > 1 Then - TipoCambioGuardar = If(DivTC.Visible, TxtTC.Text.ToDecimal, LblTC.Text.Substring(3).ToDecimal) - End If - TipoCambio = If(DivTC.Visible, TipoCambioGuardar, TipoCambio) - - For Each dtMovs As DataRow In TmpDT.Rows - If TmpDT.Rows.Count > 0 Then - tcvealmacen = dtMovs("AlmacenRegistrado").ToString.ToEntero - Exit For - End If - Next - - folio = ObjInventario.GetFolioSiguiente(13, UsuarioActual.CveEmpresa) - cvemovimientoentrada = ObjInventario.AddMovimiento(tcvealmacen, 13, 1, fecha, folio, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveCompra, -1, -1, -1, TipoCambio:=If(DdlMoneda.SelectedValue.ToEntero = 1, -1, TipoCambioGuardar), Modulo:="Devolucion Automatica") - If cvemovimientoentrada <= 0 Then - ErrorMovInv = True - Else - For Each dr As DataRow In tbmovs.Rows - If dr("cvealmacen").ToString.ToEntero = tcvealmacen And dr("CveCompraDetalle").ToString.ToEntero <> -1 And dr("origen").ToString.ToEntero <> -1 And dr("Total").ToString.ToDecimal <> 0 Then - 'hay que restarle descuento - importeconcepto = dr("Total").ToString.ToDecimal - If Not ObjInventario.AddMovimientoDetalle(cvemovimientoentrada, dr("cantidad").ToString.ToDouble, dr("cveum").ToString.ToEntero, dr("cveps").ToString.ToEntero, importeconcepto, -1, CveCompraDetalle:=dr("CveCompraDetalle").ToString.ToEntero, Serie:=dr("Serie").ToString) Then - ErrorMovInv = True - Exit Sub - End If - End If - Next - - End If - - If ErrorMovInv = True Then - ObjInventario.RollBack() - End If - ObjInventario.Dispose() - ObjCompra.Dispose() - End If - + Dim ObjCompras As New ClsCompras + Dim ObjContabilidad As New ClsContabilidad(ObjCompras.IniciaTransacSQL()) + Dim ObjInventario As New ClsInventarios(ObjCompras.IniciaTransacSQL()) Dim ObjAC As ClsContPAQi = Nothing If (UsuarioActual.Empresa.UsaAC Or UsuarioActual.Empresa.Funcionalidad(200).ToString = "1") AndAlso UsuarioActual.Empresa.TipoContabilidad = 2 Then @@ -13767,21 +13701,128 @@ Partial Class Compras_Compras ObjAC.IniciaTransacSQL() End If - Dim ObjCompras As New ClsCompras - Dim ObjContabilidad As New ClsContabilidad(ObjCompras.IniciaTransacSQL()) - Dim ErrorCancelar = False Dim IdPolizaNueva = -1 Dim FolioPolizaNueva = -1 Dim CvePrePolizaNueva = -1 - Dim dt As DataTable + + Try + + 'DEVOLUCIÓN AUTOMATICA + If CheckDevAuto.Checked Then + + Dim fecha As Date = TxtFechaCancelacion.Text.ToDateTime().AddHours(23).AddMinutes(59) + Dim importeconcepto As Decimal + + Dim tbmovs As DataTable = Nothing + Dim TmpDT As DataTable = Nothing + Dim TipoCambioGuardar As Decimal = 1 - ' MES ANTERIOR, MOVIMIENTOS CONTRARIOS (NEGATIVOS) - If True Then + If ObjCompras.GetCompraDetalle(CveCompra, UsuarioActual.CveEmpresa) Then + If ObjCompras.DtResultados.Rows.Count > 0 Then + TmpDT = ObjCompras.DtResultados.Copy() + End If + End If + If ObjInventario.GetInv_ComprasMov(CveCompra, UsuarioActual.CveEmpresa) Then + If ObjInventario.DtResultados.Rows.Count > 0 Then + tbmovs = ObjInventario.DtResultados + End If + End If + + If DdlMoneda.SelectedValue.ToEntero > 1 Then + TipoCambioGuardar = If(DivTC.Visible, TxtTC.Text.ToDecimal, LblTC.Text.Substring(3).ToDecimal) + End If + TipoCambio = If(DivTC.Visible, TipoCambioGuardar, TipoCambio) + + 'For Each dtMovs As DataRow In TmpDT.Rows + ' If TmpDT.Rows.Count > 0 Then + ' tcvealmacen = dtMovs("AlmacenRegistrado").ToString.ToEntero + ' Exit For + ' End If + 'Next + + Dim DtMovimientos = tbmovs.FiltraParametros("Origen = 1", DistinctColumns:={"CveMovimiento", "CveConcepto", "CveAlmacen", "Origen"}) + + For Each RowMovto As DataRow In DtMovimientos.Rows + + Dim CveMovimientoEntrada As Integer = -1 + + Dim Folio As Integer + Dim CveAlmacen As Integer = RowMovto("CveAlmacen").ToString().ToEntero() + Dim CveConceptoDevolucion As Integer = -1 + Dim CveConcetoEntrada = RowMovto("CveConcepto").ToString().ToEntero() + Dim CveMovimientoReferencia As Integer = RowMovto("CveMovimiento").ToString().ToEntero() + + Select Case CveConcetoEntrada + Case 2 + CveConceptoDevolucion = 13 + End Select + + Folio = ObjInventario.GetFolioSiguiente(CveConceptoDevolucion, UsuarioActual.CveEmpresa) + CveMovimientoEntrada = ObjInventario.AddMovimiento(CveAlmacen, CveConceptoDevolucion, 1, fecha, Folio, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveCompra, -1, -1, -1, TipoCambio:=If(DdlMoneda.SelectedValue.ToEntero = 1, -1, TipoCambioGuardar), Modulo:="Devolucion Automatica") + + If CveMovimientoEntrada <= 0 Then + ErrorCancelar = True + Exit For + Else + For Each dr As DataRow In tbmovs.Rows + If dr("CveAlmacen").ToString.ToEntero = CveAlmacen And dr("CveCompraDetalle").ToString.ToEntero <> -1 And dr("origen").ToString.ToEntero <> -1 And dr("Total").ToString.ToDecimal <> 0 Then + 'hay que restarle descuento + importeconcepto = dr("Total").ToString.ToDecimal + If Not ObjInventario.AddMovimientoDetalle(CveMovimientoEntrada, dr("Cantidad").ToString.ToDouble, dr("CveUM").ToString.ToEntero, dr("CvePS").ToString.ToEntero, importeconcepto, -1, CveCompraDetalle:=dr("CveCompraDetalle").ToString.ToEntero, Serie:=dr("Serie").ToString) Then + ErrorCancelar = True + Exit For + End If + End If + Next + + End If + + If CvePrePoliza > 0 Then + Dim Total68 As Decimal = 0 + If ObjInventario.GetMovimientosDetalle(CveMovimientoEntrada, UsuarioActual.CveEmpresa) Then + Total68 = ObjInventario.DtResultados.SUMD("Total").RoundSQL(2) * -1 + End If + + If ObjContabilidad.GetPrePolizasDetalle(CvePrePoliza, UsuarioActual.CveEmpresa) Then + Dim DtPrePolizaAlmacen = ObjContabilidad.DtResultados.FiltraParametros($"CveMovimientoAlmacen = {CveMovimientoReferencia}") + + CvePrePolizaNueva = ObjContabilidad.AddPrePolizas("Compras/Cancelar", DtPrePolizaAlmacen.Rows(0)("CvePlantillaPoliza").ToString.ToEntero, DtPrePolizaAlmacen.Rows(0)("Cargos").ToString.ToDouble * -1, DtPrePolizaAlmacen.Rows(0)("Abonos").ToString.ToDouble * -1, DtPrePolizaAlmacen.Rows(0)("CveMoneda").ToString.ToEntero, TxtFechaCancelacion.Text.ToDate, String.Format("Cancelación: {0}", DtPrePolizaAlmacen.Rows(0)("Concepto").ToString), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) + + If CvePrePolizaNueva > 0 Then + For Each dr As DataRow In DtPrePolizaAlmacen.Rows + If Not ObjContabilidad.AddPrePolizasDetalle(CvePrePolizaNueva, CBool(dr("TipoMovto").ToString), Total68, dr("Referencia").ToString, dr("CveConceptoContable").ToString.ToEntero, + dr("Concepto").ToString, TxtFechaCancelacion.Text.ToDate, dr("IdCtaContable").ToString.ToEntero, dr("IdSegmentoNegocio").ToString.ToEntero, dr("CveIE").ToString.ToEntero, + dr("CveVenta").ToString.ToEntero, dr("CveCompra").ToString.ToEntero, dr("CveSubProyecto").ToString.ToEntero, dr("CveCliente").ToString.ToEntero, dr("CveProveedor").ToString.ToEntero, dr("CvePersonal").ToString.ToEntero, + CveMovimientoEntrada, + dr("CveActivoFijo").ToString.ToEntero, -1, -1, dr("CveCreditoDetalle").ToString.ToEntero, + ImporteMX:=Total68, ImporteME:=Total68, + CveTipoGasto:=dr("CveTipoGasto").ToString.ToEntero, CveClasificacion:=dr("CveClasificacion").ToString.ToEntero, + PorcentajeImpuesto:=dr("PorcentajeImpuesto").ToString.ToDecimal, + CveOCDetalle:=dr("CveOCDetalle").ToString.ToEntero) Then + ErrorCancelar = True + Exit For + End If + Next + Else + ErrorCancelar = True + End If + Else + ErrorCancelar = True + End If + End If + + Next + + End If + + Dim dt As DataTable + + ' MOVIMIENTOS CONTRARIOS (NEGATIVOS) 'CREA POLIZA NEGATIVA - If IdPoliza > 0 AndAlso ObjAC IsNot Nothing AndAlso UsuarioActual.Empresa.UsaAC Then + If Not ErrorCancelar AndAlso IdPoliza > 0 AndAlso ObjAC IsNot Nothing AndAlso UsuarioActual.Empresa.UsaAC Then If ObjAC.GetPoliza(IdPoliza, -1, -1, -1, -1) AndAlso ObjAC.DtResultados.Rows.Count > 0 Then dt = ObjAC.DtResultados @@ -13809,47 +13850,21 @@ Partial Class Compras_Compras End If 'CREA PRE-POLIZA NEGATIVA - If DdlTipoComprobante.SelectedValue.Contiene("NC") Then - If ObjCompras.GetCancelarNC(CveCompra, UsuarioActual.CveEmpresa) Then - dt = ObjCompras.DtResultados - - CvePrePolizaNueva = ObjContabilidad.AddPrePolizas("Compras/Cancelar", dt.Rows(0)("CvePlantillaPoliza").ToString.ToEntero, dt.Rows(0)("Cargos").ToString.ToDouble * -1, dt.Rows(0)("Abonos").ToString.ToDouble * -1, dt.Rows(0)("CveMoneda").ToString.ToEntero, TxtFechaCancelacion.Text.ToDate, String.Format("Cancelación: {0}", dt.Rows(0)("Concepto").ToString), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) - If CvePrePolizaNueva > 0 Then - For Each dr As DataRow In dt.Rows - If Not ObjContabilidad.AddPrePolizasDetalle(CvePrePolizaNueva, CBool(dr("TipoMovto").ToString), dr("Importe").ToString.ToDecimal * -1, dr("Referencia").ToString, dr("CveConceptoContable").ToString.ToEntero, - dr("Concepto").ToString, TxtFechaCancelacion.Text.ToDate, dr("IdCtaContable").ToString.ToEntero, dr("IdSegmentoNegocio").ToString.ToEntero, dr("CveIE").ToString.ToEntero, - dr("CveVenta").ToString.ToEntero, dr("CveCompra").ToString.ToEntero, dr("CveSubProyecto").ToString.ToEntero, dr("CveCliente").ToString.ToEntero, dr("CveProveedor").ToString.ToEntero, dr("CvePersonal").ToString.ToEntero, - dr("CveMovimientoAlmacen").ToString.ToEntero, dr("CveActivoFijo").ToString.ToEntero, -1, -1, dr("CveCreditoDetalle").ToString.ToEntero, - ImporteMX:=dr("Importe").ToString.ToDecimal * -1, ImporteME:=dr("Importe").ToString.ToDecimal * -1, CveTipoGasto:=dr("CveTipoGasto").ToString.ToEntero, CveClasificacion:=dr("CveClasificacion").ToString.ToEntero, - PorcentajeImpuesto:=dr("PorcentajeImpuesto").ToString.ToDecimal, CveOCDetalle:=dr("CveOCDetalle").ToString.ToEntero, - CveCompraAmortizacion:=dr("CveCompraAmortizacion").ToString.ToEntero) Then - ErrorCancelar = True - Exit For - End If - Next - Else - ErrorCancelar = True - End If - Else - ErrorCancelar = True - End If - Else - If CvePrePoliza > 0 Then - If ObjContabilidad.GetPrePolizasDetalle(CvePrePoliza, UsuarioActual.CveEmpresa) Then - dt = ObjContabilidad.DtResultados + If Not ErrorCancelar Then + If DdlTipoComprobante.SelectedValue.Contiene("NC") Then + If ObjCompras.GetCancelarNC(CveCompra, UsuarioActual.CveEmpresa) Then + dt = ObjCompras.DtResultados CvePrePolizaNueva = ObjContabilidad.AddPrePolizas("Compras/Cancelar", dt.Rows(0)("CvePlantillaPoliza").ToString.ToEntero, dt.Rows(0)("Cargos").ToString.ToDouble * -1, dt.Rows(0)("Abonos").ToString.ToDouble * -1, dt.Rows(0)("CveMoneda").ToString.ToEntero, TxtFechaCancelacion.Text.ToDate, String.Format("Cancelación: {0}", dt.Rows(0)("Concepto").ToString), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) If CvePrePolizaNueva > 0 Then For Each dr As DataRow In dt.Rows If Not ObjContabilidad.AddPrePolizasDetalle(CvePrePolizaNueva, CBool(dr("TipoMovto").ToString), dr("Importe").ToString.ToDecimal * -1, dr("Referencia").ToString, dr("CveConceptoContable").ToString.ToEntero, - dr("Concepto").ToString, TxtFechaCancelacion.Text.ToDate, dr("IdCtaContable").ToString.ToEntero, dr("IdSegmentoNegocio").ToString.ToEntero, dr("CveIE").ToString.ToEntero, - dr("CveVenta").ToString.ToEntero, dr("CveCompra").ToString.ToEntero, dr("CveSubProyecto").ToString.ToEntero, dr("CveCliente").ToString.ToEntero, dr("CveProveedor").ToString.ToEntero, dr("CvePersonal").ToString.ToEntero, - If(cvemovimientoentrada > 0, cvemovimientoentrada, dr("CveMovimientoAlmacen").ToString.ToEntero), - dr("CveActivoFijo").ToString.ToEntero, -1, -1, dr("CveCreditoDetalle").ToString.ToEntero, - ImporteMX:=dr("Importe").ToString.ToDecimal * -1, ImporteME:=dr("Importe").ToString.ToDecimal * -1, - CveTipoGasto:=dr("CveTipoGasto").ToString.ToEntero, CveClasificacion:=dr("CveClasificacion").ToString.ToEntero, - PorcentajeImpuesto:=dr("PorcentajeImpuesto").ToString.ToDecimal, - CveOCDetalle:=dr("CveOCDetalle").ToString.ToEntero) Then + dr("Concepto").ToString, TxtFechaCancelacion.Text.ToDate, dr("IdCtaContable").ToString.ToEntero, dr("IdSegmentoNegocio").ToString.ToEntero, dr("CveIE").ToString.ToEntero, + dr("CveVenta").ToString.ToEntero, dr("CveCompra").ToString.ToEntero, dr("CveSubProyecto").ToString.ToEntero, dr("CveCliente").ToString.ToEntero, dr("CveProveedor").ToString.ToEntero, dr("CvePersonal").ToString.ToEntero, + dr("CveMovimientoAlmacen").ToString.ToEntero, dr("CveActivoFijo").ToString.ToEntero, -1, -1, dr("CveCreditoDetalle").ToString.ToEntero, + ImporteMX:=dr("Importe").ToString.ToDecimal * -1, ImporteME:=dr("Importe").ToString.ToDecimal * -1, CveTipoGasto:=dr("CveTipoGasto").ToString.ToEntero, CveClasificacion:=dr("CveClasificacion").ToString.ToEntero, + PorcentajeImpuesto:=dr("PorcentajeImpuesto").ToString.ToDecimal, CveOCDetalle:=dr("CveOCDetalle").ToString.ToEntero, + CveCompraAmortizacion:=dr("CveCompraAmortizacion").ToString.ToEntero) Then ErrorCancelar = True Exit For End If @@ -13860,64 +13875,53 @@ Partial Class Compras_Compras Else ErrorCancelar = True End If - End If - End If + Else + If CvePrePoliza > 0 Then + If ObjContabilidad.GetPrePolizasDetalle(CvePrePoliza, UsuarioActual.CveEmpresa) Then + dt = ObjContabilidad.DtResultados.FiltraParametros("ISNULL(CveMovimientoAlmacen,0) <=0") - 'MES ACTUAL - Else - - 'LIMPIA POLIZA PONIENDO IMPORTE EN CEROS - If IdPoliza > 0 AndAlso ObjAC IsNot Nothing Then - If ObjAC.GetPoliza(IdPoliza, -1, -1, -1, -1) AndAlso ObjAC.DtResultados.Rows.Count > 0 Then - dt = ObjAC.DtResultados - - For Each dr As DataRow In dt.Rows - If Not ObjAC.UpdateMovimiento(dr("Id").ToString.ToEntero, dr("IdCuenta").ToString.ToEntero, dr("TipoMovto").ToString = "1", 0, dr("Referencia").ToString, dr("Concepto").ToString, dr("IdSegNeg").ToString.ToEntero, dr("Fecha").ToString.ToDate) Then - ErrorCancelar = True : Exit For - End If - Next - - 'AJUSTA POLIZA - If Not ErrorCancelar Then - If Not ObjAC.AjustaPoliza(IdPoliza) Then + CvePrePolizaNueva = ObjContabilidad.AddPrePolizas("Compras/Cancelar", dt.Rows(0)("CvePlantillaPoliza").ToString.ToEntero, dt.Rows(0)("Cargos").ToString.ToDouble * -1, dt.Rows(0)("Abonos").ToString.ToDouble * -1, dt.Rows(0)("CveMoneda").ToString.ToEntero, TxtFechaCancelacion.Text.ToDate, String.Format("Cancelación: {0}", dt.Rows(0)("Concepto").ToString), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) + If CvePrePolizaNueva > 0 Then + For Each dr As DataRow In dt.Rows + If Not ObjContabilidad.AddPrePolizasDetalle(CvePrePolizaNueva, CBool(dr("TipoMovto").ToString), dr("Importe").ToString.ToDecimal * -1, dr("Referencia").ToString, dr("CveConceptoContable").ToString.ToEntero, + dr("Concepto").ToString, TxtFechaCancelacion.Text.ToDate, dr("IdCtaContable").ToString.ToEntero, dr("IdSegmentoNegocio").ToString.ToEntero, dr("CveIE").ToString.ToEntero, + dr("CveVenta").ToString.ToEntero, dr("CveCompra").ToString.ToEntero, dr("CveSubProyecto").ToString.ToEntero, dr("CveCliente").ToString.ToEntero, dr("CveProveedor").ToString.ToEntero, dr("CvePersonal").ToString.ToEntero, + dr("CveMovimientoAlmacen").ToString.ToEntero, + dr("CveActivoFijo").ToString.ToEntero, -1, -1, dr("CveCreditoDetalle").ToString.ToEntero, + ImporteMX:=dr("Importe").ToString.ToDecimal * -1, ImporteME:=dr("Importe").ToString.ToDecimal * -1, + CveTipoGasto:=dr("CveTipoGasto").ToString.ToEntero, CveClasificacion:=dr("CveClasificacion").ToString.ToEntero, + PorcentajeImpuesto:=dr("PorcentajeImpuesto").ToString.ToDecimal, + CveOCDetalle:=dr("CveOCDetalle").ToString.ToEntero) Then + ErrorCancelar = True + Exit For + End If + Next + Else + ErrorCancelar = True + End If + Else ErrorCancelar = True End If End If + End If + End If - Else + If Not ErrorCancelar Then + If Not ObjCompras.CancelarCompraOC(CveCompra, UsuarioActual.CveEmpresa) Then ErrorCancelar = True End If End If - 'LIMPIA PRE-POLIZA PONIENDO IMPORTE EN CEROS - If CvePrePoliza > 0 Then - If ObjContabilidad.GetPrePolizasDetalle(CvePrePoliza, UsuarioActual.CveEmpresa) Then - dt = ObjContabilidad.DtResultados - - For Each dr As DataRow In dt.Rows - If Not ObjContabilidad.UpdatePrePolizasDetalle(dr("CvePrePolizaDetalle").ToString.ToEntero, dr("Concepto").ToString, dr("CveSubProyecto").ToString.ToEntero, dr("IdCtaContable").ToString.ToEntero, CBool(dr("TipoMovto").ToString), 0, CveUsuarioModifico:=UsuarioActual.CveUsuario) Then - ErrorCancelar = True : Exit For - End If - Next - Else + 'CANCELA COMPRA + If Not ErrorCancelar Then + If Not ObjCompras.UpdateEstatusCompra(CveCompra, -2) Then ErrorCancelar = True End If End If - - End If - - If Not ErrorCancelar Then - If Not ObjCompras.CancelarCompraOC(CveCompra, UsuarioActual.CveEmpresa) Then - ErrorCancelar = True - End If - End If - - 'CANCELA COMPRA - If Not ErrorCancelar Then - If Not ObjCompras.UpdateEstatusCompra(CveCompra, -2) Then - ErrorCancelar = True - End If - End If + Catch ex As Exception + OnError("Ocurrió un error al cancelar la compra", ex) + ErrorCancelar = True + End Try If Not ErrorCancelar Then If ObjAC IsNot Nothing Then From fae78953b2a07da355609e647fd18ec15a70decc Mon Sep 17 00:00:00 2001 From: rrene Date: Fri, 30 Jun 2023 08:56:36 -0700 Subject: [PATCH 05/31] -- mejora --- Bancos/RepEgresosSinComprobante.aspx | 20 ++-- Bancos/RepEgresosSinComprobante.aspx.vb | 122 +++++++++++++----------- 2 files changed, 74 insertions(+), 68 deletions(-) diff --git a/Bancos/RepEgresosSinComprobante.aspx b/Bancos/RepEgresosSinComprobante.aspx index 7091a53bf..ba7f21cbb 100644 --- a/Bancos/RepEgresosSinComprobante.aspx +++ b/Bancos/RepEgresosSinComprobante.aspx @@ -153,9 +153,9 @@ - + - + @@ -166,32 +166,28 @@ - - + - - + - + - - + - - + @@ -199,7 +195,7 @@ - + diff --git a/Bancos/RepEgresosSinComprobante.aspx.vb b/Bancos/RepEgresosSinComprobante.aspx.vb index 4b23ae67d..f09a2051b 100644 --- a/Bancos/RepEgresosSinComprobante.aspx.vb +++ b/Bancos/RepEgresosSinComprobante.aspx.vb @@ -202,76 +202,86 @@ Partial Class Bancos_RepEgresosSinComprobante 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 - Dim IdCtaContable As Integer = 0 - Dim TipoMovtoOtIngresos As Boolean = False - Dim TipoMovtoConcepto As Boolean = True - Dim CveConceptoContable As Integer - - Select Case gr.DataKey("CveConceptoContable").ToEntero - Case 10 - CveConceptoContable = 21 - Case 28 - CveConceptoContable = 29 - TipoMovtoOtIngresos = False - TipoMovtoConcepto = True - Case 37 - CveConceptoContable = 43 - Case 42 - CveConceptoContable = 41 - Case 43 - CveConceptoContable = 37 - End Select - - If ObjProveedor.GetProveedores(ClsCompProveedores.TipoConsulta.ParaUsoEnEmpresa, gr.DataKey("CveProveedor").ToEntero, "-1", "-1", "-1", "-1", "-1", "-1", "-1", -1, UsuarioActual.CveEmpresa) Then - If ObjProveedor.DtResultados.Rows.Count > 0 Then - IdCtaContable = ObjProveedor.IdCtaContProveedores - End If - End If - - CvePrePoliza = ObjConta.AddPrePolizas("Bancos/RepEgresosSinComprobante", 6, gr.DataKey("Saldo").ToDecimal, gr.DataKey("Saldo").ToDecimal, gr.DataKey("CveMoneda").ToEntero, Now, - "Saldo de ExC por Sistema", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) - - If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoConcepto, gr.DataKey("Saldo").ToDecimal, "", CveConceptoContable, "Saldo de ExC por Sistema", Now, IdCtaContable, -1, - gr.DataKey("CveIE").ToEntero, CveProveedor:=gr.DataKey("CveProveedor").ToEntero, CvePersonal:=gr.DataKey("CvePersonal").ToEntero, - ImporteMX:=gr.DataKey("Saldo").ToDecimal, Contabilizable:=EsContabilizable) Then - MsgError = "Ocurrio un error al saldar el movimiento" - Exit For - End If - - If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoOtIngresos, gr.DataKey("Saldo").ToDecimal, "", 78, "Saldo de ExC por Sistema", Now, UsuarioActual.Empresa.IdCuentaOtrosIngresos, -1, gr.DataKey("CveIE").ToEntero, - ImporteMX:=gr.DataKey("Saldo").ToDecimal, CveSubProyecto:=gr.DataKey("CveSubProyecto").ToEntero, Contabilizable:=EsContabilizable) Then - MsgError = "Ocurrio un error al saldar el movimiento" - Exit For - End If - - If UsuarioActual.Empresa.Funcionalidad(200) = "1" Then - If Not ObjConta.ContabilizarPrePoliza(CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.Empresa) Then - Alert("Ocurrio un Error al contabilizar, pongase en contacto con Soporte Técnico", TipoMensaje.MsgError) - End If - End If - + 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) + + For Each gr As GridViewRow In GvESC.Rows + If gr.FCCheckBox("Chk").Checked Then + Dim IdCtaContable As Integer = 0 + Dim TipoMovtoOtIngresos As Boolean = False + Dim TipoMovtoConcepto As Boolean = True + Dim CveConceptoContable As Integer + + Select Case gr.DataKey("CveConceptoContable").ToEntero + Case 10 + CveConceptoContable = 21 + Case 28 + CveConceptoContable = 29 + TipoMovtoOtIngresos = False + TipoMovtoConcepto = True + Case 37 + CveConceptoContable = 43 + Case 42 + CveConceptoContable = 41 + Case 43 + CveConceptoContable = 37 + Case 48 + CveConceptoContable = 56 + End Select + + If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoConcepto, gr.DataKey("Saldo").ToDecimal, gr.DataKey("Folio"), CveConceptoContable, "Saldo de ExC por Sistema", Now, IdCtaContable, -1, + gr.DataKey("CveIE").ToEntero, CveProveedor:=gr.DataKey("CveProveedor").ToEntero, CvePersonal:=gr.DataKey("CvePersonal").ToEntero, + ImporteMX:=gr.DataKey("Saldo").ToDecimal, Contabilizable:=EsContabilizable) Then + MsgError = "Ocurrio un error al saldar el movimiento" + Exit For + End If + + If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoOtIngresos, gr.DataKey("Saldo").ToDecimal, gr.DataKey("Folio"), 211, "Saldo de ExC por Sistema", Now, UsuarioActual.Empresa.IdCuentaOtrosIngresos, -1, gr.DataKey("CveIE").ToEntero, + ImporteMX:=gr.DataKey("Saldo").ToDecimal, CveSubProyecto:=gr.DataKey("CveSubProyecto").ToEntero, Contabilizable:=EsContabilizable) Then + MsgError = "Ocurrio un error al saldar el movimiento" + Exit For + End If + + If UsuarioActual.Empresa.Funcionalidad(200) = "1" Then + If Not ObjConta.ContabilizarPrePoliza(CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.Empresa) Then + Alert("Ocurrio un Error al contabilizar, pongase en contacto con Soporte Técnico", TipoMensaje.MsgError) + End If + End If + + End If + Next + Else + Alert("No se especificaron") + End If + Catch ex As Exception MsgError = "Ocurrió un error al generar la prepoliza" OnError(MsgError, ex) End Try - If MsgError = "" Then + If MsgError = "" Then + LnkSaldar.Visible = False + LnkHabilitarSaldar.Visible = True ObjConta.Commit() - CargaDatos() - Alert("Los movimientos se saldaron correctamente.") + CargaDatos() + Alert(String.Format("Los movimientos se saldaron correctamente
Ver Póliza", CvePrePoliza), TipoMensaje.MsgInformacion) + Else ObjConta.RollBack() Alert(MsgError, TipoMensaje.MsgError) - End If - - LnkSaldar.Visible = False - LnkHabilitarSaldar.Visible = True - + End If + + + ObjConta.Dispose() ObjProveedor.Dispose() End Sub From 86c96c004bbae25196284a54e551f4415e332ecc Mon Sep 17 00:00:00 2001 From: rrene Date: Fri, 30 Jun 2023 08:58:37 -0700 Subject: [PATCH 06/31] -- mejora en 8.5 prorrateo sobre la compra registrada --- Compras/Compras.aspx.vb | 194 +++++++++++++++++++++------------------- 1 file changed, 101 insertions(+), 93 deletions(-) diff --git a/Compras/Compras.aspx.vb b/Compras/Compras.aspx.vb index 0478b39c0..05492ee06 100644 --- a/Compras/Compras.aspx.vb +++ b/Compras/Compras.aspx.vb @@ -6618,112 +6618,112 @@ Partial Class Compras_Compras End If If importeMovimiento > 0 Or TxtTotal.Text.ToDecimal = 0 Then - RegistroCuentaPuente = True - Dim ImporteTransito As Decimal = 0 - 'SI ES GASTO DE ALMACEN NO DEBE CONTABILIZAR CONCEPTO 68 - If DdlTipoCompra.SelectedValue = "10" AndAlso ConceptoContabilizacionNC = 68 Then - SeContabiliza = False - IdCtaContable = 0 - End If - 'se lleva saldo de Mercancía en tránsito - If ChkNCInvNC.Checked Then - For Each Gvr As GridViewRow In GVNCInv.Rows - If Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDouble > 0 Then - If Not ObjCompras.ComprasDetalleDevolucionesAdd(Gvr.DataKey("CveCompraDetalle").ToEntero, CveCompra, Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDouble, UsuarioActual.CveEmpresa) Then - ErrorMovInv = True - Exit For - End If - End If - Next - Dim diferenciaTransito As Decimal = 0 - For Each Gvr As GridViewRow In GVNCInvAlmacen.Rows - If Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDouble > 0 Then - Dim importeMNTemp As Decimal = 0 - If Not ObjCompras.ComprasDetalleDevolucionesAdd(Gvr.DataKey("CveCompraDetalle").ToEntero, CveCompra, Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDouble, UsuarioActual.CveEmpresa) Then - ErrorMovInv = True - Exit For - End If - Dim DifTC As Decimal = tipoCambioActual - Gvr.DataKey("TipoCambio").ToDecimal - 'diferenciaTransito = DifTC * (Gvr.DataKey("IVA").ToDecimal / Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDecimal) - 'diferenciaTransito += DifTC * (Gvr.DataKey("IEPSPS").ToDecimal / Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDecimal) - importeMNTemp = (Gvr.FCTextBox("TxtPU").Text.ToDecimal * Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDecimal * Gvr.DataKey("TipoCambio").ToDecimal).RoundSQL - ImporteTransito += importeMNTemp - 'se registra por cada compra relacionada - If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMNTemp, Referencia, ConceptoContabilizacionNC, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveCompraAmortizacion:=Gvr.DataKey("CveCompra").ToEntero, CveProveedor:=CveProveedorConcepto, ImporteMX:=importeMNTemp, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=Gvr.DataKey("TipoCambio").ToDecimal, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza) Then - ErrorPrepoliza = True - End If - End If - Next - 'la diferencia se va aplicar sobre los - - 'Dim diferenciaTransito As Decimal = ImporteTransito - importeMN.RoundSQL - - If diferenciaTransito <> 0 Then - Dim tCveCon As Integer = 65 - If diferenciaTransito < 0 Then - tCveCon = 64 - End If - diferenciaTransito = Math.Abs(diferenciaTransito) - - If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, If(tCveCon = 64, True, False), diferenciaTransito, Referencia, tCveCon, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=diferenciaTransito, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=1, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza, CveSubProyecto:=CveSubProyecto) Then - ErrorPrepoliza = True - End If + RegistroCuentaPuente = True + Dim ImporteTransito As Decimal = 0 + 'SI ES GASTO DE ALMACEN NO DEBE CONTABILIZAR CONCEPTO 68 + If DdlTipoCompra.SelectedValue = "10" AndAlso ConceptoContabilizacionNC = 68 Then + SeContabiliza = False + IdCtaContable = 0 End If - Else - Dim DiferenciaDevolucion As Decimal = importeMovimiento - TotalRealDevolucion - If TotalRealDevolucion <> 0 Then - - If Math.Abs(DiferenciaDevolucion) > 0 Then - Dim tMovto As Boolean = False - If UsuarioActual.CveEmpresa = 119 Then - tMovto = True - Else - DiferenciaDevolucion = -DiferenciaDevolucion + 'se lleva saldo de Mercancía en tránsito + If ChkNCInvNC.Checked Then + For Each Gvr As GridViewRow In GVNCInv.Rows + If Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDouble > 0 Then + If Not ObjCompras.ComprasDetalleDevolucionesAdd(Gvr.DataKey("CveCompraDetalle").ToEntero, CveCompra, Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDouble, UsuarioActual.CveEmpresa) Then + ErrorMovInv = True + Exit For + End If End If - If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, tMovto, DiferenciaDevolucion.RoundSQL(), Referencia, 69, Concepto, FechaMovimiento, -1, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=DiferenciaDevolucion, ImporteME:=If(tipoCambioActual = 1, 0, DiferenciaDevolucion), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza, CveSubProyecto:=tCveSubProyecto, CveClasificacion:=tCveClasif) Then + Next + Dim diferenciaTransito As Decimal = 0 + For Each Gvr As GridViewRow In GVNCInvAlmacen.Rows + If Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDouble > 0 Then + Dim importeMNTemp As Decimal = 0 + If Not ObjCompras.ComprasDetalleDevolucionesAdd(Gvr.DataKey("CveCompraDetalle").ToEntero, CveCompra, Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDouble, UsuarioActual.CveEmpresa) Then + ErrorMovInv = True + Exit For + End If + Dim DifTC As Decimal = tipoCambioActual - Gvr.DataKey("TipoCambio").ToDecimal + 'diferenciaTransito = DifTC * (Gvr.DataKey("IVA").ToDecimal / Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDecimal) + 'diferenciaTransito += DifTC * (Gvr.DataKey("IEPSPS").ToDecimal / Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDecimal) + importeMNTemp = (Gvr.FCTextBox("TxtPU").Text.ToDecimal * Gvr.FCTextBox("TxtCantidadNCInv").Text.ToDecimal * Gvr.DataKey("TipoCambio").ToDecimal).RoundSQL + ImporteTransito += importeMNTemp + 'se registra por cada compra relacionada + If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMNTemp, Referencia, ConceptoContabilizacionNC, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveCompraAmortizacion:=Gvr.DataKey("CveCompra").ToEntero, CveProveedor:=CveProveedorConcepto, ImporteMX:=importeMNTemp, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=Gvr.DataKey("TipoCambio").ToDecimal, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza) Then + ErrorPrepoliza = True + End If + End If + Next + 'la diferencia se va aplicar sobre los + + 'Dim diferenciaTransito As Decimal = ImporteTransito - importeMN.RoundSQL + + If diferenciaTransito <> 0 Then + Dim tCveCon As Integer = 65 + If diferenciaTransito < 0 Then + tCveCon = 64 + End If + diferenciaTransito = Math.Abs(diferenciaTransito) + + If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, If(tCveCon = 64, True, False), diferenciaTransito, Referencia, tCveCon, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=diferenciaTransito, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=1, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza, CveSubProyecto:=CveSubProyecto) Then ErrorPrepoliza = True End If End If - If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, TotalRealDevolucion.RoundSQL(), Referencia, ConceptoContabilizacionNC, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=(TotalRealDevolucion * tipoCambioActual).RoundSQL(), ImporteME:=If(tipoCambioActual = 1, 0, TotalRealDevolucion).RoundSQL(), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza) Then - ErrorPrepoliza = True - End If Else - If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMovimiento.RoundSQL, Referencia, ConceptoContabilizacionNC, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=importeMovimiento * tipoCambioActual * Multiplicador, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, CveClasificacion:=tCveClasif, CveSubProyecto:=tCveSubProyecto, Contabilizable:=SeContabiliza) Then + Dim DiferenciaDevolucion As Decimal = importeMovimiento - TotalRealDevolucion + If TotalRealDevolucion <> 0 Then + + If Math.Abs(DiferenciaDevolucion) > 0 Then + Dim tMovto As Boolean = False + If UsuarioActual.CveEmpresa = 119 Then + tMovto = True + Else + DiferenciaDevolucion = -DiferenciaDevolucion + End If + If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, tMovto, DiferenciaDevolucion.RoundSQL(), Referencia, 69, Concepto, FechaMovimiento, -1, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=DiferenciaDevolucion, ImporteME:=If(tipoCambioActual = 1, 0, DiferenciaDevolucion), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza, CveSubProyecto:=tCveSubProyecto, CveClasificacion:=tCveClasif) Then + ErrorPrepoliza = True + End If + End If + If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, TotalRealDevolucion.RoundSQL(), Referencia, ConceptoContabilizacionNC, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=(TotalRealDevolucion * tipoCambioActual).RoundSQL(), ImporteME:=If(tipoCambioActual = 1, 0, TotalRealDevolucion).RoundSQL(), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza) Then + ErrorPrepoliza = True + End If + Else + If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMovimiento.RoundSQL, Referencia, ConceptoContabilizacionNC, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=importeMovimiento * tipoCambioActual * Multiplicador, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, CveClasificacion:=tCveClasif, CveSubProyecto:=tCveSubProyecto, Contabilizable:=SeContabiliza) Then + ErrorPrepoliza = True + End If + End If + End If + End If + + If UsuarioActual.CveEmpresa.Contiene(119) Then + Dim ContienePSNeteoBonif As Boolean = False + For Each Dr As DataRow In TmpDT.Rows + If Dr("CveClasificacion").ToString.ToEntero.Contiene(20319) Or DdlTipoCompra.SelectedValue.Contiene("11") Then 'clasificación de Bonificación, no se incluirá en el neteo + ContienePSNeteoBonif = True + Exit For + End If + Next + + If ContienePSNeteoBonif Then + importeMovimiento = TmpDT.SUM(If(ListaDocumentos IsNot Nothing AndAlso ListaDocumentos.Count > 0 AndAlso ArrAnticipos IsNot Nothing AndAlso ArrAnticipos.Count > 0 AndAlso TxtTotal.Text.ToDecimal = 0, "ImporteSinImpuestos", "Total"), $"ISNULL(TipoAF,0) <> 2 And ISNULL(CveAlmacen,0) = 0 And ISNULL(AplicaCostoIndirecto,0) <> 1 AND CveClasificacion = 20319 ").ToString.ToDecimal + importeMN = importeMovimiento * tipoCambioActual * Multiplicador + Dim IdCtaContableDescCompra As Integer = UsuarioActual.Empresa.Funcionalidad(405).ToEntero + Dim CveSubProyecto259 As Integer = TmpDT.MAX("CveSubProyecto").ToEntero + + If ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, importeMovimiento, Referencia, 259, Concepto, FechaMovimiento, IdCtaContableDescCompra, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=importeMN, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza, CveSubProyecto:=CveSubProyecto259) Then + If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, -importeMovimiento, Referencia, 259, Concepto, FechaMovimiento, IdCtaContableDescCompra, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=-importeMN, ImporteME:=If(tipoCambioActual = 1, 0, -importeMovimiento), TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza, CveSubProyecto:=CveSubProyecto259) Then + ErrorPrepoliza = True + End If + Else ErrorPrepoliza = True End If End If End If End If - If UsuarioActual.CveEmpresa.Contiene(119) Then - Dim ContienePSNeteoBonif As Boolean = False - For Each Dr As DataRow In TmpDT.Rows - If Dr("CveClasificacion").ToString.ToEntero.Contiene(20319) Or DdlTipoCompra.SelectedValue.Contiene("11") Then 'clasificación de Bonificación, no se incluirá en el neteo - ContienePSNeteoBonif = True - Exit For - End If - Next + 'ChkNCInvNC - If ContienePSNeteoBonif Then - importeMovimiento = TmpDT.SUM(If(ListaDocumentos IsNot Nothing AndAlso ListaDocumentos.Count > 0 AndAlso ArrAnticipos IsNot Nothing AndAlso ArrAnticipos.Count > 0 AndAlso TxtTotal.Text.ToDecimal = 0, "ImporteSinImpuestos", "Total"), $"ISNULL(TipoAF,0) <> 2 And ISNULL(CveAlmacen,0) = 0 And ISNULL(AplicaCostoIndirecto,0) <> 1 AND CveClasificacion = 20319 ").ToString.ToDecimal - importeMN = importeMovimiento * tipoCambioActual * Multiplicador - Dim IdCtaContableDescCompra As Integer = UsuarioActual.Empresa.Funcionalidad(405).ToEntero - Dim CveSubProyecto259 As Integer = TmpDT.MAX("CveSubProyecto").ToEntero - - If ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, importeMovimiento, Referencia, 259, Concepto, FechaMovimiento, IdCtaContableDescCompra, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=importeMN, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza, CveSubProyecto:=CveSubProyecto259) Then - If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, -importeMovimiento, Referencia, 259, Concepto, FechaMovimiento, IdCtaContableDescCompra, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=-importeMN, ImporteME:=If(tipoCambioActual = 1, 0, -importeMovimiento), TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza, CveSubProyecto:=CveSubProyecto259) Then - ErrorPrepoliza = True - End If - Else - ErrorPrepoliza = True - End If - End If - End If - End If - - 'ChkNCInvNC - - If Not RegistroCuentaPuente AndAlso Not ChkNCInvNC.Checked Then + If Not RegistroCuentaPuente AndAlso Not ChkNCInvNC.Checked Then 'GASTO If UsuarioActual.CveEmpresa = 119 Then DT = TmpDT @@ -20451,6 +20451,7 @@ Partial Class Compras_Compras nRowAgrupado("PS") = psPSCodigo nRowAgrupado("CveClasificacion") = psCveClasificacion nRowAgrupado("Clasificacion") = psClasificacion + nRowAgrupado("CveTipoPS") = rowPS("CveTipoPS").ToString nRowAgrupado("IVAPorcentaje") = drIva("IVAPorcentaje") nRowAgrupado("RetIVAPorcentaje") = drIva("RetIVAPorcentaje") @@ -20514,6 +20515,7 @@ Partial Class Compras_Compras dRow91_5("PS") = psPSCodigo dRow91_5("CveClasificacion") = psCveClasificacion dRow91_5("Clasificacion") = psClasificacion + dRow91_5("CveTipoPS") = rowPS("CveTipoPS").ToString dRow91_5("Consec") = Consec + 1 dRow91_5("PU") = dRow91_5("PU").ToString.ToDecimal * Mul91_5 @@ -20535,6 +20537,12 @@ Partial Class Compras_Compras Consec = Consec + 2 Next DTProtateo.AcceptChanges() + 'recorrer + If CveCompra > 0 Then + For Each dbrow As DataRow In TmpDT.Rows + ClavesBorradas.Add(dbrow("CveCompraDetalle").ToString.ToEntero) + Next + End If TmpDT = DTProtateo BtnProrateoDeducible.Visible = False From f12bd82e947c566fbe79ad2dce3c34f6846e2358 Mon Sep 17 00:00:00 2001 From: Oscar Irigoyen Date: Fri, 30 Jun 2023 09:00:57 -0700 Subject: [PATCH 07/31] Cat turnos , Flujodiario.rdlc --- Empresas/Grales/Formatos/FlujoDiario.rdlc | 4412 +++++++++++---------- RH/CatTurno.aspx | 93 +- RH/CatTurno.aspx.vb | 23 +- 3 files changed, 2316 insertions(+), 2212 deletions(-) diff --git a/Empresas/Grales/Formatos/FlujoDiario.rdlc b/Empresas/Grales/Formatos/FlujoDiario.rdlc index 8e619396e..b1ea1c69a 100644 --- a/Empresas/Grales/Formatos/FlujoDiario.rdlc +++ b/Empresas/Grales/Formatos/FlujoDiario.rdlc @@ -1,2207 +1,5 @@  - - - - - - - - 10.07247cm - - - 3.4525cm - - - 3.69063cm - - - - - 0.6cm - - - - - true - true - - - - - SALDOS INICIALES EN BANCOS - - - - - - - - 1pt - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - Pesos - - - - - - - Textbox6 - - - - - 1pt - - - - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - Dólares - - - - - - - Textbox13 - - - - - 1pt - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - 0.49417cm - - - - - true - true - - - - - =Fields!Banco.Value - - - - - - - - 1pt - - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =IIF(Fields!Moneda.Value = "Pesos", Fields!Saldo.Value, "") - - - - - - - Saldo - - - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =IIF(Fields!Moneda.Value = "Dólares", Fields!Saldo.Value, "") - - - - - - - Saldo1 - - - - - 1pt - - 2pt - 2pt - 2pt - 2pt - - - - - - - - 0.6cm - - - - - true - true - - - - - SALDOS - - - - - - - - 1pt - - - - 1pt - - - - 1pt - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =Fields!Saldo.Value - - - - - - - Saldo2 - - - - - 1pt - - - - 1pt - - - - 1pt - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =SUM(IIF(Fields!Moneda.Value = "Dólares" AND Fields!CveCuenta.Value = "-1", CDbl(Fields!Saldo.Value), 0)) - - - - - - - Saldo3 - - - - - 1pt - - - - 1pt - - - - 1pt - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - - - - - - - - - - - - After - - - - - =IIF(Fields!Banco.Value = "", TRUE,FALSE) - - - - Before - - - - DataSet1 - 0.17639cm - 0.08599cm - 1.69417cm - 17.21559cm - - - - - - - - - 10.07247cm - - - 3.47235cm - - - 3.71048cm - - - - - 0.6cm - - - - - true - true - - - - - INGRESOS DEL DIA - - - - - - - - 1pt - - - - 1pt - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - Pesos - - - - - - - Textbox22 - - - - - 1pt - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - Dólares - - - - - - - Textbox23 - - - - - 1pt - - - - 1pt - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - 0.52062cm - - - - - true - true - - - - - =Fields!PagueseA.Value - - - - - - - - 1pt - - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Pesos", Fields!Importe.Value, "") - - - - - - - Saldo - - - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Dólares", Fields!Importe.Value, "") - - - - - - - Importe - - - - - 1pt - - 2pt - 2pt - 2pt - 2pt - - - - - - - - 0.6cm - - - - - true - true - - - - - TOTAL INGRESOS - - - - - - - - 1pt - - - - 1pt - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =SUM(IIF(Fields!Moneda.Value = "Pesos", CDbl(Fields!Importe.Value), 0)) - - - - - - - Textbox25 - - - - - 1pt - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =SUM(IIF(Fields!Moneda.Value = "Dólares", CDbl(Fields!Importe.Value), 0)) - - - - - - - Textbox26 - - - - - 1pt - - - - 1pt - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - - - - - - - - - - - - After - - - - - - Before - - - - DataSet2 - 2.08222cm - 0.08599cm - 1.72062cm - 17.25529cm - 1 - - - - - - - - - 10.09232cm - - - 3.4525cm - - - 3.71048cm - - - - - 0.6cm - - - - - true - true - - - - - GASTOS DEL DÍA - - - - - - - - 1pt - - - 1pt - - - 1pt - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - Pesos - - - - - - - Textbox6 - - - - - 1pt - - - 1pt - - - - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - Dólares - - - - - - - Textbox13 - - - - - 1pt - - - 1pt - - - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - 0.49417cm - - - - - true - true - - - - - =Fields!PagueseA.Value - - - - - - - - 1pt - - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Pesos", Fields!Importe.Value, "") - - - - - - - Saldo - - - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Dólares", Fields!Importe.Value, "") - - - - - - - Saldo1 - - - - - - 2pt - 2pt - 2pt - 2pt - - - - - - - - 0.6cm - - - - - true - true - - - - - TOTAL GASTOS - - - - - - - 1pt - - - 1pt - - - 1pt - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =SUM(IIF(Fields!Moneda.Value = "Pesos", CDbl(Fields!Importe.Value), 0)) - - - - - - - Saldo2 - - - - - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =SUM(IIF(Fields!Moneda.Value = "Dólares", CDbl(Fields!Importe.Value), 0)) - - - - - - - Saldo3 - - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - - - - - - - - - - - - After - - - - - - Before - - - - DataSet3 - 4.05351cm - 0.06614cm - 1.69417cm - 17.25529cm - 2 - - - - - - - - - 10.09232cm - - - 3.43265cm - - - 3.69063cm - - - - - 0.6cm - - - - - true - true - - - - - SALDO AL CIERRE - - - - - - - 1pt - - - 1pt - - - 1pt - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - Pesos - - - - - - - Textbox6 - - - - 1pt - - - 1pt - - - - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - Dólares - - - - - - - Textbox13 - - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - 0.49417cm - - - - - true - true - - - - - =Fields!Banco.Value - - - - - - - - 1pt - - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Pesos", Fields!Saldo.Value, "") - - - - - - - Saldo - - - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Dólares", Fields!Saldo.Value, "") - - - - - - - Saldo1 - - - - - 1pt - - 2pt - 2pt - 2pt - 2pt - - - - - - - - 0.6cm - - - - - true - true - - - - - SALDOS - - - - - - - 1pt - - - 1pt - - - 1pt - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =Fields!Saldo.Value - - - - - - - Saldo2 - - - - - - - - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - true - true - - - - - =Sum(Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Dólares" And Fields!CveCuenta.Value = "-1", CDbl(Fields!Saldo.Value), 0)) - - - - - - - Saldo3 - - - - 1pt - - - 1pt - - - - - - 1pt - - #e0e3da - 2pt - 2pt - 2pt - 2pt - - - - - - - - - - - - - - - - - - - After - - - - - =Microsoft.VisualBasic.Interaction.IIF(Fields!Banco.Value = "", True, False) - - - - Before - - - - DataSet4 - 6.02637cm - 0.08599cm - 1.69417cm - 17.21559cm - 3 - - - - - - 3.1in - - - - - - - Textbox1 - 0.22833cm - 6.0099cm - 0.6cm - 9.74549cm - - - 2pt - 2pt - 2pt - 2pt - - - - true - true - - - - - FLUJO DIARIO - - - - - - - - - - - - - - - - Textbox2 - 0.86361cm - 6.0099cm - 0.52945cm - 9.74549cm - 1 - - - 2pt - 2pt - 2pt - 2pt - - - - External - =Parameters!LogoPath.Value - FitProportional - 0.22833cm - 0.08599cm - 2.40883cm - 4.0834cm - 2 - - - - - - true - true - - - - - =Parameters!Fecha.Value - - - - Textbox3 - 1.91108cm - 14.00032cm - 0.6cm - 6.2766cm - 3 - - - 2pt - 2pt - 2pt - 2pt - - - - 3.01512cm - 0.04947cm - 0cm - 20.22745cm - 4 - - - - - - - - - - - 1.00188cm - true - true - - - true - true - - - - - ="Página " & Globals.PageNumber & " de " & Globals.TotalPages - - - - - - - Textbox3 - 0.2734cm - 17.14236cm - 0.68085cm - 3.13456cm - - - 2pt - 2pt - 2pt - 2pt - - - - true - true - - - - - Usuario: - - - - - - 2pt - 2pt - 2pt - 2pt - - - - true - true - - - - - =Parameters!UsuarioImprimio.Value - - - - - - 2pt - 2pt - 2pt - 2pt - - - - true - true - - - - - Fecha Impresión: - - - - - - 2pt - 2pt - 2pt - 2pt - - - - true - true - - - - - =Parameters!FechaImpresion.Value - - - - - - 2pt - 2pt - 2pt - 2pt - - - - 0.15874cm - 0.08599cm - 0cm - 20.21078cm - 5 - - - - - - - - - - 27.94cm - 21.59cm - 0.5cm - 0.5cm - 1cm - 1cm - 0.13cm - + + + + + + + 1pt + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Pesos + + + + + + + Textbox6 + + + + + 1pt + + + + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Dólares + + + + + + + Textbox13 + + + + + 1pt + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.49417cm + + + + + true + true + + + + + =Fields!Banco.Value + + + + + + + + 1pt + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =IIF(Fields!Moneda.Value = "Pesos", Fields!Saldo.Value, "") + + + + + + + Saldo + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =IIF(Fields!Moneda.Value = "Dólares", Fields!Saldo.Value, "") + + + + + + + Saldo1 + + + + + 1pt + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.6cm + + + + + true + true + + + + + SALDOS + + + + + + + + 1pt + + + + 1pt + + + + 1pt + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Saldo.Value + + + + + + + Saldo2 + + + + + 1pt + + + + 1pt + + + + 1pt + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =SUM(IIF(Fields!Moneda.Value = "Dólares" AND Fields!CveCuenta.Value = "-1", CDbl(Fields!Saldo.Value), 0)) + + + + + + + Saldo3 + + + + + 1pt + + + + 1pt + + + + 1pt + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + After + + + + + =IIF(Fields!Banco.Value = "", TRUE,FALSE) + + + + Before + + + + DataSet1 + 0.17639cm + 0.24474cm + 1.69417cm + 19.59685cm + + + + + + + + + 12.45372cm + + + 3.47235cm + + + 3.71048cm + + + + + 0.6cm + + + + + true + true + + + + + INGRESOS DEL DIA + + + + + + + + 1pt + + + + 1pt + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Pesos + + + + + + + Textbox22 + + + + + 1pt + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Dólares + + + + + + + Textbox23 + + + + + 1pt + + + + 1pt + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.52062cm + + + + + true + true + + + + + =Fields!PagueseA.Value + + + + + + + + 1pt + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Pesos", Fields!Importe.Value, "") + + + + + + + Saldo + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Dólares", Fields!Importe.Value, "") + + + + + + + Importe + + + + + 1pt + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.6cm + + + + + true + true + + + + + TOTAL INGRESOS + + + + + + + + 1pt + + + + 1pt + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =SUM(IIF(Fields!Moneda.Value = "Pesos", CDbl(Fields!Importe.Value), 0)) + + + + + + + Textbox25 + + + + + 1pt + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =SUM(IIF(Fields!Moneda.Value = "Dólares", CDbl(Fields!Importe.Value), 0)) + + + + + + + Textbox26 + + + + + 1pt + + + + 1pt + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + After + + + + + + Before + + + + DataSet2 + 2.08222cm + 0.24474cm + 1.72062cm + 19.63655cm + 1 + + + + + + + + + 12.47357cm + + + 3.4525cm + + + 3.71048cm + + + + + 0.6cm + + + + + true + true + + + + + GASTOS DEL DÍA + + + + + + + + 1pt + + + 1pt + + + 1pt + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Pesos + + + + + + + Textbox6 + + + + + 1pt + + + 1pt + + + + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Dólares + + + + + + + Textbox13 + + + + + 1pt + + + 1pt + + + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.49417cm + + + + + true + true + + + + + =Fields!PagueseA.Value + + + + + + + + 1pt + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Pesos", Fields!Importe.Value, "") + + + + + + + Saldo + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Dólares", Fields!Importe.Value, "") + + + + + + + Saldo1 + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.6cm + + + + + true + true + + + + + TOTAL GASTOS + + + + + + + 1pt + + + 1pt + + + 1pt + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =SUM(IIF(Fields!Moneda.Value = "Pesos", CDbl(Fields!Importe.Value), 0)) + + + + + + + Saldo2 + + + + + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =SUM(IIF(Fields!Moneda.Value = "Dólares", CDbl(Fields!Importe.Value), 0)) + + + + + + + Saldo3 + + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + After + + + + + + Before + + + + DataSet3 + 4.05351cm + 0.22489cm + 1.69417cm + 19.63655cm + 2 + + + + + + + + + 12.45372cm + + + 3.43265cm + + + 3.69063cm + + + + + 0.6cm + + + + + true + true + + + + + SALDO AL CIERRE + + + + + + + 1pt + + + 1pt + + + 1pt + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Pesos + + + + + + + Textbox6 + + + + 1pt + + + 1pt + + + + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Dólares + + + + + + + Textbox13 + + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.49417cm + + + + + true + true + + + + + =Fields!Banco.Value + + + + + + + + 1pt + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Pesos", Fields!Saldo.Value, "") + + + + + + + Saldo + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Dólares", Fields!Saldo.Value, "") + + + + + + + Saldo1 + + + + + 1pt + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.6cm + + + + + true + true + + + + + SALDOS + + + + + + + 1pt + + + 1pt + + + 1pt + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Saldo.Value + + + + + + + Saldo2 + + + + + + + + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Sum(Microsoft.VisualBasic.Interaction.IIF(Fields!Moneda.Value = "Dólares" And Fields!CveCuenta.Value = "-1", CDbl(Fields!Saldo.Value), 0)) + + + + + + + Saldo3 + + + + 1pt + + + 1pt + + + + + + 1pt + + #e0e3da + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + After + + + + + =Microsoft.VisualBasic.Interaction.IIF(Fields!Banco.Value = "", True, False) + + + + Before + + + + DataSet4 + 6.02637cm + 0.24474cm + 1.69417cm + 19.577cm + 3 + + + + + + 3.1in + + + + + + + Textbox1 + 0.22833cm + 4.58115cm + 0.6cm + 11.78278cm + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + FLUJO DIARIO + + + + + + + + + + + + + + + + Textbox2 + 0.86361cm + 4.58115cm + 0.52945cm + 11.78278cm + 1 + + + 2pt + 2pt + 2pt + 2pt + + + + External + =Parameters!LogoPath.Value + FitProportional + 0.08599cm + 2.40883cm + 4.0834cm + 2 + + + + + + true + true + + + + + Fecha: + + + + Textbox3 + 2.51466cm + 0.08599cm + 0.6cm + 6.2766cm + 3 + + + 2pt + 2pt + 2pt + 2pt + + + + 3.33262cm + 0.04947cm + 0cm + 20.22745cm + 4 + + + + + + + + + + + 1.00188cm + true + true + + + true + true + + + + + ="Página " & Globals.PageNumber & " de " & Globals.TotalPages + + + + + + + Textbox3 + 0.2734cm + 17.14236cm + 0.68085cm + 3.13456cm + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Usuario: + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!UsuarioImprimio.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Fecha Impresión: + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!FechaImpresion.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + 0.15874cm + 0.08599cm + 0cm + 20.21078cm + 5 + + + + + + + + + + 27.94cm + 21.59cm + 0.5cm + 0.5cm + 1cm + 1cm + 0.13cm + @@ -3492,7 +3492,7 @@ First(Fields!MonedaP.Value, "Pago") + " - " + First(Fields!TipoCambioP.Value, "P Textbox31 0.00031cm 0.47652cm - 1.90028cm + 1.72389cm 7 @@ -3521,9 +3521,9 @@ First(Fields!MonedaP.Value, "Pago") + " - " + First(Fields!TipoCambioP.Value, "P Textbox32 - 1.90059cm + 1.75948cm 0.47652cm - 2.86701cm + 3.00812cm 8