private void EmployeePayRuleStep(List <Employee> fullData) { var employeeMapper = new EmployeeMapper(); var payRules = employeeMapper.MapPayRulePre(fullData); var excludedToTestPayRules = payRules.Where(s => s.Sequence > IncludedForTestingPayRuleCount); var excludedForTestingExportData = new ExportData <PayRulePre> { DataList = excludedToTestPayRules.ToList(), FilePath = _outputFileDictionary.OneEePerPayRuleExtra.FilePath, SheetName = _outputFileDictionary.OneEePerPayRuleExtra.SheetName }; _statusTracker.NotifyNewStep(string.Format(JobStepDescription.ExportFile, _outputFileDictionary.OneEePerPayRuleExtra.FileName)); _commandExecutor.Execute(excludedForTestingExportData); var includedToTestExportData = new ExportData <PayRule> { DataList = employeeMapper.MapPayRule(payRules.Where(s => s.Sequence <= IncludedForTestingPayRuleCount).ToList()), FilePath = _outputFileDictionary.OneEePerPayRule.FilePath, SheetName = _outputFileDictionary.OneEePerPayRule.SheetName }; _statusTracker.NotifyNewStep(string.Format(JobStepDescription.ExportFile, _outputFileDictionary.OneEePerPayRule.FileName)); _commandExecutor.Execute <ExportData <PayRule> >(includedToTestExportData); }
private void EmployeeCustomDateStep(List <Employee> fullData, string fileName) { var employeeMapper = new EmployeeMapper(); var employeeCustomDates = employeeMapper.MapCustomDate(fullData); var employeeExportData = new ExportData <CustomDate> { DataList = employeeCustomDates, FilePath = _outputDirectory.ExcelFilePath(fileName) }; _commandExecutor.Execute(employeeExportData); }