public ListDelegationForListVm GetAllDelegationsForListByStatus(int statusId) { var delegations = _delegationRepo.GetDelegationsByStatus(statusId).ProjectTo <DelegationForListVm>(_mapper.ConfigurationProvider).ToList(); var delegationsVm = new ListDelegationForListVm() { Delegations = delegations, Count = delegations.Count }; return(delegationsVm); }