public ActionResult DeleteConfirmed(int id) { ArticleExternalLinks articleExternalLinks = db.ArticleExternalLinks.Find(id); db.ArticleExternalLinks.Remove(articleExternalLinks); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "articleExternalLinkID,articleID,url")] ArticleExternalLinks articleExternalLinks) { if (ModelState.IsValid) { db.Entry(articleExternalLinks).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.articleID = new SelectList(db.Article, "articleID", "title", articleExternalLinks.articleID); return(View(articleExternalLinks)); }
// GET: ArticleExternalLinks/Details/5 public ActionResult Details(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } ArticleExternalLinks articleExternalLinks = db.ArticleExternalLinks.Find(id); if (articleExternalLinks == null) { return(HttpNotFound()); } return(View(articleExternalLinks)); }
// GET: ArticleExternalLinks/Edit/5 public ActionResult Edit(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } ArticleExternalLinks articleExternalLinks = db.ArticleExternalLinks.Find(id); if (articleExternalLinks == null) { return(HttpNotFound()); } ViewBag.articleID = new SelectList(db.Article, "articleID", "title", articleExternalLinks.articleID); return(View(articleExternalLinks)); }