Exemplo n.º 1
0
        static void Main(string[] args)
        {
            var optionsBuilder = new DbContextOptionsBuilder <LiveyTvContext>();

            StreamHubCoreDal.AppConfig.AppConfiguration appConfiguration = new StreamHubCoreDal.AppConfig.AppConfiguration();

            optionsBuilder.UseSqlServer(appConfiguration.ConnectionString);
            liveyTvContext = new LiveyTvContext(optionsBuilder.Options);
            iterateAllFiles("D:\\programming3\\livey\\Data-Scrapping\\Data");
        }
Exemplo n.º 2
0
        private static List <Item> CollectAllDBItemsEntered()
        {
            LiveyTvContext liveyTvContext;
            var            optionsBuilder = new DbContextOptionsBuilder <LiveyTvContext>();

            StreamHubCoreDal.AppConfig.AppConfiguration appConfiguration = new StreamHubCoreDal.AppConfig.AppConfiguration();

            optionsBuilder.UseSqlServer(appConfiguration.ConnectionString);
            liveyTvContext = new LiveyTvContext(optionsBuilder.Options);
            List <Item> lstItemsEnteredToday = new List <Item>();

            lstItemsEnteredToday = liveyTvContext.Items.Where(x => x.createDate >= DateTime.Today.AddDays(-1)).ToList();

            return(lstItemsEnteredToday);
        }
Exemplo n.º 3
0
 public CsvProcessingController(LiveyTvContext context)
 {
     _context = context;
 }
Exemplo n.º 4
0
 public ItemsController(LiveyTvContext context)
 {
     _context = context;
 }