Dashboard: Change X-Axis in graph with button or slider

Hey everybody!

I have a rather simple question, but I'm trying for 2 days to solve my issue and found nothing, which would help me. So that's my problem:
I have a chart and I want to adjust the X-Axis (Timestamps) using buttons like "last 5 minutes", "last 10 minutes", and so on. As far as I have understood, I have to inject a msg into the chart, containing an ui_control as described in https://github.com/node-red/node-red-dashboard/blob/master/config-fields.md
Now my problem: I have absolutely no idea how to get the message into the chart. At the moment it looks something like this:

So how to connect the button with the chart? Could someone give me a small tutorial? After 2 days of googeling I still don't get, what to do!
Many thanks for helping!!

Take a look at this post & video tutorial.
I've tried it and it worked really well! (although I'm currently using Grafana instead)


Here is the topic about nearly similar case. Get the basics from it and replace text inputs with buttons and you are probably achieved your goal Chart Variable Timeline X-Axis


Works!! Many, many thanks!! I'm happy :slight_smile:

Wonderful :wink: