You are here

public function FacetsSummary::setFacets in Facets 8

Returns a list of facets that are included in this summary.

Parameters

array $facets: An associative array keyed by facet id and having arrays as values with the next structure:

  • facet_id: (string) The facet entity id.
  • show_count: (bool) If the source count will be displayed in the block.
  • prefix: (string) Prefix of facet group.
  • suffix: (string) Suffix of facet group.
  • separator: (string) Separator for facet items.

Overrides FacetsSummaryInterface::setFacets

File

modules/facets_summary/src/Entity/FacetsSummary.php, line 158

Class

FacetsSummary
Defines the facet summary entity.

Namespace

Drupal\facets_summary\Entity

Code

public function setFacets(array $facets) {
  return $this->facets = $facets;
}