Nueva columna agregada a FormatoClientes.xlsx

This commit is contained in:
Antonio Gonzalez
2019-08-21 11:29:48 -05:00
parent 69122d7cc6
commit 925ac84761
2 changed files with 11 additions and 4 deletions

View File

@@ -121,6 +121,12 @@ Partial Class General_SaldosIniciales
Alert("El nombre de la treceava columna debe ser 'Plazo Cobranza'. Favor de corregirlo", TipoMensaje.MsgError) Alert("El nombre de la treceava columna debe ser 'Plazo Cobranza'. Favor de corregirlo", TipoMensaje.MsgError)
Exit Sub Exit Sub
End If End If
If RblFormato.SelectedValue = "1" Then
If Not dt.Columns(14).ColumnName = "Es distribuidor" Then
Alert("El nombre de la catorceava columna debe ser 'Es distribuidor'. Favor de corregirlo", TipoMensaje.MsgError)
Exit Sub
End If
End If
ElseIf RblFormato.SelectedValue = "3" Or RblFormato.SelectedValue = "4" Then ElseIf RblFormato.SelectedValue = "3" Or RblFormato.SelectedValue = "4" Then
If Not dt.Columns(0).ColumnName = "Sucursal" Then If Not dt.Columns(0).ColumnName = "Sucursal" Then
@@ -718,6 +724,7 @@ Partial Class General_SaldosIniciales
Dim Contacto As String = Row("Contacto").ToString Dim Contacto As String = Row("Contacto").ToString
Dim CelularContacto As String = Row("Celular Contacto").ToString Dim CelularContacto As String = Row("Celular Contacto").ToString
Dim CveCliente As Integer = GlobalDTCliente(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveCliente", $"RFC = '{RFC}'").ToString.ToEntero Dim CveCliente As Integer = GlobalDTCliente(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveCliente", $"RFC = '{RFC}'").ToString.ToEntero
Dim EsDistribuidor As Boolean = If(Row("Es distribuidor").ToString = "si", True, False)
If CveCliente > 0 Then If CveCliente > 0 Then
ExisteCliente = True ExisteCliente = True
@@ -730,7 +737,7 @@ Partial Class General_SaldosIniciales
'End If 'End If
Else Else
If Not ObjClientes.AddCliente(RazonSocial, RazonSocial, Calle, "", "", Colonia, "", "", Estado, Pais, RFC, CodigoPostal, "", "", Contacto, "", "", "", "", -1, False, 0, 0, False, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, "", -1, -1, -1, If Not ObjClientes.AddCliente(RazonSocial, RazonSocial, Calle, "", "", Colonia, "", "", Estado, Pais, RFC, CodigoPostal, "", "", Contacto, "", "", "", "", -1, False, 0, 0, False, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, "", -1, -1, -1,
"-1", "-1", -1, "-1", -1, "0", -1, "0", 0, "", 0, "", 0, "", 0, "", "", "", Codigo, 0, "", 1, False, "", "", "", False, "", "", "", "", "", False, "", "", "", False, 0, -1) Then "-1", "-1", -1, "-1", -1, "0", -1, "0", 0, "", 0, "", 0, "", 0, "", "", "", Codigo, 0, "", 1, False, "", "", "", False, "", "", "", "", "", False, "", "", "", False, 0, -1, EsDistribuidor:=EsDistribuidor) Then
ErrorClientes = True ErrorClientes = True
RFC.GuardaLog RFC.GuardaLog
Exit For Exit For
@@ -769,11 +776,11 @@ Partial Class General_SaldosIniciales
Dim Encontrados As Integer = 0 Dim Encontrados As Integer = 0
DtProveedores = GlobalDTCompProveedores(UsuarioActual.CveEmpresa) DtProveedores = GlobalDTCompProveedores(UsuarioActual.CveEmpresa)
Dim RFC As String = "" Dim RFC As String = ""
Dim drr As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa).FiltroPrimero("") Dim drr As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa).FiltroPrimero("")
Dim CvePS As Integer = drr("CvePS").ToString.ToEntero Dim CvePS As Integer = drr("CvePS").ToString.ToEntero
Dim CveUnidadMedida As Integer = drr("CveUnidadMedida").ToString.ToEntero Dim CveUnidadMedida As Integer = drr("CveUnidadMedida").ToString.ToEntero
Dim CveClasificacion As Integer = drr("CveClasificacion").ToString.ToEntero Dim CveClasificacion As Integer = drr("CveClasificacion").ToString.ToEntero
Dim dtsubp As DataTable = GlobalDTSubProyectos(-1, CveEmpresa:=UsuarioActual.CveEmpresa) Dim dtsubp As DataTable = GlobalDTSubProyectos(-1, CveEmpresa:=UsuarioActual.CveEmpresa)
For Each Row As DataRow In dt.FiltraParametros("RFC <> ''").Rows For Each Row As DataRow In dt.FiltraParametros("RFC <> ''").Rows
@@ -789,7 +796,7 @@ Dim drr As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa).FiltroPrimero("")
Dim Saldo As Decimal = Row("Saldo").ToString.ToDecimal Dim Saldo As Decimal = Row("Saldo").ToString.ToDecimal
Dim TipoDocto As String = Row("Tipo Documento").ToString Dim TipoDocto As String = Row("Tipo Documento").ToString
Dim CveProveedor As Integer = DtProveedores.FiltroPrimeroValor("CveProveedor", $"RFC = '{RFC}'").ToString.ToEntero Dim CveProveedor As Integer = DtProveedores.FiltroPrimeroValor("CveProveedor", $"RFC = '{RFC}'").ToString.ToEntero
GuardaLog(Sucursal + " - " + Row("Sucursal").ToString) GuardaLog(Sucursal + " - " + Row("Sucursal").ToString)
Dim RetIVA As Double = Row("Ret IVA").ToString.ToDouble Dim RetIVA As Double = Row("Ret IVA").ToString.ToDouble
Dim RetISR As Double = Row("Ret ISR").ToString.ToDouble Dim RetISR As Double = Row("Ret ISR").ToString.ToDouble
Dim IEPS As Decimal = Row("IEPS").ToString.ToDecimal Dim IEPS As Decimal = Row("IEPS").ToString.ToDecimal