From e6c0d3d99038f936df4cd5ba1921b81b9cb48c7d Mon Sep 17 00:00:00 2001 From: janeth arvizu Date: Mon, 25 Nov 2019 15:03:27 -0700 Subject: [PATCH] Factura - Clientes de EMD --- General/SaldosIniciales.aspx.vb | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/General/SaldosIniciales.aspx.vb b/General/SaldosIniciales.aspx.vb index 7db555706..6a7e7601c 100644 --- a/General/SaldosIniciales.aspx.vb +++ b/General/SaldosIniciales.aspx.vb @@ -294,7 +294,19 @@ Partial Class General_SaldosIniciales If Not dt.Columns(14).ColumnName = "Fecha Vencimiento" Then Alert("El nombre de la quinceava columna debe ser 'Fecha Vencimiento'. Favor de corregirlo", TipoMensaje.MsgError) Exit Sub - End If + End If + + If RblFormato.SelectedValue = "4" Then + If Not dt.Columns(15).ColumnName = "ImpuestoLocal" Then + Alert("El nombre de la diesciseisava columna debe ser 'ImpuestoLocal'. Favor de corregirlo", TipoMensaje.MsgError) + Exit Sub + End If + + If Not dt.Columns(16).ColumnName = "Amort.Ant" Then + Alert("El nombre de la diescisieteava columna debe ser 'Amort.Ant'. Favor de corregirlo", TipoMensaje.MsgError) + Exit Sub + End If + End If ElseIf RblFormato.SelectedValue = "5" Then @@ -1309,6 +1321,8 @@ Partial Class General_SaldosIniciales Dim Folio As Integer = Row("Folio").ToString.ToEntero Dim Fecha As Date = Row("Fecha").ToString.ToDate Dim FechaVencimiento As Date = Row("Fecha Vencimiento").ToString.ToDate + Dim ImpuestoLocal As Double = Row("ImpuestoLocal").ToString.ToDouble + Dim Amortizacion As Double = Row("Amort.Ant").ToString.ToDouble Dim SubTotal As Decimal = Row("SubTotal").ToString.ToDecimal Dim IVA As Decimal = Row("IVA").ToString.ToDecimal Dim Total As Decimal = Row("Total").ToString.ToDecimal @@ -1365,11 +1379,11 @@ Partial Class General_SaldosIniciales If TipoDocto.Contiene("Ing", "Egs", "Rem") Then GuardaLog(Serie & "-" & Folio) - If Not ObjVentas.AddVenta(TipoDocto, Folio, CveCliente.ToEntero, CveClienteSucursal, SubTotal, 0, 0, IVA, RetIVA, RetISR, Total, CveMoneda, TipoCambio.ToDouble, + If Not ObjVentas.AddVenta(TipoDocto, Folio, CveCliente.ToEntero, CveClienteSucursal, SubTotal, 0, Amortizacion, IVA, RetIVA, RetISR, Total, CveMoneda, TipoCambio.ToDouble, 0, 0, 0, FechaVencimiento, Fecha, "", "", Fecha, CveVendedor, Folio2, "", "", 0, 0, 0, "-1".ToDate, "-1".ToDate, "-1".ToDate, -1, -1, 0, CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, Serie:=Serie, CveSubProyecto:=Sucursal.ToEntero, CveSubProyectoEjecucion:=Sucursal.ToEntero, CveSubProyectoCobranza:=Sucursal.ToEntero, IEPS:=IEPS, - ObservacionesAlmacen:=Transaccion, Entrega:=CodCliente) Then + ObservacionesAlmacen:=Transaccion, Entrega:=CodCliente, ImpuestoLocal:=ImpuestoLocal) Then ErrorVentas = True Exit For End If