campo serie agregado
This commit is contained in:
@@ -36,7 +36,6 @@ Partial Class Inventarios_TrasladoSolicitud
|
||||
ViewState("CveDireccionEnvio") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
'Private Property CveUsuarioAutoriza As Integer
|
||||
' Get
|
||||
' If ViewState("CveUsuarioAutoriza") Is Nothing Then
|
||||
@@ -94,8 +93,9 @@ Partial Class Inventarios_TrasladoSolicitud
|
||||
TempDT.Columns.Add("Precio", Type.GetType("System.Double"))
|
||||
TempDT.Columns.Add("Observaciones", Type.GetType("System.String"))
|
||||
TempDT.Columns.Add("CveContratoDetalle", Type.GetType("System.Int32"))
|
||||
'TempDT.Columns.Add("CveContratoDetalle", Type.GetType("System.Int32"))
|
||||
'TempDT.Columns.Add("CveDireccionEnvio", Type.GetType("System.Int32"))
|
||||
'TempDT.Columns.Add("DireccionEnvio", Type.GetType("System.String"))
|
||||
TempDT.Columns.Add("Serie", Type.GetType("System.String"))
|
||||
|
||||
TempDT.Columns.Add()
|
||||
End Sub
|
||||
@@ -153,6 +153,7 @@ Partial Class Inventarios_TrasladoSolicitud
|
||||
If ObjInventarios.DtResultados.Rows.Count > 0 Then
|
||||
|
||||
GvDatos.Columns(4).Visible = False
|
||||
GvDatos.Columns(5).Visible = True
|
||||
DivFolio.Visible = True
|
||||
LbFolio.Text = ObjInventarios.DtResultados.Rows(0)("FolioTraspaso").ToString
|
||||
TxtObservaciones.Text = ObjInventarios.DtResultados.Rows(0)("ObservacionesTraspaso").ToString
|
||||
@@ -284,6 +285,7 @@ Partial Class Inventarios_TrasladoSolicitud
|
||||
End If
|
||||
ObjInventarios.Dispose()
|
||||
ObjClientes.Dispose()
|
||||
MostarSerieColumn()
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
@@ -347,6 +349,13 @@ Partial Class Inventarios_TrasladoSolicitud
|
||||
Row("UnidadMedida") = DdlUM.SelectedItem.Text
|
||||
Row("Observaciones") = ""
|
||||
|
||||
If Div4.Visible Then
|
||||
Row("Serie") = TxtSerie.Text
|
||||
GvDatos.Columns(5).Visible = True
|
||||
Else
|
||||
Row("Serie") = "-1"
|
||||
End If
|
||||
|
||||
Dim ObjInventarios As New ClsInventarios
|
||||
Dim Existencia As Double = ObjInventarios.GetExistenciasPS(DdlProductoServicio.SelectedValue.ToEntero, DdlUM.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, DdlAlmacenOrigen.SelectedValue.ToEntero, FechaMovto:=TxtFecha.Text.ToDate.ToString("yyyy/MM/dd 23:59"))
|
||||
ObjInventarios.Dispose()
|
||||
@@ -612,8 +621,9 @@ Partial Class Inventarios_TrasladoSolicitud
|
||||
Dim Precio As Double = Row.DataKey("Precio").ToEntero
|
||||
Dim Observaciones As String = Row.DataKey("Observaciones")
|
||||
Dim CveContratoDetalle As Integer = Row.DataKey("CveContratoDetalle").ToEntero
|
||||
Dim Serie As String = Row.DataKey("Serie")
|
||||
|
||||
If Not ObjInventarios.AddTrasladoSolicitudDetalle(CveTraspasoSolicitud, Cantidad, CveUM, CvePS, Precio, Observaciones, CveContratoDetalle) Then
|
||||
If Not ObjInventarios.AddTrasladoSolicitudDetalle(CveTraspasoSolicitud, Cantidad, CveUM, CvePS, Precio, Observaciones, CveContratoDetalle, Serie) Then
|
||||
TieneError = True
|
||||
Exit For
|
||||
End If
|
||||
@@ -767,6 +777,7 @@ Partial Class Inventarios_TrasladoSolicitud
|
||||
params.Add(New ReportParameter("Paqueteria", DdlPaqueteria.SelectedItem.Text))
|
||||
params.Add(New ReportParameter("NumeroContrato", NumContrato))
|
||||
params.Add(New ReportParameter("FechaEnvio", TxtFecha.Text.Substring(0, 10)))
|
||||
params.Add(New ReportParameter("TieneSerie", GvDatos.Columns(5).Visible.ToString()))
|
||||
|
||||
Dim RutaFormato As String = String.Format("Empresas\{0}\Formatos\RepTrasladoSolicitud.rdlc", UsuarioActual.CveEmpresa)
|
||||
Dim RutaFormatoDefault As String = String.Format("Empresas\Grales\Formatos\RepTrasladoSolicitud.rdlc")
|
||||
@@ -963,6 +974,8 @@ Partial Class Inventarios_TrasladoSolicitud
|
||||
DdlUM.SelectedValue = "-1"
|
||||
DdlUM.DataBind()
|
||||
DdlUM.SelectedValueExist(drPS("CveUnidadMedida").ToString)
|
||||
Dim AplicaSerie As Boolean = drPS("AplicaSerie").ToString = "True"
|
||||
Div4.Visible = AplicaSerie
|
||||
End If
|
||||
UpPS.Update()
|
||||
UpDatos.Update()
|
||||
@@ -1028,16 +1041,20 @@ Partial Class Inventarios_TrasladoSolicitud
|
||||
Dim MandaCorre As New ClsSisMail
|
||||
MandaCorre.SendMail(ClsPaginas.EmpresaNotificaciones, CorreoDestino, $"Solicitud de Autorización de traspaso #{Folio}", SB.ToString, Displayname:="SIG Notificaciones: Solicitud de Traspaso")
|
||||
|
||||
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
Public Sub MostarSerieColumn()
|
||||
Dim Mostrar As Boolean = False
|
||||
For Each row As GridViewRow In GvDatos.Rows
|
||||
Dim Serie As String = row.DataKey("Serie").ToString
|
||||
If Serie IsNot "-1" And Serie IsNot "" Then
|
||||
Mostrar = True
|
||||
Exit For
|
||||
End If
|
||||
Next
|
||||
GvDatos.Columns(5).Visible = Mostrar
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
|
||||
Reference in New Issue
Block a user