diff --git a/Inventarios/InventarioFisicoDetalle.aspx.vb b/Inventarios/InventarioFisicoDetalle.aspx.vb
index 07abb0732..cdd2c7edb 100644
--- a/Inventarios/InventarioFisicoDetalle.aspx.vb
+++ b/Inventarios/InventarioFisicoDetalle.aspx.vb
@@ -86,8 +86,6 @@ Partial Class Inventarios_InventarioFisicoDetalle
GvIFD.DataBind()
If (GvIFD.Rows.Count > 0) Then
- GvIFD.UseAccessibleHeader = True
- GvIFD.HeaderRow.TableSection = TableRowSection.TableHeader
RegistraScript("OrdenarGV();")
End If
@@ -319,11 +317,11 @@ Partial Class Inventarios_InventarioFisicoDetalle
End If
Inventario.Dispose()
GvIFD.DataBind()
- If (GvIFD.Rows.Count > 0) Then
- GvIFD.UseAccessibleHeader = True
- GvIFD.HeaderRow.TableSection = TableRowSection.TableHeader
- RegistraScript("OrdenarGV();")
- End If
+ 'If (GvIFD.Rows.Count > 0) Then
+ ' GvIFD.UseAccessibleHeader = True
+ ' GvIFD.HeaderRow.TableSection = TableRowSection.TableHeader
+ ' RegistraScript("OrdenarGV();")
+ 'End If
UPPInventario.Update()
End Sub
#End Region
@@ -518,10 +516,14 @@ Partial Class Inventarios_InventarioFisicoDetalle
#End Region
#Region " ELIMINAR "
- Protected Sub gvInventarioFisicoDetalle_RowDeleting(sender As Object, e As GridViewDeleteEventArgs) Handles GvIFD.RowDeleting
+ Public Sub Delete_Click(sender As Object, e As EventArgs)
+
+ Dim ObjInventario As New ClsInventarios()
+ Dim GvRow As GridViewRow = DirectCast(DirectCast(sender, LinkButton).NamingContainer, GridViewRow)
+
If ddlUsuario.SelectedValue = UsuarioActual.CveUsuario.ToString OrElse UsuarioActual.TienePermisoProceso(283) Then
Dim Inventarios As New ClsInventarios
- Dim Retorno As Boolean = Inventarios.RemoveInventarioFisicoDetalles(GvIFD.DataKeys(e.RowIndex).Value.ToString.ToEntero())
+ Dim Retorno As Boolean = Inventarios.RemoveInventarioFisicoDetalles(GvRow.DataKey("CveInventarioFisicoDetalle").ToString.ToEntero)
If Retorno Then
If Inventarios.GetInventarioFisicoDetalle(CveInventarioFisico, ddlUsuario.SelectedValue.ToString.ToEntero) Then
@@ -532,18 +534,18 @@ Partial Class Inventarios_InventarioFisicoDetalle
Inventarios.Dispose()
GvIFD.DataBind()
- If (GvIFD.Rows.Count > 0) Then
- GvIFD.UseAccessibleHeader = True
- GvIFD.HeaderRow.TableSection = TableRowSection.TableHeader
- RegistraScript("OrdenarGV();")
- End If
+ 'If (GvIFD.Rows.Count > 0) Then
+ ' GvIFD.UseAccessibleHeader = True
+ ' GvIFD.HeaderRow.TableSection = TableRowSection.TableHeader
+ ' RegistraScript("OrdenarGV();")
+ 'End If
UPPInventario.Update()
UPAgregarPro.Update()
Else
Alert("No se puede eliminar un producto registrado por otro usuario.", TipoMensaje.MsgAdvertencia)
RegistraScript("playsonidito('142608__autistic-lucario__error.wav')")
- End If
+ End If
End Sub
#End Region
@@ -733,7 +735,7 @@ Partial Class Inventarios_InventarioFisicoDetalle
' UPAgregarPro.Update()
'End Sub
- Protected Sub LnkEditar_Click(sender As Object, e As EventArgs)
+ Protected Sub Edit_Click(sender As Object, e As EventArgs)
Dim GvRow As GridViewRow = DirectCast((DirectCast(sender, LinkButton)).NamingContainer, GridViewRow)
LimpiarModal()
@@ -750,12 +752,14 @@ Partial Class Inventarios_InventarioFisicoDetalle
DivLoteEdit.Visible = Convert.ToBoolean(GvRow.DataKey("AplicaLote").ToString)
DivFechaEdit.Visible = Convert.ToBoolean(GvRow.DataKey("AplicaCaducidad").ToString)
TxtCantidad.Text = GvRow.DataKey("Cantidad").ToString
- UpEditarPS.Update()
+ UpAddInventarioFisico.Update()
RegistraScript("$('#ModalEditarPS').modal('show')")
End Sub
+
+
Private Sub LimpiarModal()
HfCveInventarioFisicoDetalle.Value = ""
HfCvePS.Value = ""
@@ -785,8 +789,6 @@ Partial Class Inventarios_InventarioFisicoDetalle
GvIFD.DataBind()
If (GvIFD.Rows.Count > 0) Then
- GvIFD.UseAccessibleHeader = True
- GvIFD.HeaderRow.TableSection = TableRowSection.TableHeader
RegistraScript("OrdenarGV();")
End If