E72. EntregaAlmacen. Sugerir serie si tiene en apartados
This commit is contained in:
@@ -2955,7 +2955,8 @@ Public Class ClsInventarios
|
|||||||
|
|
||||||
Return Retorno
|
Return Retorno
|
||||||
End Function
|
End Function
|
||||||
Public Function SerieRecomendadoGet(CvePS As Integer, CveEmpresa As Integer, Optional CveAlmacen As Integer = -1, Optional CveSeccionAlmacen As Integer = -1, Optional CveSubProyecto As Integer = -1) As Boolean
|
Public Function SerieRecomendadoGet(CvePS As Integer, CveEmpresa As Integer, Optional CveAlmacen As Integer = -1, Optional CveSeccionAlmacen As Integer = -1, Optional CveSubProyecto As Integer = -1,
|
||||||
|
Optional CveCliente As Integer = -1, Optional CveVendedor As Integer = -1, Optional ExcluyeApartados As Integer = -1) As Boolean
|
||||||
Dim Retorno As Boolean = False
|
Dim Retorno As Boolean = False
|
||||||
|
|
||||||
DataAdapter("PA_Inv_SerieRecomendadoGet")
|
DataAdapter("PA_Inv_SerieRecomendadoGet")
|
||||||
@@ -2966,6 +2967,9 @@ Public Class ClsInventarios
|
|||||||
.Add("@CveAlmacen", SqlDbType.Int).Value = CveAlmacen
|
.Add("@CveAlmacen", SqlDbType.Int).Value = CveAlmacen
|
||||||
.Add("@CveSeccionAlmacen", SqlDbType.Int).Value = CveSeccionAlmacen
|
.Add("@CveSeccionAlmacen", SqlDbType.Int).Value = CveSeccionAlmacen
|
||||||
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
|
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
|
||||||
|
.Add("@CveCliente", SqlDbType.Int).Value = CveCliente
|
||||||
|
.Add("@CveVendedor", SqlDbType.Int).Value = CveVendedor
|
||||||
|
.Add("@ExcluyeApartados", SqlDbType.Int).Value = ExcluyeApartados
|
||||||
End With
|
End With
|
||||||
|
|
||||||
Try
|
Try
|
||||||
|
|||||||
@@ -1078,7 +1078,7 @@ Partial Class Inventarios_EntregaAlmacen
|
|||||||
Dim DtSerie As New DataTable
|
Dim DtSerie As New DataTable
|
||||||
If TipoMovimiento = 1 Then
|
If TipoMovimiento = 1 Then
|
||||||
Dim ObjInventarios As New ClsInventarios
|
Dim ObjInventarios As New ClsInventarios
|
||||||
If ObjInventarios.SerieRecomendadoGet(CvePSSerie, UsuarioActual.CveEmpresa, DdlAlmacen.SelectedValue.ToEntero(), CveSubProyecto:=CveSubProyecto) Then
|
If ObjInventarios.SerieRecomendadoGet(CvePSSerie, UsuarioActual.CveEmpresa, DdlAlmacen.SelectedValue.ToEntero(), CveSubProyecto:=CveSubProyecto, CveCliente:=CveCliente, CveVendedor:=CveVendedor) Then
|
||||||
DtSerie = ObjInventarios.DtResultados
|
DtSerie = ObjInventarios.DtResultados
|
||||||
End If
|
End If
|
||||||
ObjInventarios.Dispose()
|
ObjInventarios.Dispose()
|
||||||
@@ -1105,6 +1105,7 @@ Partial Class Inventarios_EntregaAlmacen
|
|||||||
If DtSerie.Rows.Count > 0 Then
|
If DtSerie.Rows.Count > 0 Then
|
||||||
Dim Mensaje As New StringBuilder
|
Dim Mensaje As New StringBuilder
|
||||||
Mensaje.AppendFormat("Serie Recomendado: <b>{0}</b>", DtSerie.Rows(0)("Serie"))
|
Mensaje.AppendFormat("Serie Recomendado: <b>{0}</b>", DtSerie.Rows(0)("Serie"))
|
||||||
|
|
||||||
If AplicaCaducidad Then Mensaje.AppendFormat(", Caducicdad: <b>{0}</b>", DtSerie.Rows(0)("FechaCaducidad").ToString().ToDate.ToShortDateString)
|
If AplicaCaducidad Then Mensaje.AppendFormat(", Caducicdad: <b>{0}</b>", DtSerie.Rows(0)("FechaCaducidad").ToString().ToDate.ToShortDateString)
|
||||||
LbSerieRecomendado.Text = Mensaje.ToString() 'String.Format("Serie / Lote Recomendado: <b>{0}</b>, Caducicdad: <b>{1}</b>", ObjInventarios.DtResultados.Rows(0)("SerieLote"), ObjInventarios.DtResultados.Rows(0)("FechaCaducidad").ToString().ToDate.ToShortDateString)
|
LbSerieRecomendado.Text = Mensaje.ToString() 'String.Format("Serie / Lote Recomendado: <b>{0}</b>, Caducicdad: <b>{1}</b>", ObjInventarios.DtResultados.Rows(0)("SerieLote"), ObjInventarios.DtResultados.Rows(0)("FechaCaducidad").ToString().ToDate.ToShortDateString)
|
||||||
Else
|
Else
|
||||||
|
|||||||
Reference in New Issue
Block a user