Beispiel #1
0
        public ListQueryResult <CreditRequestViewModel> GetSecurityCreditRequests(SecurityCreditRequestsQuery query)
        {
            var rightsRes = CheckEmployeeRights(query.EmployeeId, EmployeeRights.SecurityOfficer);

            if (rightsRes.IsFailed)
            {
                return(new ListQueryResult <CreditRequestViewModel>(query, null, false).From(rightsRes));
            }
            return(Filter(_creditRequestService.GetSecurityRequests(new SecurityRequestsQuery()), query));
        }