示例#1
0
        public ActionResult DeleteConfirmed(int id)
        {
            FSOSummary fSOSummary = db.FSOSummaries.Find(id);

            db.FSOSummaries.Remove(fSOSummary);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
示例#2
0
 public ActionResult Edit([Bind(Include = "Id,Report,ReportDate,UploadTime,TimeStamp,DayOftheWeek")] FSOSummary fSOSummary)
 {
     if (ModelState.IsValid)
     {
         db.Entry(fSOSummary).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(fSOSummary));
 }
示例#3
0
        public ActionResult Create([Bind(Include = "Id,Report,ReportDate,UploadTime,TimeStamp,DayOftheWeek")] FSOSummary fSOSummary)
        {
            if (ModelState.IsValid)
            {
                db.FSOSummaries.Add(fSOSummary);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(fSOSummary));
        }
示例#4
0
        // GET: FSOSummaries/Delete/5
        public ActionResult Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            FSOSummary fSOSummary = db.FSOSummaries.Find(id);

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