Exemple #1
0
        public ActionResult DeleteConfirmed(int id)
        {
            YearInput yearInput = db.YearInputs.Find(id);

            db.YearInputs.Remove(yearInput);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
Exemple #2
0
 public ActionResult Edit([Bind(Include = "ID,Year")] YearInput yearInput)
 {
     if (ModelState.IsValid)
     {
         db.Entry(yearInput).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(yearInput));
 }
Exemple #3
0
        public ActionResult Create([Bind(Include = "ID,Year")] YearInput yearInput)
        {
            if (ModelState.IsValid)
            {
                db.YearInputs.Add(yearInput);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(yearInput));
        }
Exemple #4
0
        // GET: YearInput/Delete/5
        public ActionResult Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            YearInput yearInput = db.YearInputs.Find(id);

            if (yearInput == null)
            {
                return(HttpNotFound());
            }
            return(View(yearInput));
        }
Exemple #5
0
 public CreateAlbumPage CrearAlbum(Album album)
 {
     foreach (var input in AllForm)
     {
         input.Clear();
     }
     Thread.Sleep(1000);
     NameInput.SendKeys(album.Name);
     Thread.Sleep(1000);
     ArtistInput.SendKeys(album.Artist);
     Thread.Sleep(1000);
     YearInput.SendKeys(album.Year.ToString());
     Thread.Sleep(1000);
     GenresInput.SendKeys(album.Genres);
     Thread.Sleep(1000);
     SubGenresInput.SendKeys(album.SubGenres);
     Thread.Sleep(1000);
     return(this);
 }
Exemple #6
0
 public AgeRegistrationPage SetYear(string value)
 {
     YearInput.SendKeys(value);
     return(this);
 }
 public AddPage set_year_to(int year)
 {
     YearInput.Clear();
     YearInput.SendKeys(year.ToString());
     return(this);
 }
 public EditPage SetYearTo(int year)
 {
     YearInput.Clear();
     YearInput.SendKeys(year.ToString());
     return(this);
 }