-- al editar remision, que si tiene salida, no permita cambiar el producto
This commit is contained in:
@@ -1263,8 +1263,8 @@ Public Class Timbrado
|
|||||||
ObjCFDITimbre.Complementos.ComercioExterior11.Emisor.Pais,
|
ObjCFDITimbre.Complementos.ComercioExterior11.Emisor.Pais,
|
||||||
ObjCFDITimbre.Complementos.ComercioExterior11.Emisor.CP)
|
ObjCFDITimbre.Complementos.ComercioExterior11.Emisor.CP)
|
||||||
'RECEPTOR
|
'RECEPTOR
|
||||||
cfdi.agregarComercioExterior11Receptor(ObjCFDITimbre.Complementos.ComercioExterior11.Receptor.NumRegIdTrib)
|
cfdi.agregarComercioExterior11Receptor(ObjCFDITimbre.Complementos.ComercioExterior11.Receptor.NumRegIdTrib,
|
||||||
cfdi.agregarComercioExterior11DomicilioReceptor(ObjCFDITimbre.Complementos.ComercioExterior11.Receptor.Calle,
|
ObjCFDITimbre.Complementos.ComercioExterior11.Receptor.Calle,
|
||||||
ObjCFDITimbre.Complementos.ComercioExterior11.Receptor.NumeroExterior,
|
ObjCFDITimbre.Complementos.ComercioExterior11.Receptor.NumeroExterior,
|
||||||
ObjCFDITimbre.Complementos.ComercioExterior11.Receptor.NumeroInterior,
|
ObjCFDITimbre.Complementos.ComercioExterior11.Receptor.NumeroInterior,
|
||||||
ObjCFDITimbre.Complementos.ComercioExterior11.Receptor.Colonia,
|
ObjCFDITimbre.Complementos.ComercioExterior11.Receptor.Colonia,
|
||||||
|
|||||||
@@ -2090,54 +2090,82 @@ Partial Class Bancos_PopIEVentas
|
|||||||
IdCtaContable = UsuarioActual.Empresa.IdCuentaGananciaCambiaria
|
IdCtaContable = UsuarioActual.Empresa.IdCuentaGananciaCambiaria
|
||||||
CveCuenta = UsuarioActual.Empresa.CveCuentaGananciaCambiaria
|
CveCuenta = UsuarioActual.Empresa.CveCuentaGananciaCambiaria
|
||||||
|
|
||||||
Dim TCImpuestos As Decimal = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioVenta)
|
Dim tImporteVenta, tImportePago, Diferencia As Decimal
|
||||||
TimpocambioGeneral = TCImpuestos
|
ImporteMovimiento = 0
|
||||||
|
|
||||||
Dim Diferencia As Decimal = ((MovimientoPagar.Total * PorcentajePago) * tipoCambioVentaValuacion) - ((MovimientoPagar.Total * PorcentajePago) * tipoCambioPago) 'Añadimos la diferencia de perdida en la venta
|
If CveMonedaVenta = 1 And CveMoneda = 2 Then
|
||||||
Diferencia -= ((MovimientoPagar.IVA * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.IVA * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el IVA
|
'factura pesos, pago en dolares
|
||||||
Diferencia += ((MovimientoPagar.RetIVA * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.RetIVA * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el RetIVA
|
tImporteVenta = ((MovimientoPagar.Total * PorcentajePago) * tipoCambioVenta).RoundSQL
|
||||||
Diferencia += ((MovimientoPagar.RetISR * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.RetISR * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el RetISR
|
tImportePago = ((MovimientoPagar.Total * PorcentajePago) * tipoCambioVenta / tipoCambioPago).RoundSQL
|
||||||
Diferencia -= ((MovimientoPagar.IEPS * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.IEPS * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el IEPS
|
ElseIf CveMonedaVenta = 2 And CveMoneda = 2 Then
|
||||||
Diferencia = Math.Round(Diferencia, 2)
|
'factura dolares, pago en dolares
|
||||||
|
tImporteVenta = ((MovimientoPagar.Total * PorcentajePago) * tipoCambioVenta).RoundSQL
|
||||||
|
tImportePago = ((MovimientoPagar.Total * PorcentajePago) * tipoCambioPago).RoundSQL
|
||||||
|
ElseIf CveMonedaVenta = 2 And CveMoneda = 1 Then
|
||||||
|
'factura dolares, pago en pesos
|
||||||
|
tImporteVenta = ((MovimientoPagar.Total * PorcentajePago) * tipoCambioVenta).RoundSQL
|
||||||
|
tImportePago = ((MovimientoPagar.Total * PorcentajePago) * tipoCambioPago).RoundSQL
|
||||||
|
End If
|
||||||
|
|
||||||
|
If tImporteVenta <> tImportePago Then
|
||||||
|
If tImporteVenta < tImportePago Then
|
||||||
|
CveConcepto = 64
|
||||||
|
Else
|
||||||
|
CveConcepto = 65
|
||||||
|
End If
|
||||||
|
Diferencia = Math.Abs(tImporteVenta - tImportePago)
|
||||||
|
End If
|
||||||
|
|
||||||
|
' si tiene funcionalidad para que tome el TC de pago, que solo afecta a los impuestos
|
||||||
|
If FuncionalidadFluctuacionImpuestos Then
|
||||||
|
Dim TCImpuestos As Decimal = tipoCambioPago
|
||||||
|
TimpocambioGeneral = TCImpuestos
|
||||||
|
|
||||||
|
Diferencia -= ((MovimientoPagar.IVA * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.IVA * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el IVA
|
||||||
|
Diferencia += ((MovimientoPagar.RetIVA * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.RetIVA * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el RetIVA
|
||||||
|
Diferencia += ((MovimientoPagar.RetISR * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.RetISR * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el RetISR
|
||||||
|
Diferencia -= ((MovimientoPagar.IEPS * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.IEPS * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el IEPS
|
||||||
|
Diferencia = Math.Round(Diferencia, 2)
|
||||||
|
End If
|
||||||
|
|
||||||
|
|
||||||
'' se considera, las diferencias, y no el tipo de cambio, por el caso de las fluctuaciones
|
'' se considera, las diferencias, y no el tipo de cambio, por el caso de las fluctuaciones
|
||||||
|
|
||||||
'' si tiene funcionalidad de flucturación con ivas, tomar tipocambioventa
|
'' si tiene funcionalidad de flucturación con ivas, tomar tipocambioventa
|
||||||
If Diferencia < 0 AndAlso CveMonedaVenta = 2 Then
|
'If Diferencia < 0 AndAlso CveMonedaVenta = 2 Then
|
||||||
ImporteMovimiento = Math.Abs(Diferencia)
|
' ImporteMovimiento = Math.Abs(Diferencia)
|
||||||
ImporteMX = ImporteMovimiento
|
' ImporteMX = ImporteMovimiento
|
||||||
End If
|
'End If
|
||||||
Else
|
Else
|
||||||
ImporteMovimiento = 0
|
ImporteMovimiento = 0
|
||||||
End If
|
End If
|
||||||
CveSubProyectoContabilizar = CveSubProyectoVenta
|
CveSubProyectoContabilizar = CveSubProyectoVenta
|
||||||
|
|
||||||
Case 65 'Perdida
|
'Case 65 'Perdida
|
||||||
If CveMoneda <> 1 OrElse CveMonedaVenta <> 1 Then
|
' If CveMoneda <> 1 OrElse CveMonedaVenta <> 1 Then
|
||||||
IdCtaContable = UsuarioActual.Empresa.IdCuentaPerdidaCambiaria
|
' IdCtaContable = UsuarioActual.Empresa.IdCuentaPerdidaCambiaria
|
||||||
CveCuenta = UsuarioActual.Empresa.CveCuentaPerdidaCambiaria
|
' CveCuenta = UsuarioActual.Empresa.CveCuentaPerdidaCambiaria
|
||||||
|
|
||||||
Dim TCImpuestos As Decimal = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioVenta)
|
' Dim TCImpuestos As Decimal = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioVenta)
|
||||||
TimpocambioGeneral = TCImpuestos
|
' TimpocambioGeneral = TCImpuestos
|
||||||
|
|
||||||
|
|
||||||
Dim Diferencia As Decimal = ((MovimientoPagar.Total * PorcentajePago) * tipoCambioVentaValuacion) - ((MovimientoPagar.Total * PorcentajePago) * tipoCambioPago) 'Añadimos la diferencia de perdida en la venta
|
' Dim Diferencia As Decimal = ((MovimientoPagar.Total * PorcentajePago) * tipoCambioVentaValuacion) - ((MovimientoPagar.Total * PorcentajePago) * tipoCambioPago) 'Añadimos la diferencia de perdida en la venta
|
||||||
Diferencia -= ((MovimientoPagar.IVA * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.IVA * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el IVA
|
' Diferencia -= ((MovimientoPagar.IVA * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.IVA * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el IVA
|
||||||
Diferencia += ((MovimientoPagar.RetIVA * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.RetIVA * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el RetIVA
|
' Diferencia += ((MovimientoPagar.RetIVA * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.RetIVA * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el RetIVA
|
||||||
Diferencia += ((MovimientoPagar.RetISR * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.RetISR * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el RetISR
|
' Diferencia += ((MovimientoPagar.RetISR * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.RetISR * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el RetISR
|
||||||
Diferencia -= ((MovimientoPagar.IEPS * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.IEPS * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el IEPS
|
' Diferencia -= ((MovimientoPagar.IEPS * PorcentajePago) * tipoCambioVenta) - ((MovimientoPagar.IEPS * PorcentajePago) * TCImpuestos) 'Añadimos la diferencia de ganancia en el IEPS
|
||||||
Diferencia = Math.Round(Diferencia, 2)
|
' Diferencia = Math.Round(Diferencia, 2)
|
||||||
|
|
||||||
'si la diferencia es negativa es pérdida, si es positiva es ganancia
|
' 'si la diferencia es negativa es pérdida, si es positiva es ganancia
|
||||||
If Diferencia > 0 AndAlso CveMonedaVenta = 2 Then
|
' If Diferencia > 0 AndAlso CveMonedaVenta = 2 Then
|
||||||
ImporteMovimiento = Math.Abs(Diferencia)
|
' ImporteMovimiento = Math.Abs(Diferencia)
|
||||||
ImporteMX = ImporteMovimiento
|
' ImporteMX = ImporteMovimiento
|
||||||
End If
|
' End If
|
||||||
Else
|
' Else
|
||||||
ImporteMovimiento = 0
|
' ImporteMovimiento = 0
|
||||||
End If
|
' End If
|
||||||
CveSubProyectoContabilizar = CveSubProyectoVenta
|
' CveSubProyectoContabilizar = CveSubProyectoVenta
|
||||||
|
|
||||||
Case 30
|
Case 30
|
||||||
If RBLContado.SelectedValue = "1" Then
|
If RBLContado.SelectedValue = "1" Then
|
||||||
|
|||||||
BIN
Bin/RVCFDI33.dll
BIN
Bin/RVCFDI33.dll
Binary file not shown.
@@ -6307,7 +6307,7 @@ Partial Class Compras_Compras
|
|||||||
Case 6 'Compra
|
Case 6 'Compra
|
||||||
|
|
||||||
Dim AgregaMercanciaInventario As Boolean = UsuarioActual.CveEmpresa.Contiene(1, 72, 80, 119, 140, 141) AndAlso UsuarioActual.Empresa.UsaInventarios AndAlso Not UsuarioActual.Empresa.Funcionalidad(126) = "1"
|
Dim AgregaMercanciaInventario As Boolean = UsuarioActual.CveEmpresa.Contiene(1, 72, 80, 119, 140, 141) AndAlso UsuarioActual.Empresa.UsaInventarios AndAlso Not UsuarioActual.Empresa.Funcionalidad(126) = "1"
|
||||||
Dim RegistraConcepto225 As Boolean = UsuarioActual.Empresa.UsaInventarios AndAlso DdlTipoComprobante.SelectedValue.Contiene("NC", "DEV") AndAlso Not UsuarioActual.Empresa.Funcionalidad(126) = "1"
|
Dim RegistraConcepto225 As Boolean = UsuarioActual.Empresa.UsaInventarios AndAlso DdlTipoComprobante.SelectedValue.Contiene("DEV") AndAlso Not UsuarioActual.Empresa.Funcionalidad(126) = "1"
|
||||||
|
|
||||||
If RBLPago.SelectedValue.ToEntero = 4 Then
|
If RBLPago.SelectedValue.ToEntero = 4 Then
|
||||||
Exit Select 'Es credito el concepto 6 se agrega en CASE 17
|
Exit Select 'Es credito el concepto 6 se agrega en CASE 17
|
||||||
@@ -6645,18 +6645,22 @@ Partial Class Compras_Compras
|
|||||||
importeMN = importeMovimiento * tipoCambioActual * Multiplicador '[IPP] EL 6 DEBE SER POSITIVO 27/AGOSTO/2018
|
importeMN = importeMovimiento * tipoCambioActual * Multiplicador '[IPP] EL 6 DEBE SER POSITIVO 27/AGOSTO/2018
|
||||||
|
|
||||||
'CLASIFICACION
|
'CLASIFICACION
|
||||||
If Row2("CveClasificacion").ToString.ToEntero > 0 Then
|
If Row2("CveClasificacion").ToString.ToEntero > 0 AndAlso DdlTipoComprobante.SelectedValue = "FAC" Then
|
||||||
|
|
||||||
If ObjConta.GetRetCuenta(6, Row2("CveClasificacion").ToString.ToEntero, CveSubProyecto:=Row2("CveSubProyecto").ToString.ToEntero) Then
|
If ObjConta.GetRetCuenta(6, Row2("CveClasificacion").ToString.ToEntero, CveSubProyecto:=Row2("CveSubProyecto").ToString.ToEntero) Then
|
||||||
If ObjConta.DtResultados.Rows.Count > 0 AndAlso ObjConta.DtResultados.Rows(0)("IdCuentaGasto").ToString.ToEntero > 0 Then
|
If ObjConta.DtResultados.Rows.Count > 0 AndAlso ObjConta.DtResultados.Rows(0)("IdCuentaGasto").ToString.ToEntero > 0 Then
|
||||||
IdCtaContable = ObjConta.DtResultados.Rows(0)("IdCuentaGasto").ToString.ToEntero
|
IdCtaContable = ObjConta.DtResultados.Rows(0)("IdCuentaGasto").ToString.ToEntero
|
||||||
CveCuenta = ObjConta.DtResultados.Rows(0)("IdCuentaGastoSIG").ToString.ToEntero
|
' CveCuenta = ObjConta.DtResultados.Rows(0)("IdCuentaGastoSIG").ToString.ToEntero
|
||||||
Else
|
Else
|
||||||
IdCtaContable = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCuentaGasto", String.Format("CveClasificacion = {0}", Row2("CveClasificacion"))).ToString.ToEntero
|
IdCtaContable = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCuentaGasto", String.Format("CveClasificacion = {0}", Row2("CveClasificacion"))).ToString.ToEntero
|
||||||
CveCuenta = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCuentaGastoSIG", String.Format("CveClasificacion = {0}", Row2("CveClasificacion"))).ToString.ToEntero
|
' CveCuenta = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCuentaGastoSIG", String.Format("CveClasificacion = {0}", Row2("CveClasificacion"))).ToString.ToEntero
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
'SEGMENTO DE NEGOCIO
|
'SEGMENTO DE NEGOCIO
|
||||||
Dim IdSegmentoNegocio As Integer = -1
|
Dim IdSegmentoNegocio As Integer = -1
|
||||||
Dim drT As DataRow = GlobalDTSubProyectos(-1, CveSubProyecto:=Row2("CveSubProyecto").ToString.ToEntero).FiltroPrimero(String.Format("CveSubProyecto = {0} ", Row2("CveSubProyecto").ToString.ToEntero))
|
Dim drT As DataRow = GlobalDTSubProyectos(-1, CveSubProyecto:=Row2("CveSubProyecto").ToString.ToEntero).FiltroPrimero(String.Format("CveSubProyecto = {0} ", Row2("CveSubProyecto").ToString.ToEntero))
|
||||||
@@ -6686,6 +6690,11 @@ Partial Class Compras_Compras
|
|||||||
If DdlMoneda.SelectedValue = "2" Then
|
If DdlMoneda.SelectedValue = "2" Then
|
||||||
tidctacon = ViewState("CtaProveedorAnticiposExtranjera").ToString.ToEntero
|
tidctacon = ViewState("CtaProveedorAnticiposExtranjera").ToString.ToEntero
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
ElseIf DdlTipoComprobante.SelectedValue = "NC" Then
|
||||||
|
tcvecon = 259
|
||||||
|
tidctacon = UsuarioActual.Empresa.Funcionalidad(405).ToEntero
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim usacomplementariaProveedor As Boolean = False
|
Dim usacomplementariaProveedor As Boolean = False
|
||||||
|
|||||||
@@ -464,7 +464,7 @@ Partial Class Inventarios_RecepcionEntrega
|
|||||||
|
|
||||||
GVPendientes.DataBind()
|
GVPendientes.DataBind()
|
||||||
UpPendientes.Update()
|
UpPendientes.Update()
|
||||||
DtPendientes.Dispose()
|
If DtPendientes IsNot Nothing Then DtPendientes.Dispose()
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
Protected Sub GVPendientes_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GVPendientes.RowDataBound
|
Protected Sub GVPendientes_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GVPendientes.RowDataBound
|
||||||
@@ -632,10 +632,7 @@ Partial Class Inventarios_RecepcionEntrega
|
|||||||
DdlAlmacen.SelectedValueExist(CveAlmacenTraspasoOrigen)
|
DdlAlmacen.SelectedValueExist(CveAlmacenTraspasoOrigen)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
DtDatos.Columns.Add("AplicaSeccion", GetType(Boolean))
|
|
||||||
DtDatos.Columns.Add("AplicaSerie", GetType(Boolean))
|
|
||||||
DtDatos.Columns.Add("AplicaLote", GetType(Boolean))
|
|
||||||
DtDatos.Columns.Add("AplicaCaducidad", GetType(Boolean))
|
|
||||||
If Not DtDatos.Columns.Contains("Lote") Then
|
If Not DtDatos.Columns.Contains("Lote") Then
|
||||||
DtDatos.Columns.Add("Lote", GetType(String))
|
DtDatos.Columns.Add("Lote", GetType(String))
|
||||||
End If
|
End If
|
||||||
@@ -1749,7 +1746,7 @@ Partial Class Inventarios_RecepcionEntrega
|
|||||||
For Each Dr As DataRow In DtDatos.Rows
|
For Each Dr As DataRow In DtDatos.Rows
|
||||||
If Dr("CantidadGV").ToString.ToDecimal > 0 Then
|
If Dr("CantidadGV").ToString.ToDecimal > 0 Then
|
||||||
|
|
||||||
If CBool(Dr("AplicaSeccion")) Then
|
If CBool(Dr("AplicaSerieLote")) Then
|
||||||
|
|
||||||
DtDetalle = DtDatosDetalle.FiltraParametros(String.Format("ConsecId = {0}", Dr("Consec")))
|
DtDetalle = DtDatosDetalle.FiltraParametros(String.Format("ConsecId = {0}", Dr("Consec")))
|
||||||
For Each Dr1 As DataRow In DtDetalle.Rows
|
For Each Dr1 As DataRow In DtDetalle.Rows
|
||||||
@@ -1882,7 +1879,12 @@ Partial Class Inventarios_RecepcionEntrega
|
|||||||
|
|
||||||
CantidadPendiente = If(Dr1("ExistenciaFinal").ToString.ToDecimal > CantidadSaldo, CantidadSaldo, Dr1("ExistenciaFinal").ToString.ToDecimal)
|
CantidadPendiente = If(Dr1("ExistenciaFinal").ToString.ToDecimal > CantidadSaldo, CantidadSaldo, Dr1("ExistenciaFinal").ToString.ToDecimal)
|
||||||
|
|
||||||
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoSalida, CantidadPendiente.ToString.ToDecimal, Dr("CveUM").ToString.ToEntero, Dr("CvePS").ToString.ToEntero, 0, -1, CveVentaDetalle:=Dr("CveVentaDetalle").ToString.ToEntero, FechaCaducidad:=If(CBool(Dr("AplicaCaducidad")), Dr("Caducidad").ToString.ToDate, MinFecha), Lote:=If(CBool(Dr("AplicaLote")), Dr("Lote").ToString, "-1"), CveSeccionAlmacen:=If(CBool(Dr("AplicaSeccion")), Dr("CveSeccion").ToString.ToEntero, -1)) Then
|
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoSalida, CantidadPendiente.ToString.ToDecimal, Dr("CveUM").ToString.ToEntero, Dr("CvePS").ToString.ToEntero, 0, -1,
|
||||||
|
SerieLote:=Dr("SerieLote").ToString,
|
||||||
|
CveVentaDetalle:=Dr("CveVentaDetalle").ToString.ToEntero,
|
||||||
|
FechaCaducidad:=If(CBool(Dr("AplicaCaducidad")), Dr("Caducidad").ToString.ToDate, MinFecha),
|
||||||
|
Lote:=If(CBool(Dr("AplicaLote")), Dr("Lote").ToString, "-1"),
|
||||||
|
CveSeccionAlmacen:=If(CBool(Dr("AplicaSeccion")), Dr("CveSeccion").ToString.ToEntero, -1)) Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
TextoError = "Ocurrió un error al procesar los conceptos de traspaso de apartado. Por favor vuelva a intentar."
|
TextoError = "Ocurrió un error al procesar los conceptos de traspaso de apartado. Por favor vuelva a intentar."
|
||||||
Exit For
|
Exit For
|
||||||
@@ -1894,7 +1896,8 @@ Partial Class Inventarios_RecepcionEntrega
|
|||||||
Next
|
Next
|
||||||
|
|
||||||
If ErrorMovInv Then Exit For
|
If ErrorMovInv Then Exit For
|
||||||
|
Else
|
||||||
|
ErrorMovInv = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -1038,7 +1038,7 @@ Partial Class Inventarios_RecepcionUsados
|
|||||||
|
|
||||||
Dim GenerarRNC As Boolean = False
|
Dim GenerarRNC As Boolean = False
|
||||||
'SI ES DISTRIBUIDOR Y NO VIENE DE REMISION, GENERA UNA REMISION DE NOTA DE CREDITO
|
'SI ES DISTRIBUIDOR Y NO VIENE DE REMISION, GENERA UNA REMISION DE NOTA DE CREDITO
|
||||||
If EsDistribuidor AndAlso Me.CveRemisionRecibida <= 0 Then
|
If Me.CveRemisionRecibida <= 0 Then 'EsDistribuidor AndAlso , comentado, 2020.04.21 RMF
|
||||||
GenerarRNC = True
|
GenerarRNC = True
|
||||||
Dim CveCliente As Integer = DdlClientes.SelectedValue.ToEntero()
|
Dim CveCliente As Integer = DdlClientes.SelectedValue.ToEntero()
|
||||||
Dim CveSubProyecto = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveSubProyecto", $"CveAlmacen={DdlAlmacen.SelectedValue}").ToEntero
|
Dim CveSubProyecto = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveSubProyecto", $"CveAlmacen={DdlAlmacen.SelectedValue}").ToEntero
|
||||||
|
|||||||
@@ -370,10 +370,10 @@
|
|||||||
<th width="25px">#</th>
|
<th width="25px">#</th>
|
||||||
<th width="100px">Cantidad</th>
|
<th width="100px">Cantidad</th>
|
||||||
<th width="90px">Unidad</th>
|
<th width="90px">Unidad</th>
|
||||||
<th width="500px">Clasificación
|
<th width="500px">Clasificación
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
Producto
|
Producto
|
||||||
</th>
|
</th>
|
||||||
<th width="100px">Observaciones</th>
|
<th width="100px">Observaciones</th>
|
||||||
<th style="width: 88px" runat="server" id="ThSerieLote" visible="false">Serie - Lote </th>
|
<th style="width: 88px" runat="server" id="ThSerieLote" visible="false">Serie - Lote </th>
|
||||||
@@ -499,27 +499,27 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="titlefiltros caption ">
|
<div class="titlefiltros caption ">
|
||||||
<ul class="list-inline" style="font-size: 12px;">
|
<ul class="list-inline" style="font-size: 12px;">
|
||||||
<li>Almacén Recibe:
|
<li>Almacén Recibe:
|
||||||
|
|
||||||
<asp:DropDownList ID="DdlAlmacenRecepcion" runat="server" DataTextField="Almacen" DataValueField="CveAlmacen" CssClass="form-control input-sm select2me" Style="width: 150px !important;" ValidationGroup="GrpCargaTransitorios"></asp:DropDownList>
|
<asp:DropDownList ID="DdlAlmacenRecepcion" runat="server" DataTextField="Almacen" DataValueField="CveAlmacen" CssClass="form-control input-sm select2me" Style="width: 150px !important;" ValidationGroup="GrpCargaTransitorios"></asp:DropDownList>
|
||||||
<%--<asp:RequiredFieldValidator ID="RFVAlmacenRecepcion" runat="server" ControlToValidate="DdlAlmacenRecepcion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Almacen Recibe''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpCargaTransitorios"></asp:RequiredFieldValidator>--%>
|
<%--<asp:RequiredFieldValidator ID="RFVAlmacenRecepcion" runat="server" ControlToValidate="DdlAlmacenRecepcion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Almacen Recibe''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpCargaTransitorios"></asp:RequiredFieldValidator>--%>
|
||||||
<%--<ajax:ValidatorCalloutExtender ID="VCEAlmacenRecepcion" runat="server" HighlightCssClass="vco" TargetControlID="RFVAlmacenRecepcion" Width="350px"></ajax:ValidatorCalloutExtender>--%>
|
<%--<ajax:ValidatorCalloutExtender ID="VCEAlmacenRecepcion" runat="server" HighlightCssClass="vco" TargetControlID="RFVAlmacenRecepcion" Width="350px"></ajax:ValidatorCalloutExtender>--%>
|
||||||
</li>
|
</li>
|
||||||
<li>Almacén Transitorio:
|
<li>Almacén Transitorio:
|
||||||
|
|
||||||
<asp:DropDownList ID="DdlAlmacenTransitorioRecepcion" runat="server" DataTextField="Almacen" DataValueField="CveAlmacen" CssClass="form-control input-sm select2me" Style="width: 150px !important;" ValidationGroup="GrpCargaTransitorios"></asp:DropDownList>
|
<asp:DropDownList ID="DdlAlmacenTransitorioRecepcion" runat="server" DataTextField="Almacen" DataValueField="CveAlmacen" CssClass="form-control input-sm select2me" Style="width: 150px !important;" ValidationGroup="GrpCargaTransitorios"></asp:DropDownList>
|
||||||
<asp:RequiredFieldValidator ID="RFVAlmacenTransitorioRecepcion" runat="server" ControlToValidate="DdlAlmacenTransitorioRecepcion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Almacen Transitorio''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpCargaTransitorios"></asp:RequiredFieldValidator>
|
<asp:RequiredFieldValidator ID="RFVAlmacenTransitorioRecepcion" runat="server" ControlToValidate="DdlAlmacenTransitorioRecepcion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Almacen Transitorio''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpCargaTransitorios"></asp:RequiredFieldValidator>
|
||||||
<ajax:ValidatorCalloutExtender ID="VCEAlmacenTransitorioRecepcion" runat="server" HighlightCssClass="vco" TargetControlID="RFVAlmacenTransitorioRecepcion" Width="350px"></ajax:ValidatorCalloutExtender>
|
<ajax:ValidatorCalloutExtender ID="VCEAlmacenTransitorioRecepcion" runat="server" HighlightCssClass="vco" TargetControlID="RFVAlmacenTransitorioRecepcion" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||||
</li>
|
</li>
|
||||||
<li>Folio:
|
<li>Folio:
|
||||||
|
|
||||||
<asp:TextBox ID="TxtFolioRecepcion" runat="server" Width="70px"></asp:TextBox>
|
<asp:TextBox ID="TxtFolioRecepcion" runat="server" Width="70px"></asp:TextBox>
|
||||||
<ajax:FilteredTextBoxExtender ID="SoloNumeros2" runat="server" TargetControlID="TxtFolioRecepcion" FilterType="Numbers" />
|
<ajax:FilteredTextBoxExtender ID="SoloNumeros2" runat="server" TargetControlID="TxtFolioRecepcion" FilterType="Numbers" />
|
||||||
</li>
|
</li>
|
||||||
<%--<li>Transportista/Responsable:
|
<%--<li>Transportista/Responsable:
|
||||||
<asp:DropDownList ID="DdlResponsableRecepcion" runat="server" DataTextField="Nombre" DataValueField="CveUsuario" Class="table-group-action-input form-control input-inline input-small input-sm" Style="width: 200px !important;"></asp:DropDownList>
|
<asp:DropDownList ID="DdlResponsableRecepcion" runat="server" DataTextField="Nombre" DataValueField="CveUsuario" Class="table-group-action-input form-control input-inline input-small input-sm" Style="width: 200px !important;"></asp:DropDownList>
|
||||||
<asp:RequiredFieldValidator ID="RFVResponsableRecepcion" runat="server" ControlToValidate="DdlResponsableRecepcion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Almacen Transitorio''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpCargaTransitorios"></asp:RequiredFieldValidator>
|
<asp:RequiredFieldValidator ID="RFVResponsableRecepcion" runat="server" ControlToValidate="DdlResponsableRecepcion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Almacen Transitorio''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpCargaTransitorios"></asp:RequiredFieldValidator>
|
||||||
<ajax:ValidatorCalloutExtender ID="VCEResponsableRecepcion" runat="server" HighlightCssClass="vco" TargetControlID="RFVResponsableRecepcion" Width="350px"></ajax:ValidatorCalloutExtender>
|
<ajax:ValidatorCalloutExtender ID="VCEResponsableRecepcion" runat="server" HighlightCssClass="vco" TargetControlID="RFVResponsableRecepcion" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||||
</li>--%>
|
</li>--%>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
@@ -587,7 +587,7 @@
|
|||||||
<div style="text-align: center;" class="col-sm-12">
|
<div style="text-align: center;" class="col-sm-12">
|
||||||
<asp:UpdatePanel runat="server">
|
<asp:UpdatePanel runat="server">
|
||||||
<ContentTemplate>
|
<ContentTemplate>
|
||||||
<asp:Button ID="BtnRecibir" runat="server" Text="Recibir Traspaso" OnClick="BtnRecibir_Click" class="btn btn-primary" ValidationGroup="GrpRecibir" />
|
<asp:Button ID="BtnRecibir" runat="server" Text="Recibir Traspaso" OnClick="BtnRecibir_Click" class="btn btn-primary" ValidationGroup="GrpRecibir" />
|
||||||
|
|
||||||
<asp:Button ID="BtnCancelarTraspaso" runat="server" Text="Cancelar Traspaso" OnClick="BtnCancelarTraspaso_Click" class="btn btn-danger" Visible="false" ValidationGroup="GrpRecibir" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea cancelar el traspaso?" data-btn-ok-label="si" />
|
<asp:Button ID="BtnCancelarTraspaso" runat="server" Text="Cancelar Traspaso" OnClick="BtnCancelarTraspaso_Click" class="btn btn-danger" Visible="false" ValidationGroup="GrpRecibir" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea cancelar el traspaso?" data-btn-ok-label="si" />
|
||||||
</ContentTemplate>
|
</ContentTemplate>
|
||||||
@@ -634,8 +634,8 @@
|
|||||||
<asp:GridView ID="GvDatosRecepcion" DataKeyNames="CveMovimiento,CveUM,CvePS,PS,CveAF,CodigoBarras,CveAlmacen,CveAlmacenDestino,AplicaSerieLote,CveMovimientoDetalle,PU,CveAlmacenSalida,CveMovimientoSalida,SerieLote,Lote,Batch,Cantidad, GastoIndirectoSalida, Importe,Codigo" runat="server" AutoGenerateColumns="False" EmptyDataText="No hay movimientos pendientes" ToolTip="Listado de Movimientos" CssClass="table table-hover Widthall" GridLines="None">
|
<asp:GridView ID="GvDatosRecepcion" DataKeyNames="CveMovimiento,CveUM,CvePS,PS,CveAF,CodigoBarras,CveAlmacen,CveAlmacenDestino,AplicaSerieLote,CveMovimientoDetalle,PU,CveAlmacenSalida,CveMovimientoSalida,SerieLote,Lote,Batch,Cantidad, GastoIndirectoSalida, Importe,Codigo" runat="server" AutoGenerateColumns="False" EmptyDataText="No hay movimientos pendientes" ToolTip="Listado de Movimientos" CssClass="table table-hover Widthall" GridLines="None">
|
||||||
<Columns>
|
<Columns>
|
||||||
<asp:TemplateField ItemStyle-Width="5%" ItemStyle-HorizontalAlign="Center">
|
<asp:TemplateField ItemStyle-Width="5%" ItemStyle-HorizontalAlign="Center">
|
||||||
<%--<HeaderTemplate>
|
<%--<HeaderTemplate>
|
||||||
<input type="checkbox" id="ChkAll" onclick="CheckAll();" />
|
<input type="checkbox" id="ChkAll" onclick="CheckAll();" />
|
||||||
</HeaderTemplate>--%>
|
</HeaderTemplate>--%>
|
||||||
<ItemTemplate>
|
<ItemTemplate>
|
||||||
<asp:CheckBox ID="Chk" Checked="true" runat="server"></asp:CheckBox>
|
<asp:CheckBox ID="Chk" Checked="true" runat="server"></asp:CheckBox>
|
||||||
@@ -699,18 +699,18 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-xs-4">
|
<div class="col-xs-4">
|
||||||
Con copia para:<br />
|
Con copia para:<br />
|
||||||
(Separar con: ;)
|
(Separar con: ;)
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="col-xs-8">
|
<div class="col-xs-8">
|
||||||
<asp:TextBox ID="TxtCC" runat="server" TextMode="MultiLine" Columns="3" Rows="3" CssClass="form-control"></asp:TextBox>
|
<asp:TextBox ID="TxtCC" runat="server" TextMode="MultiLine" Columns="3" Rows="3" CssClass="form-control"></asp:TextBox>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<%--<div class="row">
|
<%--<div class="row">
|
||||||
<div class="col-xs-4">Texto Adicional:</div>
|
<div class="col-xs-4">Texto Adicional:</div>
|
||||||
<div class="col-xs-8">
|
<div class="col-xs-8">
|
||||||
<asp:TextBox ID="TxtAdicional" runat="server" TextMode="MultiLine" Columns="3" Rows="3" CssClass="form-control"></asp:TextBox>
|
<asp:TextBox ID="TxtAdicional" runat="server" TextMode="MultiLine" Columns="3" Rows="3" CssClass="form-control"></asp:TextBox>
|
||||||
</div>
|
</div>
|
||||||
</div>--%>
|
</div>--%>
|
||||||
</ContentTemplate>
|
</ContentTemplate>
|
||||||
</asp:UpdatePanel>
|
</asp:UpdatePanel>
|
||||||
@@ -876,87 +876,87 @@
|
|||||||
</asp:Content>
|
</asp:Content>
|
||||||
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
|
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
|
||||||
|
|
||||||
<script type="text/javascript" language="javascript">
|
<script type="text/javascript" language="javascript">
|
||||||
|
|
||||||
function ValidaCantidad(input, valorInicial) {
|
function ValidaCantidad(input, valorInicial) {
|
||||||
var ValorActual = input.value;
|
var ValorActual = input.value;
|
||||||
if (ValorActual > valorInicial) {
|
if (ValorActual > valorInicial) {
|
||||||
//alert("El valor no puede ser mayor a la cantidad inicial: " + valorInicial);
|
//alert("El valor no puede ser mayor a la cantidad inicial: " + valorInicial);
|
||||||
input.value = valorInicial;
|
input.value = valorInicial;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function ImprimirTraslado(clave) {
|
function ImprimirTraslado(clave) {
|
||||||
$get('BtnImprimirTraspaso').click();
|
$get('BtnImprimirTraspaso').click();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function Focus() {
|
function Focus() {
|
||||||
$('#TxtCodigoPS').focus()
|
$('#TxtCodigoPS').focus()
|
||||||
}
|
}
|
||||||
|
|
||||||
function Focus1() {
|
function Focus1() {
|
||||||
$('#TxtCodigoPSRecepcion').focus()
|
$('#TxtCodigoPSRecepcion').focus()
|
||||||
}
|
}
|
||||||
|
|
||||||
function Focus2() {
|
function Focus2() {
|
||||||
$('#TxtSeriePSRecepcion').focus()
|
$('#TxtSeriePSRecepcion').focus()
|
||||||
}
|
}
|
||||||
|
|
||||||
function playsonidito(NomArchivo) {
|
function playsonidito(NomArchivo) {
|
||||||
var URL = /Sonidos/ + NomArchivo
|
var URL = /Sonidos/ + NomArchivo
|
||||||
var snd = new Audio(URL);
|
var snd = new Audio(URL);
|
||||||
snd.play();
|
snd.play();
|
||||||
snd.currentTime = 0;
|
snd.currentTime = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//EXISTENCIAS ALMACEN
|
//EXISTENCIAS ALMACEN
|
||||||
$('.DdlPS').on("select2:open", function (e) { $('.select2-container.select2-container--default .select2-dropdown .select2anothertable').remove(); });
|
$('.DdlPS').on("select2:open", function (e) { $('.select2-container.select2-container--default .select2-dropdown .select2anothertable').remove(); });
|
||||||
$("body").on("mouseenter", ".select2-container.select2-container--default.select2-container--open .select2-dropdown li", function (event) {
|
$("body").on("mouseenter", ".select2-container.select2-container--default.select2-container--open .select2-dropdown li", function (event) {
|
||||||
var $this = $(this);
|
var $this = $(this);
|
||||||
var ind = $this.index();
|
var ind = $this.index();
|
||||||
$(".select2-container.select2-container--default.select2-container--open .select2-dropdown .select2anothertable tr.active").removeClass('active');
|
$(".select2-container.select2-container--default.select2-container--open .select2-dropdown .select2anothertable tr.active").removeClass('active');
|
||||||
$(".select2-container.select2-container--default.select2-container--open .select2-dropdown .select2anothertable tr:nth-child(" + (ind + 2) + ")").addClass('active');
|
$(".select2-container.select2-container--default.select2-container--open .select2-dropdown .select2anothertable tr:nth-child(" + (ind + 2) + ")").addClass('active');
|
||||||
//log($this);
|
//log($this);
|
||||||
});
|
});
|
||||||
var scrollfuncion = function () {
|
var scrollfuncion = function () {
|
||||||
var stop = this.scrollTop;
|
var stop = this.scrollTop;
|
||||||
$(".select2-container.select2-container--default.select2-container--open .select2-dropdown .select2anothertable").scrollTop(stop);
|
$(".select2-container.select2-container--default.select2-container--open .select2-dropdown .select2anothertable").scrollTop(stop);
|
||||||
}
|
}
|
||||||
|
|
||||||
function CargaExistenciaAlmacenes(data, params) {
|
function CargaExistenciaAlmacenes(data, params) {
|
||||||
var div = $('<div class="select2anothertable"></div>');
|
var div = $('<div class="select2anothertable"></div>');
|
||||||
$('.select2-container.select2-container--default.select2-container--open .select2-dropdown .select2anothertable').remove();
|
$('.select2-container.select2-container--default.select2-container--open .select2-dropdown .select2anothertable').remove();
|
||||||
$('.select2-container.select2-container--default.select2-container--open .select2-dropdown').prepend(div);
|
$('.select2-container.select2-container--default.select2-container--open .select2-dropdown').prepend(div);
|
||||||
var table = $('<table></table>'); div.append(table);
|
var table = $('<table></table>'); div.append(table);
|
||||||
var tbody = $('<tbody></tbody>'); table.append(tbody);
|
var tbody = $('<tbody></tbody>'); table.append(tbody);
|
||||||
$(".select2-container--default .select2-results>.select2-results__options").off("scroll", scrollfuncion);
|
$(".select2-container--default .select2-results>.select2-results__options").off("scroll", scrollfuncion);
|
||||||
$(".select2-container--default .select2-results>.select2-results__options").scroll(scrollfuncion);
|
$(".select2-container--default .select2-results>.select2-results__options").scroll(scrollfuncion);
|
||||||
var indexd = 0;
|
var indexd = 0;
|
||||||
data.forEach(function (item) {
|
data.forEach(function (item) {
|
||||||
if (indexd == 0) {
|
if (indexd == 0) {
|
||||||
var tr = $('<tr></tr>'); tbody.append(tr);
|
var tr = $('<tr></tr>'); tbody.append(tr);
|
||||||
var td;
|
var td;
|
||||||
for (var key in item) {
|
for (var key in item) {
|
||||||
if (!(key == "text" || key == "id")) { td = $('<td style="font-weight:bold;">' + key + '</td>'); tr.append(td); }
|
if (!(key == "text" || key == "id")) { td = $('<td style="font-weight:bold;">' + key + '</td>'); tr.append(td); }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
var tr = $('<tr></tr>'); tbody.append(tr);
|
var tr = $('<tr></tr>'); tbody.append(tr);
|
||||||
|
|
||||||
var td;
|
var td;
|
||||||
for (var key in item) {
|
for (var key in item) {
|
||||||
if (!(key == "text" || key == "id")) { td = $('<td ' + ((item[key] > 0) ? 'style = "font-weight:bold;"' : '') + '>' + item[key] + '</td>'); tr.append(td); }
|
if (!(key == "text" || key == "id")) { td = $('<td ' + ((item[key] > 0) ? 'style = "font-weight:bold;"' : '') + '>' + item[key] + '</td>'); tr.append(td); }
|
||||||
}
|
}
|
||||||
indexd += 1;
|
indexd += 1;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
</asp:Content>
|
</asp:Content>
|
||||||
|
|||||||
@@ -440,7 +440,7 @@ Partial Class Inventarios_TraspasoAlmacen
|
|||||||
Private Sub CargaAlmacenOrigen()
|
Private Sub CargaAlmacenOrigen()
|
||||||
DdlAlmacenOrigen.Enabled = True
|
DdlAlmacenOrigen.Enabled = True
|
||||||
DdlAlmacenOrigen.Items.Clear()
|
DdlAlmacenOrigen.Items.Clear()
|
||||||
DdlAlmacenOrigen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1).FiltraParametros("CveTipoAlmacen NOT IN (3,4,9,10,11,21)")
|
DdlAlmacenOrigen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1).FiltraParametros("CveTipoAlmacen NOT IN (3,4,9,10,11)")
|
||||||
DdlAlmacenOrigen.Items.Insert(0, New ListItem(" Seleccione ", "-1"))
|
DdlAlmacenOrigen.Items.Insert(0, New ListItem(" Seleccione ", "-1"))
|
||||||
DdlAlmacenOrigen.SelectedValue = "-1"
|
DdlAlmacenOrigen.SelectedValue = "-1"
|
||||||
DdlAlmacenOrigen.DataBind()
|
DdlAlmacenOrigen.DataBind()
|
||||||
@@ -1598,6 +1598,43 @@ Partial Class Inventarios_TraspasoAlmacen
|
|||||||
' TextoError = "Ocurrió un error al obtener los movimientos de salida"
|
' TextoError = "Ocurrió un error al obtener los movimientos de salida"
|
||||||
'End If
|
'End If
|
||||||
|
|
||||||
|
'VIRTUAL ENTRADA
|
||||||
|
Dim CveMovimientoVirtualEntrada As Integer = 0
|
||||||
|
Dim FolioVirtualEntrada As Integer = 0
|
||||||
|
If UsuarioActual.Empresa.Funcionalidad(573) = "1" Then
|
||||||
|
Dim CveSubProyecto As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveSubProyecto", $"CveAlmacen= {DdlAlmacenRecepcion.SelectedValue}").ToEntero()
|
||||||
|
|
||||||
|
Dim CveAlmacenVirtual As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveAlmacen", $" CveTipoAlmacen =24 AND CveSubProyecto={CveSubProyecto}").ToEntero()
|
||||||
|
|
||||||
|
If CveAlmacenVirtual > 0 Then
|
||||||
|
|
||||||
|
CveMovimientoVirtualEntrada = ObjInventario.AddMovimiento(CveAlmacenVirtual, 36, 1, TxtFecha.Text.ToDate, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, -1, -1, -1, Observaciones:=TxtObservaciones.Text.Trim, Modulo:="TA/S2")
|
||||||
|
FolioVirtualEntrada = ObjInventario.Folio
|
||||||
|
Dim dtvirtual As DataTable = Nothing
|
||||||
|
|
||||||
|
If CveMovimientoVirtualEntrada > 0 AndAlso ObjInventario.GetMovimientosDetalleVirtual(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
|
||||||
|
dtvirtual = ObjInventario.DtResultados
|
||||||
|
For Each RowVirtual As DataRow In dtvirtual.Rows
|
||||||
|
Dim CvePS = RowVirtual("CvePS").ToString().ToEntero()
|
||||||
|
Dim CantidadUsado As Decimal = RowVirtual("Cantidad").ToString().ToDecimal()
|
||||||
|
Dim PU As Decimal = RowVirtual("PU").ToString().ToDecimal()
|
||||||
|
Dim CveUM As Integer = RowVirtual("CveUM").ToString().ToEntero()
|
||||||
|
|
||||||
|
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoVirtualEntrada, CantidadUsado, CveUM, CvePS, PU, -1, CveUsuarioModifico:=UsuarioActual.CveUsuario) Then
|
||||||
|
ErrorMovInv = True
|
||||||
|
Exit For
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
Else
|
||||||
|
TextoError = "No se pudo registrar el movimiento virtual"
|
||||||
|
ErrorMovInv = True
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
TextoError = "La Sucursal no tiene creado un almacen virtual"
|
||||||
|
ErrorMovInv = True
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
If Not ErrorMovInv Then
|
If Not ErrorMovInv Then
|
||||||
Dim ImporteDecimal As Decimal = importe.ToDecimal.RoundSQL
|
Dim ImporteDecimal As Decimal = importe.ToDecimal.RoundSQL
|
||||||
Dim IdCtaContable As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCtaContable", String.Format("CveAlmacen = {0}", DdlAlmacenTransitorioRecepcion.SelectedValue.ToEntero)).ToEntero
|
Dim IdCtaContable As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCtaContable", String.Format("CveAlmacen = {0}", DdlAlmacenTransitorioRecepcion.SelectedValue.ToEntero)).ToEntero
|
||||||
|
|||||||
@@ -5802,8 +5802,12 @@ Partial Class Ventas
|
|||||||
If UsuarioActual.CveEmpresa = 119 Then
|
If UsuarioActual.CveEmpresa = 119 Then
|
||||||
e.Row.FCTextBox("TxtCantidad").Enabled = False
|
e.Row.FCTextBox("TxtCantidad").Enabled = False
|
||||||
End If
|
End If
|
||||||
'e.Row.FCDropDownList("DdlClasificacion").Enabled = False
|
|
||||||
'e.Row.FCDropDownLost("DdlPS").Enabled = False
|
'cuando ya tiene una salida, no se puede cambiar el producto
|
||||||
|
If e.Row.DBCampo("CantidadInventario").ToDouble > 0 Then
|
||||||
|
e.Row.FCDropDownList("DdlClasificacion").Enabled = False
|
||||||
|
e.Row.FCDropDownLost("DdlPS").Enabled = False
|
||||||
|
End If
|
||||||
|
|
||||||
e.Row.FCTextBox("TxtTiempoEntrega").Enabled = False
|
e.Row.FCTextBox("TxtTiempoEntrega").Enabled = False
|
||||||
e.Row.FCDropDownList("DdlProyecto").Enabled = False
|
e.Row.FCDropDownList("DdlProyecto").Enabled = False
|
||||||
@@ -5948,6 +5952,7 @@ Partial Class Ventas
|
|||||||
|
|
||||||
If Not UsuarioActual.TienePermisoProceso(169) Then ' NO VALIDA EXISTENCIAS NI COSTO - PERMISO PARA NO VALIDAR
|
If Not UsuarioActual.TienePermisoProceso(169) Then ' NO VALIDA EXISTENCIAS NI COSTO - PERMISO PARA NO VALIDAR
|
||||||
Dim CvePS As Integer = DatarowPS("CvePS").ToString.ToEntero
|
Dim CvePS As Integer = DatarowPS("CvePS").ToString.ToEntero
|
||||||
|
Dim CveUM As Integer = DatarowPS("CveUM").ToString.ToEntero
|
||||||
Dim CveTipoPS As Integer = DatarowPS("CveTipoPS").ToString.ToEntero
|
Dim CveTipoPS As Integer = DatarowPS("CveTipoPS").ToString.ToEntero
|
||||||
|
|
||||||
CantidadInventario = GvPS.Rows(e.RowIndex).DataKey("CantidadInventario").ToString.ToDecimal
|
CantidadInventario = GvPS.Rows(e.RowIndex).DataKey("CantidadInventario").ToString.ToDecimal
|
||||||
@@ -5962,7 +5967,7 @@ Partial Class Ventas
|
|||||||
Dim ObjInventarios As New ClsInventarios
|
Dim ObjInventarios As New ClsInventarios
|
||||||
Dim Existencia As Decimal
|
Dim Existencia As Decimal
|
||||||
If ValidaExistencia Then
|
If ValidaExistencia Then
|
||||||
Existencia = ObjInventarios.GetExistenciasPS(CvePS, -1, UsuarioActual.CveEmpresa, -1, FechaMovto:=DateTime.Today.AddDays(1).ToString("yyyy/MM/dd HH:mm"), CveSubProyecto:=DdlSubProyectoDatos.SelectedValue.ToEntero, CveVendedor:=DdlVendedor.SelectedValue.ToEntero, CveCliente:=If(UsuarioActual.Empresa.Funcionalidad(146) = "1", -1, CveCliente), ExcluyeAdelantado:=1, PendientePorSurtir:=1, RestringirAlmacenes:=1, ExcluyeApartados:=-1)
|
Existencia = ObjInventarios.GetExistenciasPS(CvePS, CveUM, UsuarioActual.CveEmpresa, -1, FechaMovto:=DateTime.Today.AddDays(1).ToString("yyyy/MM/dd HH:mm"), CveSubProyecto:=DdlSubProyectoDatos.SelectedValue.ToEntero, CveVendedor:=DdlVendedor.SelectedValue.ToEntero, CveCliente:=If(UsuarioActual.Empresa.Funcionalidad(146) = "1", -1, CveCliente), ExcluyeAdelantado:=1, PendientePorSurtir:=1, RestringirAlmacenes:=1, ExcluyeApartados:=-1)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim Costo As Decimal = ObjInventarios.GetCostoPS(CvePS, TxtCantidad.Text.Trim.ToDouble, -1, "-1", TxtFecha.Text.ToDate, DdlSubProyectoDatos.SelectedValue.ToEntero, CveTipoAlmacen:=1)
|
Dim Costo As Decimal = ObjInventarios.GetCostoPS(CvePS, TxtCantidad.Text.Trim.ToDouble, -1, "-1", TxtFecha.Text.ToDate, DdlSubProyectoDatos.SelectedValue.ToEntero, CveTipoAlmacen:=1)
|
||||||
@@ -11076,7 +11081,7 @@ Partial Class Ventas
|
|||||||
CveConceptoAlmacen = 18
|
CveConceptoAlmacen = 18
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim CveAlmacen = ddlAlmacen.SelectedValue.ToEntero
|
Dim CveAlmacen = ddlAlmacen.SelectedValue.ToEnteroca
|
||||||
Dim CveMovimientoInventario As Integer = ObjInventario.AddMovimiento(CveAlmacen, CveConceptoAlmacen, factura.CveMoneda, factura.Fecha, -1, factura.CveUsuario, factura.CveEmpresa, -1, factura.CveVenta, -1, -1, Modulo:="Vta/E1")
|
Dim CveMovimientoInventario As Integer = ObjInventario.AddMovimiento(CveAlmacen, CveConceptoAlmacen, factura.CveMoneda, factura.Fecha, -1, factura.CveUsuario, factura.CveEmpresa, -1, factura.CveVenta, -1, -1, Modulo:="Vta/E1")
|
||||||
|
|
||||||
If CveMovimientoInventario <= 0 Then
|
If CveMovimientoInventario <= 0 Then
|
||||||
|
|||||||
Reference in New Issue
Block a user