public IList<TitleDetail> GetTitleDetails(int titleId)
 {
     using (var db = new TitlesEntities())
     {
         return db.TitleDetails.Where(e => e.TitleId == titleId).ToList<EntityModels.TitleDetail>();
     }
 }
 public IList<Title> GetTitlesByName(string titleName)
 {
     using (var db = new TitlesEntities())
     {
         return db.Titles.Where(e => e.TitleName == titleName).ToList<EntityModels.Title>();
     }
 }