public static IEnumerable <BookViewModel> FindByAuthorId(Guid authorId) { BookDao dao = new BookDao(); return(dao.FindBy(new Dictionary <string, object>() { { "AuthorID", authorId } }).ToViewModel()); }
public static IEnumerable <BookViewModel> FindByteSizeIsNull() { BookDao dao = new BookDao(); return(dao.FindBy(new Dictionary <string, object>() { { "ByteSize", null } }).ToViewModel()); }
public static IEnumerable <BookViewModel> FindHashIsNull() { var dao = new BookDao(); return(dao.FindBy(new Dictionary <string, object>() { { "FingerPrint", null } }).ToViewModel()); }
public static bool IsDirty(ILibrary libVM, BookViewModel book) { var dao = new BookDao(); BookViewModel refBook = dao.FindBy(new Dictionary <string, object>() { { "ID", book.ID } }).Single().ToViewModel(); return(!book.Equals(refBook)); }