kpi_csv_sq.py : moved links to below graphs

Signed-off-by: Chuck SmileyRekiere <chuck.smileyrekiere@candelatech.com>
This commit is contained in:
Chuck SmileyRekiere
2021-08-04 13:35:39 -06:00
parent 2198c86243
commit 2ae9ac34ab

View File

@@ -116,6 +116,9 @@ class csv_sqlite_dash():
print("png_path {}".format(png_path)) print("png_path {}".format(png_path))
kpi_fig.write_image(png_path,scale=1,width=1200,height=350) kpi_fig.write_image(png_path,scale=1,width=1200,height=350)
# use image from above to creat html display
self.children_div.append(dcc.Graph(figure=kpi_fig))
#TODO the link must be to a server to display html #TODO the link must be to a server to display html
# WARNING: os.path.join will use the path for where the script is RUN which can be container. # WARNING: os.path.join will use the path for where the script is RUN which can be container.
# need to construct path to server manually. DO NOT USE os.path.join # need to construct path to server manually. DO NOT USE os.path.join
@@ -126,9 +129,8 @@ class csv_sqlite_dash():
href=index_html_path, target='_blank')) href=index_html_path, target='_blank'))
self.children_div.append(html.Br()) self.children_div.append(html.Br())
self.children_div.append(html.A('html_reports', href=self.server_html_reports, target='_blank')) self.children_div.append(html.A('html_reports', href=self.server_html_reports, target='_blank'))
self.children_div.append(html.Br())
# use image from above to creat html display self.children_div.append(html.Br())
self.children_div.append(dcc.Graph(figure=kpi_fig))
# access from server # access from server
# https://stackoverflow.com/questions/61678129/how-to-access-a-plotly-dash-app-server-via-lan # https://stackoverflow.com/questions/61678129/how-to-access-a-plotly-dash-app-server-via-lan