- Serie,Lote, Caducidad Seccion Almacen
This commit is contained in:
@@ -2924,7 +2924,7 @@ Partial Class PV
|
||||
DtTemporal.Columns.Add("FechaCaducidad", Type.GetType("System.DateTime"))
|
||||
End If
|
||||
|
||||
GvInv.Columns(4).Visible = DtTemporal.MAX("SerieLote", "SerieLote <> ''") <> "" Or CveVenta <= 0
|
||||
GvInv.Columns(4).Visible = DtTemporal.MAX("Serie", "Serie <> ''") <> "" Or CveVenta <= 0
|
||||
GvInv.Columns(5).Visible = DtTemporal.MAX("Lote", "Lote <> ''") <> ""
|
||||
GvInv.Columns(6).Visible = DtTemporal.MAX("FechaCaducidad", "FechaCaducidad <> ''") <> ""
|
||||
|
||||
@@ -2989,7 +2989,7 @@ Partial Class PV
|
||||
|
||||
'COSTO ALMACEN
|
||||
If UsuarioActual.Empresa.Funcionalidad(129).ToEntero > 0 AndAlso UsuarioActual.CveUsuario <> 1560 Then
|
||||
Costo = ObjInventarios.GetCostoPS(dr("CvePS").ToString.ToEntero, dr("Cantidad").ToString.ToDouble, -1, dr("SerieLote").ToString, TxtFecha.Text.ToDate, -1)
|
||||
Costo = ObjInventarios.GetCostoPS(dr("CvePS").ToString.ToEntero, dr("Cantidad").ToString.ToDouble, -1, dr("Serie").ToString, TxtFecha.Text.ToDate, -1)
|
||||
CostoMenor = Costo + ((UsuarioActual.Empresa.Funcionalidad(129).ToDecimal / 100) * Costo)
|
||||
'SI EL PRECIO ES MAYOR AL COSTO, SI PASA
|
||||
If PU >= CostoMenor Then
|
||||
@@ -3000,7 +3000,7 @@ Partial Class PV
|
||||
End If
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(133).ToEntero > 0 AndAlso UsuarioActual.CveUsuario <> 1560 Then
|
||||
Costo = ObjInventarios.GetCostoPS(dr("CvePS").ToString.ToEntero, dr("Cantidad").ToString.ToDouble, -1, dr("SerieLote").ToString, TxtFecha.Text.ToDate)
|
||||
Costo = ObjInventarios.GetCostoPS(dr("CvePS").ToString.ToEntero, dr("Cantidad").ToString.ToDouble, -1, dr("Serie").ToString, TxtFecha.Text.ToDate)
|
||||
CostoMayor = Costo + ((UsuarioActual.Empresa.Funcionalidad(133).ToDecimal / 100) * Costo)
|
||||
'SI EL PRECIO ES MAYOR AL COSTO, SI PASA
|
||||
If PU <= CostoMayor Then
|
||||
@@ -3901,7 +3901,7 @@ Partial Class PV
|
||||
|
||||
Private Sub AddPS(Cantidad As Double, CveUM As Integer, UM As String, CveClasificacion As Integer, Clasificacion As String, CvePS As Integer, PS As String, Obs As String,
|
||||
PU As Double, IVA As Double, RetIVA As Double, Descuento As Double, AsientoContableVentas As Integer, IdCtaContable As Integer, AplicaParaConcepto As Boolean,
|
||||
Codigo As String, CveProyecto As Integer, Proyecto As String, CveSubProyecto As Integer, SubProyecto As String, Optional CveTipoPS As Integer = -1, Optional SerieLote As String = "",
|
||||
Codigo As String, CveProyecto As Integer, Proyecto As String, CveSubProyecto As Integer, SubProyecto As String, Optional CveTipoPS As Integer = -1, Optional Serie As String = "",
|
||||
Optional CveContratoDetalle As Integer = -1, Optional TiempoEntrega As String = "", Optional CodigoPS As String = "")
|
||||
|
||||
If Not CvePS > 0 Then
|
||||
@@ -3948,7 +3948,7 @@ Partial Class PV
|
||||
Row("Proyecto") = Proyecto
|
||||
Row("CveSubProyecto") = CveSubProyecto
|
||||
Row("SubProyecto") = SubProyecto
|
||||
Row("SerieLote") = SerieLote
|
||||
Row("Serie") = Serie
|
||||
Row("TiempoEntrega") = TiempoEntrega
|
||||
|
||||
TmpDT.Rows.Add(Row)
|
||||
@@ -4069,7 +4069,7 @@ Partial Class PV
|
||||
Private Function AgregarProductoServicio(Cantidad As Decimal, CveUM As Integer, UM As String, CveClasificacion As Integer, Clasificacion As String, CvePS As Integer, PS As String, Obs As String,
|
||||
PU As Decimal, Descuento As Decimal,
|
||||
CveProyecto As Integer, Proyecto As String, CveSubProyecto As Integer, SubProyecto As String,
|
||||
Optional SerieLote As String = "", Optional TiempoEntrega As String = "", Optional EntregaDirecta As Integer = 0,
|
||||
Optional Serie As String = "", Optional TiempoEntrega As String = "", Optional EntregaDirecta As Integer = 0,
|
||||
Optional CveContratoDetalle As Integer = 0, Optional CveVentaDetalle As Integer = 0, Optional CveMovimientoDetallePedido As Integer = 0,
|
||||
Optional CveOrdenCompraDetalle As Integer = 0, Optional CveVentaDetalleRemision As Integer = 0, Optional CveVentaDetalleCotizacion As Integer = 0,
|
||||
Optional CuentaPredial As String = "", Optional RegeneraIEPS As Boolean = True, Optional CveVentaDetallePedido2 As Integer = 0, Optional EsCargo As Boolean = False,
|
||||
@@ -4128,7 +4128,7 @@ Partial Class PV
|
||||
Row("Proyecto") = Proyecto
|
||||
Row("CveSubProyecto") = CveSubProyecto
|
||||
Row("SubProyecto") = SubProyecto
|
||||
Row("SerieLote") = SerieLote
|
||||
Row("Serie") = Serie
|
||||
Row("TiempoEntrega") = TiempoEntrega
|
||||
Row("Orden") = TmpDT.Rows.Count + 1
|
||||
Row("Cantidad") = Cantidad
|
||||
@@ -4599,7 +4599,7 @@ Partial Class PV
|
||||
Dim Consec = AgregarProductoServicio(Cantidad, DdlUnidadMedida.SelectedValue.ToEntero, DdlUnidadMedida.SelectedItem.Text, DdlClasificacion.SelectedValue.ToEntero, DdlClasificacion.SelectedItem.Text,
|
||||
CvePS, "", TxtObsPS.Text.Trim, PU, Descuento,
|
||||
CveProyecto, Proyecto, DdlSubProyectoDatos.SelectedValue.ToEntero, DdlSubProyectoDatos.SelectedItem.Text,
|
||||
SerieLote:="", TiempoEntrega:="", CuentaPredial:="", RegeneraIEPS:=ClienteDesglosaIEPS, CveVentaDetalle:=CveVentaDetalle, EsCargo:=EsCargo)
|
||||
Serie:="", TiempoEntrega:="", CuentaPredial:="", RegeneraIEPS:=ClienteDesglosaIEPS, CveVentaDetalle:=CveVentaDetalle, EsCargo:=EsCargo)
|
||||
|
||||
If CveVentaDetalle <= 0 AndAlso Not EsCargo Then
|
||||
Dim ListaPSCargo = CalculaUsados(Consec)
|
||||
@@ -5067,7 +5067,7 @@ Partial Class PV
|
||||
' 'AddPS(TxtCantidad.Text.Trim.ToDouble, DrProducto("CveUM").ToString.ToEntero, DrProducto("UnidadMedida").ToString, DrProducto("CveClasificacion").ToString.ToEntero, DrProducto("Clasificacion").ToString,
|
||||
' ' DrProducto("CvePS").ToString.ToEntero, DrProducto("PS").ToString, TxtObsPS.Text.Trim, TxtPrecio.Text.Trim.ToDouble, HdnIVAPS.Value.ToDouble, 0, 0,
|
||||
' ' -1, -1, True, DrProducto("Codigo").ToString, DdlProyecto.SelectedValue.ToEntero,
|
||||
' ' DdlProyecto.SelectedItem.Text, DdlSubProyecto.SelectedValue.ToEntero, DdlSubProyecto.SelectedItem.Text, DrProducto("CveTipoPS").ToString.ToEntero, DrProducto("Inv_CveMetodoInventario").ToString.ToEntero, SerieLote:=SerieLote, CodigoPS:=DrProducto("PSCodigo").ToString)
|
||||
' ' DdlProyecto.SelectedItem.Text, DdlSubProyecto.SelectedValue.ToEntero, DdlSubProyecto.SelectedItem.Text, DrProducto("CveTipoPS").ToString.ToEntero, DrProducto("Inv_CveMetodoInventario").ToString.ToEntero, SerieLote:=SerieLote, CodigoPS:=DrProducto("PSCodigo").ToString)
|
||||
|
||||
' LimpiaAgregar()
|
||||
' End If
|
||||
@@ -5391,17 +5391,17 @@ Partial Class PV
|
||||
Dim Index = Row.RowIndex
|
||||
Dim ObjInventarios As New ClsInventarios
|
||||
Dim Existencia = ObjInventarios.GetExistenciasPSSerie("", ddlAlmacen.SelectedValue.ToEntero, UsuarioActual.CveEmpresa)
|
||||
Dim ExistenciaActual = DtInv.SUM("Cantidad", String.Format("SerieLote = '{0}'", Row.FCTextBox("TxtSerie").Text.ToString))
|
||||
Dim ExistenciaActual = DtInv.SUM("Cantidad", String.Format("Serie = '{0}'", Row.FCTextBox("TxtSerie").Text.ToString))
|
||||
|
||||
'Valida Existencia
|
||||
If Existencia - ExistenciaActual <= 0 Then
|
||||
Alert(String.Format("Not hay existencia suficiente del producto con la Serie: <b>{0}</b>. Por favor rectifique y vuelva a intentar", Row.FCTextBox("TxtSerie").Text.ToString), TipoMensaje.MsgAdvertencia)
|
||||
Row.FCTextBox("TxtSerie").Text = ""
|
||||
Row.FCHiddenField("HdnSerie").Value = ""
|
||||
TmpDT.Rows(Index)("SerieLote") = ""
|
||||
TmpDT.Rows(Index)("Serie") = ""
|
||||
Else
|
||||
Row.FCHiddenField("HdnSerie").Value = Row.FCTextBox("TxtSerie").Text
|
||||
TmpDT.Rows(Index)("SerieLote") = Row.FCTextBox("TxtSerie").Text
|
||||
TmpDT.Rows(Index)("Serie") = Row.FCTextBox("TxtSerie").Text
|
||||
End If
|
||||
|
||||
TmpDT.AcceptChanges()
|
||||
@@ -5428,7 +5428,7 @@ Partial Class PV
|
||||
If Gvr.FCTextBox("TxtSerie").Visible = True And Gvr.FCTextBox("TxtSerie").Text.Trim <> "" Then
|
||||
|
||||
Existencia = ObjInventarios.GetExistenciasPSSerie(Gvr.FCTextBox("TxtSerie").Text.ToString, ddlAlmacen.SelectedValue.ToEntero, UsuarioActual.CveEmpresa)
|
||||
ExistenciaActual = DtInv.SUM("Cantidad", String.Format("SerieLote = '{0}'", Gvr.FCTextBox("TxtSerie").Text.Trim))
|
||||
ExistenciaActual = DtInv.SUM("Cantidad", String.Format("Serie = '{0}'", Gvr.FCTextBox("TxtSerie").Text.Trim))
|
||||
|
||||
'Valida Existencia
|
||||
If Existencia - ExistenciaActual < 0 Or Existencia = 0 Then
|
||||
|
||||
Reference in New Issue
Block a user