RTTV Front End Configuration - PSASCapstone2013/rttv GitHub Wiki
The frontend of the RTTV allows the user to specify which widgets are displayed, what data is displayed by widgets and how they are oriented on the page by editing a yaml file. The existing config files can be found in static/config/*.yaml
Widgets
Widgets display data. Currently there are three types of widgets available:
- Text: Used to display values in plain text
- LineGraph: Used to display a value on a line graph. Line graphs with multiple data types are also available.
- Gauge: Used to display a value on a graphical gauge
Unit Conversion
All data is sent by the backend in MKS units. To handle unit conversion on the frontend the library js-quantities is used. The library contains a list of all the available units and their aliases and is located at static/scripts/quantities.js. If you try to use a unit or unit conversion not supported your data will not display. Right now the backend does not send the units in the JSON object so the incoming units for each field are kept in the file static/scripts/units.js. If the units sent by the backend changes or additional data added that file will need to be updated.
Examples
Examples for layout and each widget type can be found in the readme located here: https://github.com/PSASCapstone2013/rttv