March 2018
Beginner to intermediate
410 pages
10h 40m
English
When we understand how the first plot works, it's easy to generalize the page and create similar plots for the other time bases we have: hours and days. First, we need to create analogous static methods in our code to read hourly and daily historical values from our persistence layer. We call these methods GetLastHours() and GetLastDays(). We then simply add the following sections to our Markdown page.
The DrawGraph script function defined earlier will draw the corresponding graphs:
Hours
-------------
{DrawGraph(SensorHttp.App.GetLastHours());}
Days
-------------
{DrawGraph(SensorHttp.App.GetLastDays());}
Read now
Unlock full access