Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -581,7 +581,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
''' </summary>
|
''' </summary>
|
||||||
''' <param name="CveSubProyecto"></param>
|
''' <param name="CveSubProyecto"></param>
|
||||||
''' <param name="CveTiposAlmacen">Parametro sin espacios y separado por comas ["1,2,3,21"]</param>
|
''' <param name="CveTiposAlmacen">Parametro sin espacios y separado por comas ["1,2,3,21"]</param>
|
||||||
Private Sub CargaAlmacenes(CveSubProyecto As Integer, Optional CveTiposAlmacen As String = "", Optional CveTipoCompra As Integer = -1)
|
Private Sub CargaAlmacenes(CveSubProyecto As Integer, Optional CveTiposAlmacen As String = "", Optional CveTipoCompra As Integer = -1, Optional RecargaGrid As Boolean = True)
|
||||||
Dim StrAlmacenes As String = ""
|
Dim StrAlmacenes As String = ""
|
||||||
Dim Strtmp As String = If(TipoMovimiento = 2, ",21", "") ' cuando es solicitud de devolución de almacen ,considerar los almacenes de dev prov
|
Dim Strtmp As String = If(TipoMovimiento = 2, ",21", "") ' cuando es solicitud de devolución de almacen ,considerar los almacenes de dev prov
|
||||||
StrAlmacenes = $"CveTipoAlmacen IN ({If(CveTiposAlmacen.Length > 0, CveTiposAlmacen, "1,2,15,14,19" & Strtmp)}) {If(CveSubProyecto > 0, $"And CveSubProyecto = {CveSubProyecto}", "")}"
|
StrAlmacenes = $"CveTipoAlmacen IN ({If(CveTiposAlmacen.Length > 0, CveTiposAlmacen, "1,2,15,14,19" & Strtmp)}) {If(CveSubProyecto > 0, $"And CveSubProyecto = {CveSubProyecto}", "")}"
|
||||||
@@ -597,25 +597,20 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
DdlAlmacen.DataBind()
|
DdlAlmacen.DataBind()
|
||||||
If UsuarioActual.CveAlmacen > 0 Then
|
If UsuarioActual.CveAlmacen > 0 Then
|
||||||
DdlAlmacen.SelectedValueExist(UsuarioActual.CveAlmacen)
|
DdlAlmacen.SelectedValueExist(UsuarioActual.CveAlmacen)
|
||||||
RecargaporAlmacenes()
|
If RecargaGrid Then RecargaporAlmacenes()
|
||||||
End If
|
End If
|
||||||
|
|
||||||
UpGenerales.Update()
|
UpGenerales.Update()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Private Sub RecargaporAlmacenes()
|
Private Sub RecargaporAlmacenes()
|
||||||
CveTipoAlmacen = -1
|
CveTipoAlmacen = -1
|
||||||
If DdlAlmacen.SelectedValue <> "-1" Then
|
If DdlAlmacen.SelectedValue <> "-1" Then
|
||||||
|
|
||||||
Dim drr As DataRow = GlobalDTAlmacen(UsuarioActual.CveEmpresa, CveAlmacen:=DdlAlmacen.SelectedValue.ToEntero).FiltroPrimero("")
|
Dim drr As DataRow = GlobalDTAlmacen(UsuarioActual.CveEmpresa, CveAlmacen:=DdlAlmacen.SelectedValue.ToEntero).FiltroPrimero("")
|
||||||
If drr IsNot Nothing Then
|
If drr IsNot Nothing Then
|
||||||
|
|
||||||
CveTipoAlmacen = drr("CveTipoAlmacen").ToString.ToEntero
|
CveTipoAlmacen = drr("CveTipoAlmacen").ToString.ToEntero
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
CargaGVInv()
|
CargaGVInv()
|
||||||
'For Each Gvr As GridViewRow In GvInv.Rows
|
'For Each Gvr As GridViewRow In GvInv.Rows
|
||||||
' If Gvr.FCDropDownList("DdlSeccionAlmacen").SelectedValue = "-1" Then
|
' If Gvr.FCDropDownList("DdlSeccionAlmacen").SelectedValue = "-1" Then
|
||||||
@@ -1076,7 +1071,9 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
If TipoMovimiento = 3 Then
|
If TipoMovimiento = 3 Then
|
||||||
CargaAlmacenes(DtRecepcion.Rows(0)("CveSubProyecto").ToString.ToEntero, "21", CveTipoCompra)
|
CargaAlmacenes(DtRecepcion.Rows(0)("CveSubProyecto").ToString.ToEntero, "21", CveTipoCompra)
|
||||||
Else
|
Else
|
||||||
CargaAlmacenes(DtRecepcion.Rows(0)("CveSubProyecto").ToString.ToEntero, "22", CveTipoCompra)
|
Dim tTipoAlm As String = "22"
|
||||||
|
If CveTipoCompra = 16 Then tTipoAlm = "22,1,24" ' apoyos, "acumuladores sin virtual" o "virtual solo"
|
||||||
|
CargaAlmacenes(DtRecepcion.Rows(0)("CveSubProyecto").ToString.ToEntero, tTipoAlm, CveTipoCompra, RecargaGrid:=False)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Else
|
Else
|
||||||
@@ -1096,11 +1093,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
CveSubProyecto = DtRecepcion.Rows(0)("CveSubProyecto").ToString.ToEntero
|
CveSubProyecto = DtRecepcion.Rows(0)("CveSubProyecto").ToString.ToEntero
|
||||||
|
|
||||||
CveAlmacenDevolucionProveedor = DtRecepcion.Rows(0)("CveAlmacenDevolucionProveedor").ToString.ToEntero
|
CveAlmacenDevolucionProveedor = DtRecepcion.Rows(0)("CveAlmacenDevolucionProveedor").ToString.ToEntero
|
||||||
|
|
||||||
'SI ES MOTOBATERIA NO GENERA MOVIMIENTO VIRTUAL
|
'SI ES MOTOBATERIA NO GENERA MOVIMIENTO VIRTUAL
|
||||||
@@ -1112,8 +1105,8 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
DivVirtualAdvertencia.Visible = False
|
DivVirtualAdvertencia.Visible = False
|
||||||
End If
|
End If
|
||||||
|
|
||||||
'SI LA COMPRA ES DE TIPO "APOYO LOGISTICO" NO DEBE GENERAR VIRTUAL
|
'SI LA COMPRA ES DE TIPO "APOYO LOGISTICO" NO DEBE GENERAR VIRTUAL (9) y apoyo sin virtual (16)
|
||||||
If Not SumarImporteUsados AndAlso CveTipoCompra = 9 Then
|
If Not SumarImporteUsados AndAlso CveTipoCompra.Contiene(9, 16) Then
|
||||||
RealizarMovimientoVirtual = False
|
RealizarMovimientoVirtual = False
|
||||||
DivVirtualAdvertencia.Visible = False
|
DivVirtualAdvertencia.Visible = False
|
||||||
End If
|
End If
|
||||||
@@ -1447,6 +1440,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
If UsuarioActual.CveEmpresa = 119 Then
|
If UsuarioActual.CveEmpresa = 119 Then
|
||||||
DtInv = DtInv.FiltraParametros("", "PS")
|
DtInv = DtInv.FiltraParametros("", "PS")
|
||||||
End If
|
End If
|
||||||
|
If Not DtInv.Columns.Contains("Consec") Then DtInv.Columns.Add("Consec", GetType(Integer))
|
||||||
|
|
||||||
Dim AplicaSeccion, AplicaLote, AplicaCaducidad, AplicaSerie As Boolean
|
Dim AplicaSeccion, AplicaLote, AplicaCaducidad, AplicaSerie As Boolean
|
||||||
If DtInv IsNot Nothing AndAlso DtInv.Rows.Count > 0 Then
|
If DtInv IsNot Nothing AndAlso DtInv.Rows.Count > 0 Then
|
||||||
@@ -1744,7 +1738,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
Private Sub CreaDtDetalle()
|
Private Sub CreaDtDetalle()
|
||||||
If DtDatosDetalle Is Nothing Then
|
If DtDatosDetalle Is Nothing Then
|
||||||
DtDatosDetalle = New DataTable
|
DtDatosDetalle = New DataTable
|
||||||
DtDatosDetalle.Columns.Add("Consec", GetType(Integer))
|
If Not DtDatosDetalle.Columns.Contains("Consec") Then DtDatosDetalle.Columns.Add("Consec", GetType(Integer))
|
||||||
DtDatosDetalle.Columns.Add("ConsecId", GetType(Integer))
|
DtDatosDetalle.Columns.Add("ConsecId", GetType(Integer))
|
||||||
DtDatosDetalle.Columns.Add("CvePS", GetType(Integer))
|
DtDatosDetalle.Columns.Add("CvePS", GetType(Integer))
|
||||||
DtDatosDetalle.Columns.Add("CveUM", GetType(Integer))
|
DtDatosDetalle.Columns.Add("CveUM", GetType(Integer))
|
||||||
@@ -1996,7 +1990,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
Private Sub CreaDtLoteDetalle()
|
Private Sub CreaDtLoteDetalle()
|
||||||
If DtDatosLoteDetalle Is Nothing Then
|
If DtDatosLoteDetalle Is Nothing Then
|
||||||
DtDatosLoteDetalle = New DataTable
|
DtDatosLoteDetalle = New DataTable
|
||||||
DtDatosLoteDetalle.Columns.Add("Consec", GetType(Integer))
|
If Not DtDatosLoteDetalle.Columns.Contains("Consec") Then DtDatosLoteDetalle.Columns.Add("Consec", GetType(Integer))
|
||||||
DtDatosLoteDetalle.Columns.Add("ConsecId", GetType(Integer))
|
DtDatosLoteDetalle.Columns.Add("ConsecId", GetType(Integer))
|
||||||
DtDatosLoteDetalle.Columns.Add("Cantidad", GetType(Decimal))
|
DtDatosLoteDetalle.Columns.Add("Cantidad", GetType(Decimal))
|
||||||
DtDatosLoteDetalle.Columns.Add("CvePS", GetType(Integer))
|
DtDatosLoteDetalle.Columns.Add("CvePS", GetType(Integer))
|
||||||
|
|||||||
@@ -2876,6 +2876,7 @@ Partial Class Ventas
|
|||||||
TmpDT = ObjCGame.DtResultados
|
TmpDT = ObjCGame.DtResultados
|
||||||
TmpDT.Columns.Add("Costo", GetType(Decimal))
|
TmpDT.Columns.Add("Costo", GetType(Decimal))
|
||||||
TmpDT.Columns("Costo").DefaultValue = 0D
|
TmpDT.Columns("Costo").DefaultValue = 0D
|
||||||
|
If Not TmpDT.Columns.Contains("NumeroParte") Then TmpDT.Columns.Add("NumeroParte", GetType(String))
|
||||||
|
|
||||||
GvPS.DataBind()
|
GvPS.DataBind()
|
||||||
End If
|
End If
|
||||||
|
|||||||
Reference in New Issue
Block a user