Domanda

We've setup some taxonomy terms for use in our publishing pages. When searching within a site where pages use these terms, they show in the refinements page on the results page. However, ideally we'd like to have a little more control on how they are shown.

The screenshot below shows two of our term sets as refinements custom term set as refinements

the two customizations we'd like to make are:

  1. remove the TextBox shown when you click the "show more" link at the end of a refinement category, and
  2. Specify the order in which terms are shown in the term set, when displayed as refinments (i.e. in this screenshot we'd see (from the top) 5.4, 5.3, 5.2, show more)
  3. automatically expand specific refinements without needing to show a 'show more' link (e.g. in this screenshot we'd see (from the top) 5.4, 5.3, 5.2, 5.1, 5.0)

Are any/all of these desires possible?

Thanks in advance

Kevin

È stato utile?

Soluzione

I don't think you can get rid of the textbox.

But the other two requirements may be solved by modifying the Refinement Panels Filter Category Definition. Here is the valid option for the Refinement Panel XML Schema.

SortBy="Name" SortDirection="Descending" should give you the ordering you need.
MaxNumberOfFiltersToDisplay="50" ShowMoreLink="False" should give you the expansion

Altri suggerimenti

Yes and no. So

  1. You can implement your own Refiner inheriting (1 & 2 ) from http://www.threewill.com/2012/04/custom-search-refiners/ or http://www.sharepointanalysthq.com/2010/10/custom-refinement-filters-in-sharepoint-2010/
  2. Use something like this (use MaxNumberOfFilters and NumberOfFiltersToDisplay)

     <Category Title="Skill" Description="The skill the person has." Type="Microsoft.Office.Server.Search.WebControls.ManagedPropertyFilterGenerator" MetadataThreshold="1" NumberOfFiltersToDisplay="4" MaxNumberOfFilters="20" SortBy="Frequency" SortByForMoreFilters="Name" SortDirection="Descending" SortDirectionForMoreFilters="Ascending" ShowMoreLink="True" MappedProperty="CustomSkills" MoreLinkText="show more" LessLinkText="show fewer" ShowCounts="Count" />
    
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a sharepoint.stackexchange
scroll top