示例#1
0
        public void CatRemove2(int Id)
        {
            InvItemCategory cat = db.InvItemCategories.Find(Id);

            db.InvItemCategories.Remove(cat);
            db.SaveChanges();
        }
示例#2
0
        public ActionResult CatRemove2(int Id)
        {
            InvItemCategory cat = db.InvItemCategories.Find(Id);

            db.InvItemCategories.Remove(cat);
            db.SaveChanges();

            return(Json("CatRemove:", JsonRequestBehavior.AllowGet));
        }
示例#3
0
        // GET: InvItems/Delete/5
        public ActionResult CatRemove(int id)
        {
            InvItemCategory cat = db.InvItemCategories.Find(id);

            db.InvItemCategories.Remove(cat);
            db.SaveChanges();

            return(RedirectToAction("Index", "InvItems", null));
        }