public ActionResult DeleteConfirmed(int id)
        {
            InterestPeriod interestPeriod = db.InterestPeriods.Find(id);

            db.InterestPeriods.Remove(interestPeriod);
            db.SaveChanges();
            return(RedirectToAction("InterestPeriod"));
        }
 public ActionResult Edit([Bind(Include = "InterestPeriodID,Description")] InterestPeriod interestPeriod)
 {
     if (ModelState.IsValid)
     {
         db.Entry(interestPeriod).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("InterestPeriod"));
     }
     return(View(interestPeriod));
 }
        public ActionResult Create([Bind(Include = "InterestPeriodID,Description")] InterestPeriod interestPeriod)
        {
            if (ModelState.IsValid)
            {
                db.InterestPeriods.Add(interestPeriod);
                db.SaveChanges();
                return(RedirectToAction("InterestPeriod"));
            }

            return(View(interestPeriod));
        }
        // GET: InterestPeriods/Delete/5
        public ActionResult Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            InterestPeriod interestPeriod = db.InterestPeriods.Find(id);

            if (interestPeriod == null)
            {
                return(HttpNotFound());
            }
            return(View(interestPeriod));
        }