Passing parameters to dashboards

Hi all,

I am currently working on a Habpanel to display various readings from a temperature/humidity sensor.
I’d like to show current values, plus historic charts over the last n days.
So far, I am able to come up with a working protype for a given sensor and a fixed number of days, e.g. the dashboard is showing the bathroom sensor over the last 7 days.

Now I have about 20 sensors around the house, and I want to be able to see each of them in that view, and I would like to adjust the granularity and time frame (last day, last week, last month, last year, …) dynamically.
Of course I don’t want to create 80+ static panels, one for each sensor and time frame, but have a more dynamic kind of solution.

My question:
Is it possible to invoke a view and pass parameters to it and then use these parameters in a widget?, e.g.
https://smarthome/habpanel/index.html#/view/Klima?sensor=SensorBathroom&timeframe=7d

Sample Widget code that uses the variable sensor (which is currently set in an ng-init block, instead of being passed in by a parameter) to get the item name:

          <td class=\"main-temperature-text\">
           {{'%.1f' | sprintf:itemValue(sensor + '_Temperature').split(' ')[0]}}
          </td>

Thanks,
Daniel

Resolved by this post from 3 years ago:
How to make template dashboards - Tutorials & Examples - openHAB Community

Sometimes, knowledge is just knowing where to find things… :wink: