mirror of
https://github.com/apache/superset.git
synced 2026-04-20 00:24:38 +00:00
chore(chart-data): add annotations and url params to chart data schema (#11393)
* chore(chart-data): add annotations to chart data schema * bump superset-ui packages * xit flaky cypress tests
This commit is contained in:
@@ -59,6 +59,7 @@ class QueryObject:
|
||||
and druid. The query objects are constructed on the client.
|
||||
"""
|
||||
|
||||
annotation_layers: List[Dict[str, Any]]
|
||||
granularity: Optional[str]
|
||||
from_dttm: Optional[datetime]
|
||||
to_dttm: Optional[datetime]
|
||||
@@ -79,6 +80,7 @@ class QueryObject:
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
annotation_layers: Optional[List[Dict[str, Any]]] = None,
|
||||
granularity: Optional[str] = None,
|
||||
metrics: Optional[List[Union[Dict[str, Any], str]]] = None,
|
||||
groupby: Optional[List[str]] = None,
|
||||
@@ -97,9 +99,11 @@ class QueryObject:
|
||||
post_processing: Optional[List[Optional[Dict[str, Any]]]] = None,
|
||||
**kwargs: Any,
|
||||
):
|
||||
annotation_layers = annotation_layers or []
|
||||
metrics = metrics or []
|
||||
extras = extras or {}
|
||||
is_sip_38 = is_feature_enabled("SIP_38_VIZ_REARCHITECTURE")
|
||||
self.annotation_layers = annotation_layers
|
||||
self.granularity = granularity
|
||||
self.from_dttm, self.to_dttm = utils.get_since_until(
|
||||
relative_start=extras.get(
|
||||
|
||||
Reference in New Issue
Block a user