public FileBasedKitchenResponsibleService(IOptions <Paths> paths, IWeekNumberFinder weekNumberFinder)
        {
            this.weekNumberFinder = weekNumberFinder;
            if (employeesPath == null)
            {
                employeesPath = Path.Combine(paths.Value.FilePath + "Employees.txt");
                employees     = GetEmployees();
            }

            if (currentWeekPath == null)
            {
                currentWeekPath = Path.Combine(paths.Value.FilePath + "CurrentWeek.txt");
            }

            if (!currentWeek.HasValue)
            {
                currentWeek = GetCurrentWeek();
            }
        }
Пример #2
0
 public KitchenResponsibleService(ITrondheimRepository trondheimRepository, IWeekNumberFinder weekNumberFinder)
 {
     this.trondheimRepository = trondheimRepository;
     this.weekNumberFinder    = weekNumberFinder;
 }