Exemple #1
0
        public ActionResult DeleteConfirmed(int id)
        {
            Entity_Branchs entity_Branchs = db.Entity_Branchs.Find(id);

            db.Entity_Branchs.Remove(entity_Branchs);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
Exemple #2
0
 public ActionResult Edit([Bind(Include = "id,title,entity_id,is_deleted")] Entity_Branchs entity_Branchs)
 {
     if (ModelState.IsValid)
     {
         db.Entry(entity_Branchs).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.entity_id = new SelectList(db.Entities, "id", "Title", entity_Branchs.entity_id);
     return(View(entity_Branchs));
 }
Exemple #3
0
        // GET: Entity_Branchs/Details/5
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            Entity_Branchs entity_Branchs = db.Entity_Branchs.Find(id);

            if (entity_Branchs == null)
            {
                return(HttpNotFound());
            }
            return(View(entity_Branchs));
        }
Exemple #4
0
        // GET: Entity_Branchs/Edit/5
        public ActionResult Edit(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            Entity_Branchs entity_Branchs = db.Entity_Branchs.Find(id);

            if (entity_Branchs == null)
            {
                return(HttpNotFound());
            }
            ViewBag.entity_id = new SelectList(db.Entities, "id", "Title", entity_Branchs.entity_id);
            return(View(entity_Branchs));
        }