public bookInfo Save(bookInfo bookInfo)
 {
     if (bookInfo.bookID == 0)
     {
         db.bookInfo.Add(bookInfo);
     }
     else
     {
         db.Entry(bookInfo).State = EntityState.Modified;
     }
     db.SaveChanges();
     return(bookInfo);
 }
 public void Delete(bookInfo bookInfo)
 {
     db.bookInfo.Remove(bookInfo);
     db.SaveChanges();
 }