Example #1
0
        protected BrowseSelection GetSelection(JobTypes?jobTypes)
        {
            if (!jobTypes.HasValue || jobTypes.Value == JobTypes.None || jobTypes.Value == JobTypes.All)
            {
                return(null);
            }

            var selection = new BrowseSelection(_fieldName);

            selection.setSelectionOperation(BrowseSelection.ValueOperation.ValueOperationOr);

            foreach (var jobType in Split(jobTypes.Value))
            {
                selection.addValue(Encode(jobType));
            }

            return(selection);
        }
Example #2
0
        protected BrowseSelection GetSelection(ICollection <Guid> industryIds)
        {
            if (industryIds == null || industryIds.Count == 0 || _allIndustryIds.IsSubsetOf(industryIds))
            {
                return(null);
            }

            var selection = new BrowseSelection(_fieldName);

            selection.setSelectionOperation(BrowseSelection.ValueOperation.ValueOperationOr);

            foreach (var industry in industryIds.Select(id => id.ToFieldValue()))
            {
                selection.addValue(industry);
            }

            return(selection);
        }
Example #3
0
        BrowseSelection IContentHandler.GetSelection(MemberSearchQuery searchQuery)
        {
            if (searchQuery.CandidateStatusList == null || _allStatuses.IsSubsetOf(searchQuery.CandidateStatusList))
            {
                return(null);
            }

            var selection = new BrowseSelection(FieldName.CandidateStatus);

            selection.setSelectionOperation(BrowseSelection.ValueOperation.ValueOperationOr);

            foreach (var status in searchQuery.CandidateStatusList)
            {
                selection.addValue(status.Encode());
            }

            return(selection);
        }