I built a Date filter for Softr dashboards

Hello All,

Long time coder here - but great to be in the lo/no code development era. I have seen several posts here that request date filters to apply to blocks (tables, charts) within a dashboard. The solutions I have seen are as follows:

  • AI vibe coding block to code the entire page with calendar date pick
  • CSS code snippets
  • Waiting for native date picker release from softr

I was a bit unhappy with all the options. So, I was playing around and found a hacky way to refresh several blocks within a page dynamically based on a date selection. These would apply to tables, items, charts, etc.

The quick overview of the solution is that

  • add a date picker custom code block (static)
  • have a item details to expose the selected date as URL param
  • edit all relevant blocks to conditionally filter for current record (selected date)
    If you want a detailed walk-through of this workaround, it is available here: https://www.youtube.com/watch?v=AecsBBL9KMI . All the code snippets are also available to copy.

This seems to work well for a dashboard we built for a client. It does take a couple of seconds to refresh the charts and numbers, but this has been a huge improvement on the static pages we have been building for clients.

So yeah, feel free to use this for your business use case or clients. If you have a better way of doing this, please do let me know.

Happy no-coding! :slight_smile:

7 Likes

@kalai Thanks for creating this tutorial and sharing the code. I haven’t tried it yet, but it looks like a great work around until Softr supports this functionality natively - which is hopefully sooner than later. Great job!

1 Like

@TobyMacLeod do you happen to know when? This is one of my “concerns” is that what might be considered a foundational feature. Something that is used in many projects so ideally is a “block” we can use in Softr. But if vide-coding is the answer to all of these then I as long time developer I am worried it will not scale. More bugs, more unknowns when it comes to quoting out a gig etc.

Hi @dailyaistudio, No. I have no insight into when this functionality may be available. Hopefully sooner than later.