Exemple #1
0
        public ActionResult DeleteConfirmed(Guid id)
        {
            RefBookOwner refBookOwner = db.RefBookOwner.Find(id);

            db.RefBookOwner.Remove(refBookOwner);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
Exemple #2
0
 public ActionResult Edit([Bind(Include = "idRefBookOwner,DateDownload,OwnerId,OwnerDsc")] RefBookOwner refBookOwner)
 {
     if (ModelState.IsValid)
     {
         db.Entry(refBookOwner).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(refBookOwner));
 }
Exemple #3
0
        public ActionResult Create([Bind(Include = "idRefBookOwner,DateDownload,OwnerId,OwnerDsc")] RefBookOwner refBookOwner)
        {
            if (ModelState.IsValid)
            {
                refBookOwner.idRefBookOwner = Guid.NewGuid();
                db.RefBookOwner.Add(refBookOwner);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(refBookOwner));
        }
Exemple #4
0
        // GET: RefBookOwners/Delete/5
        public ActionResult Delete(Guid?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            RefBookOwner refBookOwner = db.RefBookOwner.Find(id);

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