public GetAllRestrictionResponse GetAllRestrictions() { GetAllRestrictionResponse response = new GetAllRestrictionResponse(); IEnumerable <Restriction> restrictions = _restrictionRepository .FindAll(); if (restrictions != null) { response.RestrictionFound = true; response.Restrictions = restrictions.ConvertToRestrictionViews(); } else { response.RestrictionFound = false; } return(response); }