feat(logs context): Adding dashboard id to logs context (#27298)

This commit is contained in:
Vitor Avila
2024-02-29 18:28:54 -03:00
committed by GitHub
parent eb2561f80c
commit 9beee92da1
2 changed files with 33 additions and 4 deletions

View File

@@ -431,6 +431,7 @@ class ChartDataRestApi(ChartRestApi):
self, form_data: dict[str, Any]
) -> dict[str, Any]:
return {
"dashboard_id": form_data.get("form_data", {}).get("dashboardId"),
"dataset_id": form_data.get("datasource", {}).get("id")
if isinstance(form_data.get("datasource"), dict)
and form_data.get("datasource", {}).get("type")