shyft.dashboard.time_series.tools.table_tools
Classes
|
Tool to download all data shown in all figures where this tool is attached to! |
|
This object represents the base class of all figure tools |
Exceptions
- class shyft.dashboard.time_series.tools.table_tools.TableTool(logger=None)[source]
Bases:
BaseTool
This object represents the base class of all figure tools
- class shyft.dashboard.time_series.tools.table_tools.ExportTableDataButton(label: str = 'Download Table Data', height: int = 50, width: int = 150, padding: int | None = None, sizing_mode: str | None = None, logger=None)[source]
-
Tool to download all data shown in all figures where this tool is attached to!
Two obstacles: - each obj/renderer in a figure has its own data source with own amount of time, value tuples - js callbacks and python callbacks in bokeh are not sync
Therefore: - for each renderer one separate csv file is downloaded - we create a bokeh PreText obj in addition to the download button, to which we attach a js callback for the download after the download the callback is removed again
- __init__(label: str = 'Download Table Data', height: int = 50, width: int = 150, padding: int | None = None, sizing_mode: str | None = None, logger=None)[source]
- Parameters:
logger – optional logger
- static js_callback(*, sources: List[ColumnDataSource], names: List[str], column_name_maps: List[Dict[str, str]], map_of_name_map: List[Dict[str, str]]) str [source]
Creates js to download all data from multiple data sources to multiple csv files
- property layout_components: Dict[str, List[Any]]
Property to return all layout.dom components of an visualisation app such that they can be arranged by the parent layout obj as desired.
- Returns:
layout_components as
- Return type:
{‘widgets’: [], ‘figures’: []}
- property layout: LayoutDOM