using LCU.Library.Internal.IncentiveApiModels.Enums; using LCU.API.Internal.Operations.IncentiveApi.Models; namespace LCU.API.Internal.Operations.IncentiveApi.Services.Rules; public class BusinessRuleService : IBusinessRuleService { private readonly IDepartmentService _departmentService; public BusinessRuleService(IDepartmentService departmentService) { _departmentService = departmentService; } public IReadOnlyCollection GetRules(PayoutType type) { var dept = _departmentService .GetDepartmentsByDayforceGlCodeAsync(NewCheckingReferralRule.MemberServicesGlCode).GetAwaiter() .GetResult(); return type switch { PayoutType.Department => new List() { new NewCheckingReferralRule(dept.Id.Value) }, PayoutType.Personal => new List() { } }; } }