public static void Export(string path, DateTime?min, DateTime?max) { var repo = Repository.Of <News>(); var news = NewsOperation.Where(repo, x => x.PublishDate <max && x.PublishDate> min); WriteToExcel(news, path); }
public static void Export(string path) { var repo = Repository.Of <News>(); var news = NewsOperation.GetAllNews(repo); WriteToExcel(news, path); }