Compras Corrección global DT Tipos Activos Fijos
This commit is contained in:
@@ -42,6 +42,8 @@
|
||||
<asp:ListItem Value="13" Text="Anticipo Proveedores"></asp:ListItem>
|
||||
<asp:ListItem Value="2" Text="Clientes"></asp:ListItem>
|
||||
<asp:ListItem Value="4" Text="Factura - Cliente"></asp:ListItem>
|
||||
<asp:ListItem Value="17" Text="Factura - Cliente Detalle"></asp:ListItem>
|
||||
|
||||
<asp:ListItem Value="14" Text="Anticipo Clientes"></asp:ListItem>
|
||||
<asp:ListItem Value="5" Text="Productos y Sevicios" ></asp:ListItem>
|
||||
<asp:ListItem Value="16" Text="Clasificaciones" Enabled="True"></asp:ListItem>
|
||||
|
||||
@@ -225,7 +225,7 @@ Partial Class General_SaldosIniciales
|
||||
|
||||
|
||||
|
||||
ElseIf RblFormato.SelectedValue = "3" Or RblFormato.SelectedValue = "4" Then
|
||||
ElseIf RblFormato.SelectedValue = "3" Or RblFormato.SelectedValue = "4" Or RblFormato.SelectedValue = "17" Then
|
||||
If Not dt.Columns(0).ColumnName = "Sucursal" Then
|
||||
Alert("El nombre de la primera columna debe ser 'Sucursal'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
@@ -293,6 +293,16 @@ Partial Class General_SaldosIniciales
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
If Not dt.Columns(15).ColumnName = "Folio Fiscal" Then
|
||||
Alert("El nombre de la decimosexta columna debe ser 'Folio Fiscalo'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
If Not dt.Columns(16).ColumnName = "PorcentajeIVA" Then
|
||||
Alert("El nombre de la decimoséptima columna debe ser 'PorcentajeIVA'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
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)
|
||||
@@ -305,6 +315,31 @@ Partial Class General_SaldosIniciales
|
||||
' End If
|
||||
'End If
|
||||
|
||||
If RblFormato.SelectedValue = "17" Then
|
||||
|
||||
|
||||
If Not dt.Columns(17).ColumnName = "Cantidad" Then
|
||||
Alert("El nombre de la Decimoctava columna debe ser 'Cantidad'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
If Not dt.Columns(18).ColumnName = "PU" Then
|
||||
Alert("El nombre de la Decimonovena columna debe ser 'PU'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
If Not dt.Columns(19).ColumnName = "IVA" Then
|
||||
Alert("El nombre de la Vigésima columna debe ser 'IVA'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
|
||||
If Not dt.Columns(20).ColumnName = "IEPS" Then
|
||||
Alert("El nombre de la Vigésimo primera columna debe ser 'IEPS'. Favor de corregirlo", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
ElseIf RblFormato.SelectedValue = "5" Then
|
||||
|
||||
@@ -1571,7 +1606,7 @@ Partial Class General_SaldosIniciales
|
||||
#End Region
|
||||
|
||||
'C L I E N T E S - F A C T U R A S
|
||||
ElseIf RblFormato.SelectedValue = "4" Then
|
||||
ElseIf RblFormato.SelectedValue = "4" Or RblFormato.SelectedValue = "17" Then
|
||||
|
||||
#Region "C L I E N T E S - F A C T U R A S"
|
||||
|
||||
@@ -1626,7 +1661,9 @@ Partial Class General_SaldosIniciales
|
||||
Dim CveMoneda As Integer = 1
|
||||
Dim Vendedor As String = If(dt.Columns.Contains("Vendedor"), Row("Vendedor").ToString(), "")
|
||||
Dim CveVendedor As Integer = 0
|
||||
|
||||
Dim IEPS As Decimal = 0 'Row("IEPS").ToString().ToDecimal
|
||||
|
||||
Dim CveClienteSucursal As Integer = 0 'Row("CveClienteSucursal").ToString().ToEntero()
|
||||
Dim FolioFiscal As String = If(dt.Columns.Contains("Folio Fiscal"), Row("Folio Fiscal").ToString(), "")
|
||||
Dim PorcentajeIVA As Decimal = If(dt.Columns.Contains("PorcentajeIVA"), Round(Row("PorcentajeIVA").ToString().ToDecimal, 4), 0)
|
||||
@@ -1640,6 +1677,16 @@ Partial Class General_SaldosIniciales
|
||||
Dim Folio2 As String = "" ' Row("Folio2").ToString()
|
||||
Dim CodCliente As String = "" 'Row("CodCliente2").ToString()
|
||||
|
||||
|
||||
Dim IEPSDetalle As Decimal = 0
|
||||
Dim CantidadDetalle As Decimal = 0
|
||||
Dim PUDetalle As Decimal = 0
|
||||
Dim IVADetalle As Decimal = 0
|
||||
|
||||
If RblFormato.SelectedValue = "17" Then
|
||||
IEPSDetalle = Row("IEPS").ToString.ToDecimal
|
||||
End If
|
||||
|
||||
If dt.Columns.Contains("Cliente Sucursal") AndAlso Row("Cliente Sucursal").ToString() <> "" Then
|
||||
|
||||
Dim ObjCliente As New ClsClientes
|
||||
@@ -1710,10 +1757,25 @@ Partial Class General_SaldosIniciales
|
||||
End If
|
||||
CveVenta = ObjVentas.CveVenta
|
||||
|
||||
If Not ObjVentas.AddVentaDetalle(CveVenta, CvePS, 1, CveUnidadMedida, SubTotal, IVA, SubTotal * PorcentajeIVA, "Saldo Inicial", 0, 0, Sucursal.ToEntero(), 0, PorcentajeIVA:=PorcentajeIVA, PorcentajeRetIVA:=PorcentajeRetIVA, ImporteRetIVA:=RetIVA, IEPS:=0) Then
|
||||
ErrorVentas = True
|
||||
Exit For
|
||||
|
||||
If RblFormato.SelectedValue = "17" Then
|
||||
If Not ObjVentas.AddVentaDetalle(CveVenta, CvePS, CantidadDetalle, CveUnidadMedida, PUDetalle * CantidadDetalle, IVADetalle, (PUDetalle * CantidadDetalle) + IVADetalle - IEPSDetalle, "Saldo Inicial", 0, 0, Sucursal.ToEntero(), 0,
|
||||
PorcentajeIVA:=PorcentajeIVA, PorcentajeRetIVA:=PorcentajeRetIVA, ImporteRetIVA:=RetIVA, IEPS:=IEPSDetalle) Then
|
||||
ErrorVentas = True
|
||||
Exit For
|
||||
End If
|
||||
Else
|
||||
If Not ObjVentas.AddVentaDetalle(CveVenta, CvePS, 1, CveUnidadMedida, SubTotal, IVA, SubTotal * PorcentajeIVA, "Saldo Inicial", 0, 0, Sucursal.ToEntero(), 0, PorcentajeIVA:=PorcentajeIVA, PorcentajeRetIVA:=PorcentajeRetIVA, ImporteRetIVA:=RetIVA, IEPS:=0) Then
|
||||
ErrorVentas = True
|
||||
Exit For
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Dim ConceptoContable As Integer = 1
|
||||
Dim ConceptoContablePago As Integer = 2
|
||||
If TipoDocto = "Egs" Then
|
||||
@@ -2980,6 +3042,8 @@ Partial Class General_SaldosIniciales
|
||||
Directorio = ModExtensiones.DirectorioBaseEmpresas & "Empresas\Grales\SaldosIniciales\FormatoBancos.xlsx"
|
||||
ElseIf RblFormato.SelectedValue = "16" Then
|
||||
Directorio = ModExtensiones.DirectorioBaseEmpresas & "Empresas\Grales\SaldosIniciales\FormatoClasificaciones.xlsx"
|
||||
ElseIf RblFormato.SelectedValue = "17" Then
|
||||
Directorio = ModExtensiones.DirectorioBaseEmpresas & "Empresas\Grales\SaldosIniciales\FormatoClientes-Facturas-Detalles.xlsx"
|
||||
End If
|
||||
|
||||
If Not (Directorio = "") Then
|
||||
|
||||
Reference in New Issue
Block a user