Reconstruir costos
This commit is contained in:
@@ -58,7 +58,31 @@ Partial Class Inventario_ReconstruirCostos
|
||||
End If
|
||||
ObjPS.Dispose()
|
||||
End Sub
|
||||
Private Sub BtnReconstruir_Click(sender As Object, e As EventArgs) Handles BtnReconstruir.Click
|
||||
Dim objInv As New ClsInventarios
|
||||
Dim TieneError As Boolean = False
|
||||
Dim Producto As String = ""
|
||||
|
||||
For Each Gvr As GridViewRow In GvProdcutos.Rows
|
||||
If Gvr.FCCheckBox("ChkProducto").Checked Then
|
||||
Dim CvePS As Integer = Gvr.DataKey("CvePS").ToEntero
|
||||
If Not objInv.ReconstruirCostos(CvePS, UsuarioActual.CveEmpresa) Then
|
||||
TieneError = True
|
||||
Producto += String.Format("{0} <br/>", Gvr.DataKey("PS").ToString)
|
||||
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
|
||||
If TieneError Then
|
||||
Alert(String.Format("Error al reconstruir los costos en los siguientes productos: {0}", Producto), TipoMensaje.MsgError)
|
||||
Else
|
||||
Alert("Se realizo el cambio correctamente", TipoMensaje.MsgConfirmacion)
|
||||
|
||||
End If
|
||||
|
||||
objInv.Dispose()
|
||||
End Sub
|
||||
|
||||
|
||||
End Class
|
||||
Reference in New Issue
Block a user