This commit is contained in:
2019-11-19 10:31:48 -07:00
9 changed files with 75 additions and 41 deletions

View File

@@ -96,7 +96,8 @@ Public Class ClsInventarios
Public Property CveGrupoPS As Integer
Public Property CveFlete As Integer
Public Property CveCliente As Integer
Public Property CveClienteSucursal As Integer
Public Property CveClienteSucursal As Integer
Public Property NombreCliente As String
Public Property DepartamentoEntrega As String
Public Property PedidoContrato As String
Public Property GastoIndirecto As Double
@@ -820,6 +821,7 @@ Public Class ClsInventarios
FolioInterno = dr("VentaAnticipo").ToString
CveCliente = If(dr("CveCliente").ToString.ToEntero > 0, dr("CveCliente").ToString.ToEntero, -1)
CveClienteSucursal = If(dr("CveClienteSucursal").ToString.ToEntero > 0, dr("CveClienteSucursal").ToString.ToEntero, -1)
NombreCliente = dr("Nombre").ToString
DepartamentoEntrega = dr("DepartamentoEntrega").ToString
PedidoContrato = dr("PedidoContrato").ToString
TienePrePoliza = dr("TienePrePoliza").ToString.ToEntero

View File

@@ -1510,16 +1510,16 @@ Partial Class Bancos_ProveedoresAbonar
'funcionalidad que toma el 100% del pago para acreditamiento de iva
If TotalImporte = gvr.DataKey("Saldo").ToDecimal Then
If CveMoneda = 1 AndAlso gvr.DataKey("CveMoneda").ToEntero = 1 Then
ImporteMovimiento = gvr.DataKey("IVA").ToDecimal
ImporteMovimiento = gvr.DataKey("IVADeducible").ToDecimal
importeMX = ImporteMovimiento
ElseIf CveMoneda = 1 AndAlso gvr.DataKey("CveMoneda").ToEntero = 2 Then
ImporteMovimiento = gvr.DataKey("IVA").ToDecimal
importeMX = gvr.DataKey("IVA").ToDecimal * If(FuncionalidadFluctuacionImpuestos, TipoCambioPago, tipoCambioCompra)
ImporteMovimiento = gvr.DataKey("IVADeducible").ToDecimal
importeMX = gvr.DataKey("IVADeducible").ToDecimal * If(FuncionalidadFluctuacionImpuestos, TipoCambioPago, tipoCambioCompra)
ElseIf CveMoneda = 2 AndAlso gvr.DataKey("CveMoneda").ToEntero = 1 Then
ImporteMovimiento = gvr.DataKey("IVA").ToDecimal
ImporteMovimiento = gvr.DataKey("IVADeducible").ToDecimal
importeMX = ImporteMovimiento * tipoCambioCompra
ElseIf CveMoneda = 2 AndAlso gvr.DataKey("CveMoneda").ToEntero = 2 Then
ImporteMovimiento = gvr.DataKey("IVA").ToDecimal
ImporteMovimiento = gvr.DataKey("IVADeducible").ToDecimal
importeMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, TipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2, MidpointRounding.AwayFromZero)
@@ -1532,16 +1532,16 @@ Partial Class Bancos_ProveedoresAbonar
End If
Else
If CveMoneda = 1 AndAlso gvr.DataKey("CveMoneda").ToEntero = 1 Then
ImporteMovimiento = If(TotalImporte = gvr.DataKey("Saldo").ToDecimal AndAlso Math.Abs(Math.Round(gvr.DataKey("IVAPorPagar").ToDecimal - (gvr.DataKey("IVA").ToDecimal * PorcentajePago), 2)) <= 0.02, gvr.DataKey("IVAPorPagar").ToDecimal, gvr.DataKey("IVA").ToDecimal * PorcentajePago)
ImporteMovimiento = If(TotalImporte = gvr.DataKey("Saldo").ToDecimal AndAlso Math.Abs(Math.Round(gvr.DataKey("IVAPorPagar").ToDecimal - (gvr.DataKey("IVADeducible").ToDecimal * PorcentajePago), 2)) <= 0.02, gvr.DataKey("IVAPorPagar").ToDecimal, gvr.DataKey("IVADeducible").ToDecimal * PorcentajePago)
importeMX = ImporteMovimiento
ElseIf CveMoneda = 1 AndAlso gvr.DataKey("CveMoneda").ToEntero = 2 Then
ImporteMovimiento = If(TotalImporte = gvr.DataKey("Saldo").ToDecimal AndAlso Math.Abs(Math.Round(gvr.DataKey("IVAPorPagar").ToDecimal - (gvr.DataKey("IVA").ToDecimal * PorcentajePago), 2)) <= 0.02, gvr.DataKey("IVAPorPagar").ToDecimal, gvr.DataKey("IVA").ToDecimal * PorcentajePago)
ImporteMovimiento = If(TotalImporte = gvr.DataKey("Saldo").ToDecimal AndAlso Math.Abs(Math.Round(gvr.DataKey("IVAPorPagar").ToDecimal - (gvr.DataKey("IVADeducible").ToDecimal * PorcentajePago), 2)) <= 0.02, gvr.DataKey("IVAPorPagar").ToDecimal, gvr.DataKey("IVADeducible").ToDecimal * PorcentajePago)
importeMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, TipoCambioPago, tipoCambioCompra)
ElseIf CveMoneda = 2 AndAlso gvr.DataKey("CveMoneda").ToEntero = 1 Then
ImporteMovimiento = If(TotalImporte = gvr.DataKey("Saldo").ToDecimal AndAlso Math.Abs(Math.Round(gvr.DataKey("IVAPorPagar").ToDecimal - (gvr.DataKey("IVA").ToDecimal * PorcentajePago), 2)) <= 0.02, gvr.DataKey("IVAPorPagar").ToDecimal, gvr.DataKey("IVA").ToDecimal * PorcentajePago)
ImporteMovimiento = If(TotalImporte = gvr.DataKey("Saldo").ToDecimal AndAlso Math.Abs(Math.Round(gvr.DataKey("IVAPorPagar").ToDecimal - (gvr.DataKey("IVADeducible").ToDecimal * PorcentajePago), 2)) <= 0.02, gvr.DataKey("IVAPorPagar").ToDecimal, gvr.DataKey("IVADeducible").ToDecimal * PorcentajePago)
importeMX = ImporteMovimiento * tipoCambioCompra
ElseIf CveMoneda = 2 AndAlso gvr.DataKey("CveMoneda").ToEntero = 2 Then
ImporteMovimiento = If(TotalImporte = gvr.DataKey("Saldo").ToDecimal AndAlso Math.Abs(Math.Round(gvr.DataKey("IVAPorPagar").ToDecimal - (gvr.DataKey("IVA").ToDecimal * PorcentajePago), 2)) <= 0.02, gvr.DataKey("IVAPorPagar").ToDecimal, gvr.DataKey("IVA").ToDecimal * PorcentajePago)
ImporteMovimiento = If(TotalImporte = gvr.DataKey("Saldo").ToDecimal AndAlso Math.Abs(Math.Round(gvr.DataKey("IVAPorPagar").ToDecimal - (gvr.DataKey("IVADeducible").ToDecimal * PorcentajePago), 2)) <= 0.02, gvr.DataKey("IVAPorPagar").ToDecimal, gvr.DataKey("IVADeducible").ToDecimal * PorcentajePago)
importeMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, TipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2, MidpointRounding.AwayFromZero)
@@ -1549,17 +1549,32 @@ Partial Class Bancos_ProveedoresAbonar
If TipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{TipoCambioPago} ${ImporteMovimiento.FormatoNumero(2)}"
End If
TipoCambioGeneral = If(FuncionalidadFluctuacionImpuestos, TipoCambioPago, tipoCambioCompra)
TipoCambioGeneral = If(FuncionalidadFluctuacionImpuestos, TipoCambioPago, tipoCambioCompra)
PorcentajeImpuesto = gvr.DataKey("PorcentajeIVA").ToDecimal
Dim IdCtaIVAXAcreditar As Integer = 0
Dim IdCtaIVAAcreditable As Integer = 0
Dim IdCtaIVAAcreditable As Integer = 0
Dim IdCtaContableNoIVA As Integer = 0
If GlobalDTClasificacionPorcentaje(UsuarioActual.CveEmpresa, PorcentajeIVA:=PorcentajeImpuesto).Rows.Count > 0 Then
IdCtaIVAXAcreditar = GlobalDTClasificacionPorcentaje(UsuarioActual.CveEmpresa, PorcentajeIVA:=PorcentajeImpuesto).Rows(0)("IdCtaIVAXAcreditar").ToString.ToEntero
IdCtaIVAAcreditable = GlobalDTClasificacionPorcentaje(UsuarioActual.CveEmpresa, PorcentajeIVA:=PorcentajeImpuesto).Rows(0)("IdCtaIVAAcreditable").ToString.ToEntero
IdCtaContableNoIVA = GlobalDTClasificacionPorcentaje(UsuarioActual.CveEmpresa, PorcentajeIVA:=PorcentajeImpuesto).Rows(0)("IdCtaIVANoAcreditable").ToString.ToEntero
End If
IdCtaContable = If(IdCtaIVAAcreditable > 0, IdCtaIVAAcreditable, 0)
'se registra el iva no acreditable
If gvr.DataKey("IVANoDeducible").ToDecimal > 0 Then
Dim ImporteNOIVA As Decimal = gvr.DataKey("IVANoDeducible").ToDecimal * PorcentajePago
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, ImporteNOIVA, Referencia, 280, ConceptoMovimiento, FechaMovimiento, IdCtaContableNoIVA, -1, CveIE, CveCompra:=gvr.DataKey("CveCompra").ToEntero, CveProveedor:=CveProveedor, ImporteMX:=ImporteNOIVA, ImporteME:=If(TipoCambioPago = 1, 0, ImporteMovimiento), CveCuenta:=CveCuenta, TipoCambio:=TipoCambioGeneral, PorcentajeImpuesto:=PorcentajeImpuesto) Then
MsgError = "No se pudo insertar la póliza"
Exit For
End If
End If
IdCtaContable = If(IdCtaIVAAcreditable > 0, IdCtaIVAAcreditable, 0)
If ImporteMovimiento <> 0 AndAlso ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) And Not IdCtaContable > 0 Then
If ObjMov.DtResultados.Rows.Count > 0 Then

View File

@@ -6989,10 +6989,10 @@ Partial Class Compras_Compras
CveCuentaPago = CveCuentaProveedorExtranjera
End If
'Agregamos el 17
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, Not TipoMovimiento, importeMovimiento, Referencia, 17, Concepto, FechaMovimiento, IdCtaContablePago, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorLocal, CveAcreedor:=CveAcreedor, CveIE:=Ant.CveIE, CveColectiva:=CveColectiva, ImporteMX:=importeMN, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), CveCuenta:=CveCuentaPago, Contabilizable:=SeContabiliza) Then
ErrorPrepoliza = True
End If
''Agregamos el 17
'If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, Not TipoMovimiento, importeMovimiento, Referencia, 17, Concepto, FechaMovimiento, IdCtaContablePago, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorLocal, CveAcreedor:=CveAcreedor, CveIE:=Ant.CveIE, CveColectiva:=CveColectiva, ImporteMX:=importeMN, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), CveCuenta:=CveCuentaPago, Contabilizable:=SeContabiliza) Then
' ErrorPrepoliza = True
'End If
End If
' FLUCTUACION CAMBIARIA
@@ -9925,7 +9925,7 @@ Partial Class Compras_Compras
Dim nodeDocumentosRelacionados As XmlNodeList = XMLDoc.SelectNodes(String.Format("//{0}:CfdiRelacionado", Prefijo), namespaces)
For Each documento As XmlNode In nodeDocumentosRelacionados
If documento.Attributes("UUID").Value <> "" Then
ListaDocumentos.Add(documento.Attributes("UUID").Value)
'ListaDocumentos.Add(documento.Attributes("UUID").Value)
End If
Next
End If
@@ -14800,7 +14800,7 @@ Partial Class Compras_Compras
AddPS2(False)
'AJUSTE DE REDONDEO O DIFERENCIA PERMITIDA DE IMPORTE
AjustaImporteUltimoConcepto((If(ListaDocumentos IsNot Nothing AndAlso ListaDocumentos.Count > 0 AndAlso ArrAnticipos IsNot Nothing AndAlso ArrAnticipos.Count > 0 AndAlso TxtTotal.Text.ToDecimal = 0, TmpDT.SUMD("ImporteSinImpuestos"), TxtSubTotal2.Text.ToDouble) + TxtOtrosImpuestos.Text.ToDouble).ToDecimal - If(ListaDocumentos IsNot Nothing AndAlso ListaDocumentos.Count > 0 AndAlso ArrAnticipos IsNot Nothing AndAlso ArrAnticipos.Count > 0 AndAlso TxtTotal.Text.ToDecimal = 0, TmpDT.SUM("ImporteSinImpuestos").ToString.ToDecimal, TmpDT.SUM("Total").ToString.ToDecimal))
AjustaImporteUltimoConcepto((If(ListaDocumentos IsNot Nothing AndAlso ListaDocumentos.Count > 0 AndAlso ArrAnticipos IsNot Nothing AndAlso ArrAnticipos.Count > 0 AndAlso TxtTotal.Text.ToDecimal = 0, TmpDT.SUMD("ImporteSinImpuestos"), TxtSubTotal.Text.ToDouble) + TxtOtrosImpuestos.Text.ToDouble).ToDecimal - If(ListaDocumentos IsNot Nothing AndAlso ListaDocumentos.Count > 0 AndAlso ArrAnticipos IsNot Nothing AndAlso ArrAnticipos.Count > 0 AndAlso TxtTotal.Text.ToDecimal = 0, TmpDT.SUM("ImporteSinImpuestos").ToString.ToDecimal, TmpDT.SUM("Total").ToString.ToDecimal))
'AjustaImporteUltimoConcepto(TxtSubTotal2.Text.ToDecimal + TxtOtrosImpuestos.Text.ToDecimal - (TmpDT.SUM("Total").ToString.ToDecimal))
@@ -16263,11 +16263,15 @@ Partial Class Compras_Compras
Dim TempSubTotal, TempDescuentos, TempIVA, TempSubTotal2, TempRetIVA, TempRetISR, TempTotal, DifTotales, TempIEPS As Double
'Dim TempPorcentajeRetIVA = LblRetIVA.Text.ToDouble / 100
'Dim TempPorcentajeRetISR = LblRetISR.Text.ToDouble / 100
Dim Amortizacion As Decimal = 0
If UsuarioActual.CveEmpresa = 119 Then
Amortizacion = LblAmortizacion.Text.Trim.ToDecimal
End If
TempSubTotal = TxtSubTotal.Text.ToDouble
SubTotalOriginal = TxtSubTotal.Text.ToDouble
SubTotal2Original = TxtSubTotal2.Text.ToDouble
TempDescuentos = TxtDescuento.Text.Trim.ToDouble '+ LblAmortizacion.Text.Trim.ToDouble
TempDescuentos = TxtDescuento.Text.Trim.ToDouble + Amortizacion
TempSubTotal2 = TempSubTotal - TempDescuentos
TempIVA = TxtIVA.Text.ToDouble
TempIEPS = TxtIEPS.Text.ToDouble

View File

@@ -1,7 +1,6 @@
Option Strict On
Option Explicit On
Imports Extensiones
Imports System.Data
Imports Microsoft.Reporting.WebForms
@@ -1179,7 +1178,8 @@ Partial Class PopUpVerFactura
Dim FolioOC As String = ObjInventarios.FolioOC
Dim FolioInterno As String = ObjInventarios.FolioInterno
Dim CveCliente As Integer = ObjInventarios.CveCliente
Dim CveCliente As Integer = ObjInventarios.CveCliente
Dim NombreCliente As String = ObjInventarios.NombreCliente
Dim CveClienteSucursal As Integer = ObjInventarios.CveClienteSucursal
Dim DepartamentoEntrega As String = ObjInventarios.DepartamentoEntrega
Dim FechaMovimiento As Date = ObjInventarios.FechaRegistro
@@ -1215,12 +1215,15 @@ Partial Class PopUpVerFactura
End If
ObjInventarios.Dispose()
If RazonSocial = "" AndAlso NombreCliente <> "" Then RazonSocial = NombreCliente
ImprimePDFAlmacen(CveConcepto, CveCompra, Folio.ToString, Fecha, Almacen, SubProyecto, Observaciones, Recibio,
Personal, Capturo, AlmacenDestino, CveConsignacion, CveMoneda, Moneda, FolioVenta, FolioOC,
FolioInterno, FechaHora, ObservacionesSolicitud, DepartamentoEntrega, RazonSocialOC,
Remision, Proveedor, CalleOrigen, NoExtOrigen, ColoniaOrigen, LocalidadOrigen, MunicipioOrigen,
EstadoOrigen, PaisOrigen, CPOrigen, CalleDestino, NoExtDestino, ColoniaDestino, LocalidadDestino, MunicipioDestino, EstadoDestino, PaisDestino, CPDestino, FechaMovimiento, NombreCapturo, PuestoRecibio, PuestoEnrego, RazonSocial, ResponsableCarga, ResponsableRecibio)
EstadoOrigen, PaisOrigen, CPOrigen, CalleDestino, NoExtDestino, ColoniaDestino, LocalidadDestino,
MunicipioDestino, EstadoDestino, PaisDestino, CPDestino, FechaMovimiento, NombreCapturo, PuestoRecibio,
PuestoEnrego, RazonSocial, ResponsableCarga, ResponsableRecibio)
End Sub
Private Sub PUanacExtr(CveMoneda As Integer) 'preciounitario a moneda nacional o extranjera
@@ -1236,7 +1239,10 @@ Partial Class PopUpVerFactura
FolioInterno As String, FechaHora As DateTime, ObservacionesSolicitud As String, DepartamentoEntrega As String, RazonSocialOC As String,
Remision As String, Proveedor As String, CalleOrigen As String, NoExtOrigen As String, ColoniaOrigen As String, LocalidadOrigen As String, MunicipioOrigen As String,
EstadoOrigen As String, PaisOrigen As String, CPOrigen As String, CalleDestino As String, NoExtDestino As String, ColoniaDestino As String, LocalidadDestino As String, MunicipioDestino As String,
EstadoDestino As String, PaisDestino As String, CPDestino As String, FechaMovimiento As Date, NombreCapturo As String, PuestoRecibio As String, PuestoEntrego As String, RazonSocial As String, ResponsableCarga As String, ResponsableRecibio As String)
EstadoDestino As String, PaisDestino As String, CPDestino As String, FechaMovimiento As Date, NombreCapturo As String, PuestoRecibio As String, PuestoEntrego As String,
RazonSocial As String, ResponsableCarga As String, ResponsableRecibio As String)
Select Case CveConcepto
Case 1 'INICIAL
Dim Archivo As New System.IO.FileInfo(String.Format("{0}Formatos/Inicial.rdlc", UsuarioActual.Empresa.Ruta))
@@ -1286,6 +1292,7 @@ Partial Class PopUpVerFactura
End If
Dim params As New List(Of ReportParameter)
If Archivo.Exists Then
@@ -1358,7 +1365,7 @@ Partial Class PopUpVerFactura
params.Add(New ReportParameter("Folio", Folio.ToString))
params.Add(New ReportParameter("NumeroOrden", If(CveCompra > 0, dr("OCVinculada").ToString, "")))
params.Add(New ReportParameter("FacturaProveedor", If(CveCompra > 0, dr("SerieFolio").ToString, "")))
params.Add(New ReportParameter("NombreProveedor", If(CveCompra > 0, dr("RazonSocial").ToString, "")))
params.Add(New ReportParameter("NombreProveedor", RazonSocial))
params.Add(New ReportParameter("DireccionProveedor", If(CveCompra > 0, dr("Direccion").ToString, "")))
params.Add(New ReportParameter("CiudadProveedor", " "))
params.Add(New ReportParameter("EstadoProveedor", " "))
@@ -1396,7 +1403,7 @@ Partial Class PopUpVerFactura
params.Add(New ReportParameter("FechaImpresion", DateTime.Now.ToString("dd/MM/yyyy")))
params.Add(New ReportParameter("Folio", Folio))
params.Add(New ReportParameter("FacturaProveedor", If(CveCompra > 0 AndAlso dr IsNot Nothing, dr("SerieFolio").ToString, "")))
params.Add(New ReportParameter("FacturadoA", If(CveCompra > 0, dr("RazonSocial").ToString, "")))
params.Add(New ReportParameter("FacturadoA", RazonSocial))
params.Add(New ReportParameter("Descuentos", If(CveCompra > 0 AndAlso dr IsNot Nothing, (dr("Descuentos").ToString.ToDouble).FormatoNumero(2), "")))
params.Add(New ReportParameter("IVA", If(CveCompra > 0 AndAlso dr IsNot Nothing, dr("IVA").ToString.FormatoNumero(2), "")))
params.Add(New ReportParameter("Total", If(CveCompra > 0 AndAlso dr IsNot Nothing, dr("Total").ToString.FormatoNumero(2), "")))

View File

@@ -180,6 +180,7 @@
<asp:BoundField HeaderText="SubTotal 0%" DataField="valorActosImp0" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField HeaderText="IVA" DataField="IVA" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField HeaderText="%IVA" DataField="PorcentajeIVA" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField HeaderText="IVA ND" DataField="IVANoDeducible" DataFormatString="{0:#,###,###.##}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField HeaderText="IEPS" DataField="IEPS" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField ItemStyle-HorizontalAlign="Right">
<HeaderTemplate>

View File

@@ -1965,7 +1965,7 @@ Partial Class Inventarios_RecepcionEntrega
If DtTamanios IsNot Nothing AndAlso DtTamanios.Rows.Count > 0 AndAlso CveAlmacenVirtual > 0 Then
Dim CveConceptoMovimientoVirtual = If(TipoMovimiento = 1, 3, 18) 'CHECA SI ES ENTRADA O DEVOLUCION
CveMovimientoVirtual = ObjInventario.AddMovimiento(CveAlmacenVirtual, CveConceptoMovimientoVirtual, 1, TxtFecha.Text.ToDate, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, CveVentaSurtir, -1, -1, Observaciones:=TxtObservaciones.Text.Trim, Guia:=TxtGuia.Text)
CveAlmacenVirutal = ObjInventario.AddMovimiento(CveAlmacenVirutal, CveConceptoMovimientoVirtual, 1, TxtFecha.Text.ToDate, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, CveVentaSurtir, -1, -1, Observaciones:=TxtObservaciones.Text.Trim, Guia:=TxtGuia.Text)
FolioVirtual = ObjInventario.Folio
If CveMovimientoVirtual > 0 Then
@@ -1975,7 +1975,7 @@ Partial Class Inventarios_RecepcionEntrega
Dim PU As Double = RowUsado("PU").ToString().ToDouble()
Dim CveUM As Integer = RowUsado("CveUM").ToString().ToEntero()
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoVirtual, CantidadEntrada, CveUM, CvePS, PU, -1) Then
If Not ObjInventario.AddMovimientoDetalle(CveAlmacenVirutal, CantidadEntrada, CveUM, CvePS, PU, -1) Then
ErrorMovInv = True
TextoError = "Ocurrió un error al procesar los conceptos de traspaso de apartado. Por favor vuelva a intentar."
Exit For
@@ -2430,7 +2430,7 @@ Partial Class Inventarios_RecepcionEntrega
Catch ex As Exception
ErrorMovInv = True
OnError("Ocurrió un error al guardar",ex)
OnError("Ocurrió un error al guardar", ex)
End Try
If Not ErrorMovInv Then

View File

@@ -510,7 +510,7 @@ Partial Class Inventarios_RecepcionUsados
End Sub
Private Sub CargaSubProyectosUsados()
If UsuarioActual.CveEmpresa = 140 Then
If UsuarioActual.Empresa.Funcionalidad(531) = "1" Then
DivRecepcionUsados.Visible = True
If Not UsuarioActual.TienePermisoProceso(190) Then

View File

@@ -1445,14 +1445,6 @@ Partial Class Inventarios_TraspasoAlmacen
Protected Sub BtnRecibir_Click(sender As Object, e As EventArgs)
If GvDatosRecepcion.Rows.Count > 0 Then
Dim ObjInventarios As New ClsInventarios
Dim Dtt As DataTable = Nothing
If ObjInventarios.GetMovimientosTransitorios(CveAlmacenDestino, -1, CveAlmacenTransitorio, -1, FolioBusqueda, UsuarioActual.CveEmpresa) Then
Dtt = ObjInventarios.DtResultados.FiltraParametros(String.Format("CveTipoAlmacenDestino <> 4"), "", {"Codigo", "Cantidad"})
End If
ObjInventarios.Dispose()
'Valida Movimientos
Dim ValidaMovtos = 0.0
For Each gvr As GridViewRow In GvDatosRecepcion.Rows
@@ -1474,13 +1466,24 @@ Partial Class Inventarios_TraspasoAlmacen
End If
Dim ObjInventario As New ClsInventarios
Dim Dtt As DataTable = Nothing
Dim CveMovimientoEntrada As Integer = 0
Dim Folio = 0
Dim ErrorMovInv As Boolean = False
Dim TextoError = ""
'REGISTRA LA SALIDA Y ENTRADA (TRASPASO)
'' verifica que no se halla recibido previamente, si ya se recibió da salida
If ObjInventario.GetMovimientosTransitorios(CveAlmacenDestino, -1, CveAlmacenTransitorio, -1, FolioBusqueda, UsuarioActual.CveEmpresa) Then
Dtt = ObjInventario.DtResultados.FiltraParametros(String.Format("CveTipoAlmacenDestino <> 4"), "", {"Codigo", "Cantidad"})
If Dtt IsNot Nothing AndAlso Dtt.FiltraParametros("Cantidad < 0").Rows.Count > 0 Then
ObjInventario.Dispose()
Alert("El traspaso no se ha puede completar, por inconsistencia en las cantidades recibidas")
Exit Sub
End If
End If
'REGISTRA LA SALIDA Y ENTRADA (TRASPASO)
ObjInventario.IniciaTransacSQL() 'Inicia la transacción
Dim Fecha As Date = TxtFechaRecepcion.Text.ToDate

View File

@@ -13040,6 +13040,8 @@ Partial Class Ventas
Else
LblTotalPS.Text = "0.00"
End If
LblPrecio1.Text = TxtPrecio.Text
UPPDescuento.Update()
HdnIVAPS.Value = If(drPS("IVA").ToString = "-1", ViewState("IVA"), drPS("IVA").ToString).ToString
HdnIVARetAPS.Value = drPS("RetIVA").ToString