public static bool Exists(string name, DataOperationUnit dataOpUnit = null) { AuthorDao dao = new AuthorDao(); return(dao.CountBy(new Dictionary <string, object>() { { "Name", name } }, dataOpUnit?.CurrentConnection) > 0); }
public static bool Exists(Guid authorID, DataOperationUnit dataOpUnit = null) { AuthorDao dao = new AuthorDao(); return(dao.CountBy(new Dictionary <string, object>() { { "ID", authorID } }, dataOpUnit?.CurrentConnection) > 0); }