Ejemplo n.º 1
0
    protected void Button2_Click(object sender, EventArgs e)
    {
        Asignaciones validar = new Asignaciones();

        foreach (GridViewRow row in GV_Pedidos.Rows)
        {
            validar.Asignar(Convert.ToString(((Label)row.Cells[0].FindControl("L_Referencia")).Text), Convert.ToDouble(((Label)row.Cells[1].FindControl("L_Talla")).Text), Convert.ToInt32(((Label)row.Cells[2].FindControl("L_Cantidad")).Text), GV_Pedidos.Rows.Count, (Session["asignacion2"] as List <Asignacion>), Convert.ToString(Session["sedePedido"]));
            Session["entregado"]   = validar.GetEntregado();
            Session["asignacion2"] = validar.GetPedidos();
            Session["idproducto"]  = validar.GetId();
#pragma warning disable CS0618 // Type or member is obsolete
            RegisterStartupScript("mensaje", "<script type='text/javascript'>alert('" + validar.Devuelve_Mensaje() + "');</script>");
#pragma warning restore CS0618 // Type or member is obsolete
        }
        Button2.Enabled = validar.GeT_Estado();
        Button3.Enabled = !validar.GeT_Estado();
        GV_Pedido.DataBind();
        GV_Pedidos.DataBind();
        GV_ProductosBodega.DataBind();
    }