Example #1
0
        public ActionResult DeleteConfirmed(long id)
        {
            MasterHasilReview masterHasilReview = db.HasilReview.Find(id);

            db.HasilReview.Remove(masterHasilReview);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
Example #2
0
 public ActionResult Edit([Bind(Include = "Id,Nama,Status")] MasterHasilReview masterHasilReview)
 {
     if (ModelState.IsValid)
     {
         db.Entry(masterHasilReview).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(masterHasilReview));
 }
Example #3
0
        public ActionResult Create([Bind(Include = "Id,Nama,Status")] MasterHasilReview masterHasilReview)
        {
            masterHasilReview.Status = "1";
            if (ModelState.IsValid)
            {
                db.HasilReview.Add(masterHasilReview);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(masterHasilReview));
        }
Example #4
0
        // GET: MasterHasilReviews/Delete/5
        public ActionResult Delete(long?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            MasterHasilReview masterHasilReview = db.HasilReview.Find(id);

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