public void SetInformationHeader(string id, string header)
 {
     using (var db = new EntityModel())
     {
         var information = db.Information.Find(Convert.ToInt32(id));
         if (information != null)
             information.Header = header;
         db.SaveChanges();
     }
 }
 public ActionResult RemoveNotation(string id)
 {
     using (var db = new EntityModel())
     {
         var notation = db.Notations.Find(Convert.ToInt32(id));
         if (notation != null)
             db.Notations.Remove(notation);
         db.SaveChanges();
     }
     return RedirectToAction("ViewNotation");
 }
 public void AddNotation(string name,string number)
 {
     using (var db = new EntityModel())
     {
         Notation newNotation = new Notation();
         newNotation.Name = name;
         newNotation.PhoneNumber = number;
         db.Notations.Add(newNotation);
         db.SaveChanges();
     }
 }
 public void SetInformationBody(string id, string bodyText)
 {
     using (var db = new EntityModel())
     {
         bodyText = bodyText.Replace("#%^", "<").Replace("#&*", ">");
         var information = db.Information.Find(Convert.ToInt32(id));
         if (information != null)
             information.Body = bodyText;
         db.SaveChanges();
     }
 }