public void Delete(Ranking_content instance)
 {
     if (instance == null)
     {
         throw new ArgumentNullException("instance");
     }
     else
     {
         Db.Entry(instance).State = EntityState.Deleted;
         this.SaveChanges();
     }
 }
 public ActionResult Edit(Ranking_content reward)
 {
     if (reward != null && ModelState.IsValid)
     {
         this.rewardRepository.Update(reward);
         return(RedirectToAction("Index"));
     }
     else
     {
         return(RedirectToAction("Index"));
     }
 }
 public void Create(Ranking_content instance)
 {
     if (instance == null)
     {
         throw new ArgumentNullException("instance");
     }
     else
     {
         Db.Ranking_content.Add(instance);
         this.SaveChanges();
     }
 }