@@ -82,6 +82,13 @@ pub struct GroupingSet {
8282 pub sub_id : Option < u32 > ,
8383}
8484
85+ #[ derive( Debug , Clone , Serialize , Deserialize ) ]
86+ #[ serde( untagged) ]
87+ pub enum CompareDateRangeType {
88+ Single ( Vec < String > ) ,
89+ Multi ( Vec < Vec < String > > ) ,
90+ }
91+
8592// We can do nothing with JS functions here,
8693// but to keep DTOs in sync with reality, let's keep it.
8794pub type JsFunction = String ;
@@ -120,7 +127,7 @@ pub struct ParsedMemberExpression {
120127pub struct QueryTimeDimension {
121128 pub dimension : String ,
122129 pub date_range : Option < Vec < String > > ,
123- pub compare_date_range : Option < Vec < String > > ,
130+ pub compare_date_range : Option < CompareDateRangeType > ,
124131 pub granularity : Option < String > ,
125132}
126133
@@ -161,6 +168,8 @@ pub struct ConfigItem {
161168 pub drill_members_grouped : Option < DrillMembersGrouped > ,
162169 #[ serde( skip_serializing_if = "Option::is_none" ) ]
163170 pub granularities : Option < Vec < GranularityMeta > > ,
171+ #[ serde( skip_serializing_if = "Option::is_none" ) ]
172+ pub granularity : Option < GranularityMeta > ,
164173}
165174
166175#[ derive( Debug , Clone , Serialize , Deserialize ) ]
0 commit comments