public override void DeleteLink(int id)
 {
     var context = new MyLifeEntities();
     var obj = new tblLinks {Id = id};
     context.AttachTo("tblLinks", obj);
     context.DeleteObject(obj);
     context.SaveChanges();
 }
 public override void UpdateLink(Link link)
 {
     var context = new MyLifeEntities();
     var obj = new tblLinks {Id = link.Id};
     context.AttachTo("tblLinks", obj);
     BizObject<Link, int>.CopyToObject(link, obj);
     context.SaveChanges();
 }
 public override void UpdateNews(Web.News.News news)
 {
     var context = new MyLifeEntities();
     var obj = new tblNews {Id = news.Id};
     context.AttachTo("tblNews", obj);
     news.CopyToObject(obj);
     context.SaveChanges();
 }