Beispiel #1
0
        public ActionResult DeleteConfirmed(int id)
        {
            tblIssueType tblIssueType = db.tblIssueTypes.Find(id);

            db.tblIssueTypes.Remove(tblIssueType);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
Beispiel #2
0
 public ActionResult Edit([Bind(Include = "typeID,typeTitle,typeDescription,typeImage,showInFeedbackSystem,TypeIcon")] tblIssueType tblIssueType)
 {
     if (ModelState.IsValid)
     {
         db.Entry(tblIssueType).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(tblIssueType));
 }
Beispiel #3
0
        public ActionResult Create([Bind(Include = "typeID,typeTitle,typeDescription,typeImage,showInFeedbackSystem,TypeIcon")] tblIssueType tblIssueType)
        {
            if (ModelState.IsValid)
            {
                db.tblIssueTypes.Add(tblIssueType);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(tblIssueType));
        }
Beispiel #4
0
        // GET: IssueTypes/Delete/5
        public ActionResult Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            tblIssueType tblIssueType = db.tblIssueTypes.Find(id);

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