0

I have a date field facet filter on my search api views page.

When I select a date in the filter, the search api display those results which has that date value selected in the date field.

I want to display those results which has a date value which is greater than or equal to the selected in the date facet filter.

Is it possible? I checked with the search api query alter hook but I can't see any helpful function to alter the condition.

1 Answer 1

0

I have overridden these classes in my custom module

Drupal\facets\Plugin\facets\query_type\SearchApiDate;
Drupal\facets\QueryType\QueryTypeRangeBase;

And then modified this function

public function execute()

of QueryTypeRangeBase and used the correct operator.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.