2

I have an entity with a timestamp field that I would like to filter based on date. I can add a standard filter "between two date", type in two dates, and everything works great. However, contextual ranges do not work. I've read online that Drupal 7 allowed 2016-01-10--2017-01-01 or 20160101--20170101 as input and would display all results in 2016. These do not seem to work in Drupal 8. Is there a way to do range contextual filters in D8?

I've tried using a datetime field instead of a timestamp, and I am unable to filter this either.

1

Views Contextual Range Filter might do the trick for you. Install the latest beta and then see if you need to apply this patch. It's got just the functionality you're looking for.

  • Thanks! I saw this, but the 'releases' list does not show the 8.x version, so I assumed there was none. – Kevin Nowaczyk Feb 3 '17 at 20:38
  • I noticed that. I thought it was too useful a module not to have something in the works for D8 so I checked the repository. – ponies Feb 3 '17 at 21:55
  • Unfortunately is doesn't install. The code is probably based on the beta versions of D8. – Kevin Nowaczyk Feb 4 '17 at 13:21
  • This module has been updated and now function for D8.4 – Kevin Nowaczyk Jan 4 '18 at 19:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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