The labels for custom date ranges aren't displayed in the facet block. Attached patch fixes this.

To get the custom labels, one needs to load the active searcher from facetapi - facetapi API says that this can return multiple searchers, as I don't know how to distinguish them properly and as I never had a situation occur where facetapi actually returns more than one active searcher, I am just using the first one returned. Maybe this is incorrect in some situations, but for me it works perfectly for now.

CommentFileSizeAuthor
date_facets-labels.patch1.08 KBFrando

Comments

g089h515r806’s picture

works correct for me.

Sneakyvv’s picture

works for me, but I have refactored your code patching two other issues (https://drupal.org/node/2131831)

eugene.ilyin’s picture

Hello. Sorry for delay.

@Frando, thanks for your work. Commited with some changes 894f6f7

eugene.ilyin’s picture

Status: Needs review » Fixed
eugene.ilyin’s picture

Status: Fixed » Closed (fixed)