public List <SalaryRuleResponse> GetSalaryRule(SalaryQueryRequest request) { var entity = GetAsNoTracking(p => p.Active == true && (request.GroupId == null || p.SalaryRuleGroupMapping.Any(a => a.SalaryRuleGroupId == request.GroupId))); var result = entity.ProjectTo <SalaryRuleResponse>(Mapper.ConfigurationProvider).ToList(); return(result); }
public ActionResult Get([FromQuery] SalaryQueryRequest request) { var result = salaryruleService.GetSalaryRule(request); return(Ok(result)); }