public ActionResult DeleteConfirmed(int id)
        {
            ref_DayType ref_DayType = db.ref_DayType.Find(id);

            db.ref_DayType.Remove(ref_DayType);
            db.SaveChanges();
            return(RedirectToAction("Create"));
        }
 public ActionResult Edit([Bind(Include = "DayTypeID,DayTypeCode,DayTypeDescription")] ref_DayType ref_DayType)
 {
     if (ModelState.IsValid)
     {
         db.Entry(ref_DayType).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Create"));
     }
     return(View(ref_DayType));
 }
        public ActionResult Create([Bind(Prefix = "Item1", Include = "DayTypeID,DayTypeCode,DayTypeDescription")] ref_DayType ref_DayType)
        {
            if (ModelState.IsValid)
            {
                db.ref_DayType.Add(ref_DayType);
                db.SaveChanges();
                return(RedirectToAction("Create"));
            }

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

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