using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using System;
using System.Threading.Tasks;

namespace AutoTurnOver.WeeklyStatistics
{
    class Program
    {
        static async Task Main(string[] args)
        {
            
            Console.WriteLine("启动定时汇总统计周普货数据");
            var builder = new HostBuilder().ConfigureServices((hostContext, services) =>
            {
                services.AddHostedService<NegativeProfitBackgrounService>();
                services.AddHostedService<RedundancyBackgrounService>();
                services.AddHostedService<ShortageBackgrounService>();
            });

            await builder.RunConsoleAsync();
        }
    }
}
