public ActionResult DeleteConfirmed(int id) { SpecialInstruction specialInstruction = db.SpecialInstructions.Find(id); db.SpecialInstructions.Remove(specialInstruction); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "id,indawoId,instruction")] SpecialInstruction specialInstruction) { if (ModelState.IsValid) { db.Entry(specialInstruction).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(specialInstruction)); }
public ActionResult Create([Bind(Include = "id,indawoId,instruction")] SpecialInstruction specialInstruction) { ViewBag.indawoId = new SelectList(db.Indawoes, "id", "name", specialInstruction.indawoId); if (ModelState.IsValid) { db.SpecialInstructions.Add(specialInstruction); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(specialInstruction)); }
// GET: SpecialInstructions/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } SpecialInstruction specialInstruction = db.SpecialInstructions.Find(id); if (specialInstruction == null) { return(HttpNotFound()); } return(View(specialInstruction)); }
public void Init(float distance, Vector3 value, GameThing gameThing, Reflex reflex, bool canBlend, SpecialInstruction specialInstruction) { this.Distance = distance; this.GameThing = gameThing; this.Reflex = reflex; this.Value = value; this.Used = false; this.ActedOn = false; this.CanBlend = canBlend; this.specialInstruction = specialInstruction; }