-merge EntregaAlmacen.aspx

This commit is contained in:
2021-06-03 18:06:08 -07:00
93 changed files with 2962 additions and 6312 deletions

View File

@@ -81,11 +81,7 @@
</li>
<li>
<asp:HyperLink ID="HplPrePoliza" Target="_blank" runat="server" Visible="false"> Ver PrePóliza</asp:HyperLink>
</li>
<li>
<asp:LinkButton runat="server" ID="LnkCambioInventarioFisico" Visible="false" CssClass="" data-toggle="tooltip" data-placement="left" OnClick="LnkCambioInventarioFisico_Click"
Text="<i class='fa fa-truck'></i> Inventario Fisico"></asp:LinkButton>
</li>
</li>
<li>
<asp:LinkButton runat="server" ID="LnkCambioVigencia" Visible="false" CssClass="" data-toggle="tooltip" data-placement="left" OnClick="LnkCambioVigencia_Click"
Text="<i class='fa fa-truck'></i> Cambiar Vigencias"></asp:LinkButton>
@@ -104,6 +100,10 @@
<asp:LinkButton runat="server" ID="LnkGenerarVirtual" Visible="false" CssClass="" data-toggle="tooltip" data-placement="left" OnClick="LnkGenerarVirtual_Click"
title="Generar Movimiento Virtual" Text="<i class='fa fa-server'></i> Generar Movimiento Virtual"></asp:LinkButton>
</li>
<li>
<asp:LinkButton runat="server" ID="LnkCambioInventarioFisico" Visible="false" CssClass="" data-toggle="tooltip" data-placement="left" OnClick="LnkCambioInventarioFisico_Click"
Text="<i class='fa fa-truck'></i> Inventario Fisico"></asp:LinkButton>
</li>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>

View File

@@ -1312,7 +1312,8 @@ Partial Class Inventarios_EntradasSalidas
Dim FechaCaducidadVal As Date = If(RowPS("AplicaCaducidad").ToString = "True", FechaCaducidad, MinFecha)
If CveMetodoInventario = 5 And (String.IsNullOrEmpty(Serie.Trim()) OrElse Serie = "-1") Then
If RowPS("AplicaSerie").ToString = "True" And (String.IsNullOrEmpty(Serie.Trim()) OrElse Serie = "-1") Then
Valido = False
Alert("El producto requiere Serie", TipoMensaje.MsgAdvertencia)
End If
@@ -1324,6 +1325,18 @@ Partial Class Inventarios_EntradasSalidas
End If
End If
Dim tCveSubProyecto As Integer
Dim drA2 As DataRow = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimero(String.Format("CveAlmacen = {0}", DdlAlmacen.SelectedValue))
If drA2 IsNot Nothing Then
tCveSubProyecto = drA2("CveSubProyecto").ToString.ToEntero
End If
If UsuarioActual.CveEmpresa = 119 AndAlso Not tCveSubProyecto.Contiene(10276) Then
FechaCaducidadVal = MinFecha
FechaCaducidad = MinFecha
Lote = ""
End If
'salida
If Valido AndAlso DdlConcepto.SelectedValue.Contiene({"3", "5", "7", "8", "11", "12", "13", "15", "16", "17", "20", "21", "30", "31"}) Then ' salida de almacen
@@ -1679,7 +1692,7 @@ Partial Class Inventarios_EntradasSalidas
'Registro la prepóliza
If ObjInventario.GetMovimientosDetalle(CveMovimiento, UsuarioActual.CveEmpresa) Then
Dim tValorInventario As Decimal = ObjInventario.DtResultados.SUM("Total", "").ToDecimal.RoundSQL()
Dim tValorInventario As Decimal = ObjInventario.DtResultados.SUMD("Total", "").RoundSQL()
Dim tValorOtro As Decimal = tValorInventario
Dim idCtaContable As Integer = 0
Dim IdCtaContableOtro As Integer = UsuarioActual.Empresa.IdCuentaOtrosIngresos
@@ -1762,7 +1775,7 @@ Partial Class Inventarios_EntradasSalidas
If UsuarioActual.Empresa.UsaAC AndAlso (DdlConcepto.SelectedValue = "3") AndAlso EsContabilizable Then
Dim DtII As DataTable = Nothing
Dim TotalDetalle As Double = 0.0
Dim Importe As Double = DtMovimientos.SUM("Total", "Estatus IN ('','U')")
Dim Importe As Decimal = DtMovimientos.SUMD("Total", "Estatus IN ('','U')")
'NOTA. CUANDO ES SALIDA, EN AUTOMATICO NO TENEMOS LOS VALORES DE LA SALIDA TODAVIA, Y POR ESO IMPORTE ES CERO, ES RECARGAR CON LOS DATOS YA INSERTADOS
If ObjInventario.GetMovimientosDetalle(CveMovimiento, UsuarioActual.CveEmpresa) Then
@@ -1812,7 +1825,7 @@ Partial Class Inventarios_EntradasSalidas
If IDPoliza > 0 Then
If ObjInventario.GetMovimientosDetalle(CveMovimiento, UsuarioActual.CveEmpresa) Then
Dim DtMovtos = ObjInventario.DtResultados
Importe = DtMovtos.SUM("Total", "Estatus = ''")
Importe = DtMovtos.SUMD("Total", "Estatus = ''")
If Importe > 0 Then
If CuentaCargoCOG > 0 AndAlso CuentaAbonoAlmacen > 0 Then
@@ -4177,7 +4190,7 @@ Partial Class Inventarios_EntradasSalidas
'Obtiene valor salida
If Not ErrorMovInv AndAlso CveMovimientoSalida > 0 Then
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
Dim tValorInventario As Decimal = ObjInventario.DtResultados.SUM("Total", "").ToDecimal.RoundSQL()
Dim tValorInventario As Decimal = ObjInventario.DtResultados.SUMD("Total", "").RoundSQL()
ValorSalida = tValorInventario
Dim drA2 As DataRow = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimero(String.Format("CveAlmacen = {0}", DdlAlmacenInventarioFisico.SelectedValue))
If drA2 IsNot Nothing Then

View File

@@ -2261,7 +2261,6 @@ Partial Class Inventarios_EntregaAlmacen
If ErrorMovInv Then Exit For
Else
ErrorMovInv = True
End If
@@ -2574,10 +2573,10 @@ Partial Class Inventarios_EntregaAlmacen
End If
End If
'DEVOLUCION APARTADOS
End If
'DEVOLUCION APARTADOS
If Not ErrorMovInv Then
If TipoMovimiento = 2 Then
If ObjInventario.VentasAlmacenApartadosGet(CveVentaSurtir) Then

View File

@@ -81,18 +81,27 @@ Partial Class Inventarios_Kardex
ddlAlmacen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1)
ddlAlmacen.DataBind()
If IfNull(Request("CveAlmacen"), "-1").ToString.ToEntero > 0 Then ddlAlmacen.SelectedValuesIfExist(Request("CveAlmacen").ToString)
Dim CveTipoAlmacen As Integer
If IfNull(Request("CveAlmacen"), "-1").ToString.ToEntero > 0 Then
ddlAlmacen.SelectedValuesIfExist(Request("CveAlmacen").ToString)
CveTipoAlmacen = GlobalDTAlmacen(UsuarioActual.CveEmpresa, CveAlmacen:=Request("CveAlmacen").ToString.ToEntero).FiltroPrimeroValor("CveTipoAlmacen").ToEntero
' If CveTipoAlmacen = 3 Then chktransitorio.checked = True
End If
CargaClasificaciones()
CBLTiposAlmacen.DataSource = GlobalDTTipoAlmacen(-1)
CBLTiposAlmacen.DataBind()
For Each item As ListItem In CBLTiposAlmacen.Items
If item.Text.Contiene("Entrega Adelantado", "Transitorio") Then
item.Selected = False
If CveTipoAlmacen = 3 Then
item.Selected = True
Else
item.Selected = False
End If
Else
item.Selected = True
End If
Next
End Sub
Private Sub CargaFuncionalidad105()