Пример #1
0
        public void SetUp()
        {
            descripcion = "Codificar UI";
             estimacion = 2;
             observaciones = "Preguntar al cliente";
             IdHistoria = 12;

            T = null;
            CHistoria CH = new CHistoria();
            cT = new CTarea();
            H = CH.buscarPorId(IdHistoria);
        }
Пример #2
0
        protected void btnEnviar_Click(object sender, EventArgs e)
        {
            try
                {
                    CHistoria cHu = new CHistoria();
                    CSprint cSpr = new CSprint();

                    Sprint oSpr = cSpr.buscarPorId(Convert.ToInt32(DDSprs.SelectedValue));

                    GridView gvAct = gvHU.gridActual;
                    List<Historia> lstHu = new List<Historia>();

                    foreach (GridViewRow item in gvAct.Rows)        //Obtengo HUs seleccionadas.
                    {
                        CheckBox Sel = (CheckBox)item.FindControl("chkSel");

                        if (Sel.Checked)
                        {
                            Label lblid = (Label)item.FindControl("lblId");
                            lstHu.Add(cHu.buscarPorId(Convert.ToInt32(lblid.Text)));
                        }
                    }

                    if (lstHu.Count > 0)
                    {
                        foreach (Historia oHu in lstHu) // Las asigno al sprint.
                        {
                            cHu.asignarSprint(oHu, oSpr);
                        }
                        alert.mostrarStringAlert("Historia asignada correctamente.", this);
                    }
                    else
                        alert.mostrarStringAlert("Por favor seleccione una historia.", this);

                }

                catch (Exception ex)
                {
                    alert.mostrarExAlert(ex, this);
                }
        }