aboutsummaryrefslogtreecommitdiffstats
path: root/csit.infra.dash/app/cdash/trending/layout.py
diff options
context:
space:
mode:
authorTibor Frank <tifrank@cisco.com>2023-06-07 13:07:19 +0000
committerTibor Frank <tifrank@cisco.com>2023-06-07 13:23:23 +0000
commit018660080bb9419dc658d6996be855e7219cf602 (patch)
treedea4b151bb8eb9d59b85dcbea7fce7298920f9bd /csit.infra.dash/app/cdash/trending/layout.py
parent83eeb515e2bf12256833545f1d40f033ef618bd9 (diff)
C-Dash: Checkboxes in telemetry selection
Change-Id: I1bace3d9e4e6815a36714a90015b3b200c678ff5 Signed-off-by: Tibor Frank <tifrank@cisco.com>
Diffstat (limited to 'csit.infra.dash/app/cdash/trending/layout.py')
-rw-r--r--csit.infra.dash/app/cdash/trending/layout.py17
1 files changed, 5 insertions, 12 deletions
diff --git a/csit.infra.dash/app/cdash/trending/layout.py b/csit.infra.dash/app/cdash/trending/layout.py
index 315b7c7a21..38381459b8 100644
--- a/csit.infra.dash/app/cdash/trending/layout.py
+++ b/csit.infra.dash/app/cdash/trending/layout.py
@@ -1061,9 +1061,9 @@ class Layout:
State({"type": "telemetry-btn", "index": ALL}, "disabled"),
State({"type": "tm-container", "index": ALL}, "children"),
State({"type": "tm-list-metrics", "index": ALL}, "value"),
+ State({"type": "tele-cl", "index": ALL}, "value"),
Input("url", "href"),
- Input({"type": "tele-cl", "index": ALL}, "value"),
Input({"type": "tm-dd", "index": ALL}, "value"),
Input("normalize", "value"),
@@ -1085,8 +1085,8 @@ class Layout:
tm_btns_disabled: list,
tm_dd: list,
list_metrics: list,
- href: str,
cl_metrics: list,
+ href: str,
tm_dd_in: list,
*_
) -> tuple:
@@ -1420,10 +1420,10 @@ class Layout:
"tele-cl", False),
)
is_open = (True, False)
- tm_btns_disabled[1], tm_btns_disabled[5] = True, True
+ tm_btns_disabled[1], tm_btns_disabled[5] = False, True
elif trigger.idx == "select":
- tm.from_json(tm_data)
if any(cl_metrics):
+ tm.from_json(tm_data)
if not tm_user["selected_metrics"]:
tm_user["selected_metrics"] = \
tm_user["unique_metrics"]
@@ -1441,8 +1441,7 @@ class Layout:
tm_btns_disabled[4] = False
is_open = (False, True)
else:
- tm_user = None
- is_open = (False, False)
+ is_open = (True, False)
elif trigger.idx == "add":
tm.from_json(tm_data)
tm_panels.append(tm_user["selected_metrics_with_labels"])
@@ -1470,12 +1469,6 @@ class Layout:
colorize=False
), )
is_open = (True, False)
- elif trigger.type == "tele-cl":
- if any(cl_metrics):
- tm_btns_disabled[1] = False
- else:
- tm_btns_disabled[1] = True
- is_open = (True, False)
elif trigger.type == "tm-dd":
tm.from_metrics_with_labels(
tm_user["unique_metrics_with_labels"]