I'm setting options of the grid report with pivot.setReport(), everything is restored correctly except drills (columns). Rows are expanded correctly. What I'm missing to be able to restore column drills too?
{
"rows": [
{"uniqueName": "Computed_ProjectName"},
{"uniqueName": "Computed_ObjectLineProjectPhase"},
{"uniqueName": "User"}
],
"columns": [
{"uniqueName": "Perdavimo registravimo data"},
{"uniqueName": "[Measures]"}
],
"measures": [
{"uniqueName": "Kiekis","formula": "1 = 1","individual": true,"caption": "Kiekis"}
],
"expands": {
"rows": [
{"tuple": ["computed_projectname.[pajustis]","computed_objectlineprojectphase.[1]"]}
]
},
"drills": {
"columns": [
{"tuple": ["perdavimo registravimo data.[2022]"]},
{"tuple": ["perdavimo registravimo data.[2022]"]},
{"tuple": ["perdavimo registravimo data.[2022].[2 ketvirtis]"]},
{"tuple": ["perdavimo registravimo data.[2022].[2 ketvirtis]"]},
{"tuple": ["perdavimo registravimo data.[2022].[1 ketvirtis]"]},
{"tuple": ["perdavimo registravimo data.[2022].[1 ketvirtis]"]},
{"tuple": ["perdavimo registravimo data.[2022].[3 ketvirtis]"]},
{"tuple": ["perdavimo registravimo data.[2022].[3 ketvirtis]"]}
]
}
}
Hello, Mantas!
Thank you for reaching out to us.
If we understand the case correctly, you are using the year/quarter/month/day
datatype with your own localized captions. In that case, the original "quarter" word should be used in the tuple instead of a localized one.
We have prepared a JSFiddle example for visualization: https://jsfiddle.net/flexmonster/8b0jypdo/.
If the case is different, we kindly ask you to modify our example to make the case reproducible.
We also want to suggest a hint to check how the parameters should be configured within the report:
1. Configure all necessary changes using Flexmonster UI
2. Press the Save
button on the Toolbar and save the report.json
file to your file system
3. Open saved report.json
with any text editor(e.g., Notebook or Notepad) and check out the already configured report. It can be copied to any other report object if needed.
Hope you will find our answer helpful.
Looking forward to hearing from you.
Regards,
Solomiia
Hello, Mantas!
Hope you are having a great week.
Our team is wondering if you had some time to look through our previous answer. Could you please let us know if changing the 'ketvirtis' to 'quarter' in tuples works for your case?
Looking forward to hearing from you.
Regards,
Solomiia
I found the problem - options.grouping = true. If I enable it, then the "drills" are not restored anymore:
https://jsfiddle.net/meLdo8nr/
In short:
var r = pivot.getReport();
r.options = {grouping: true };
r.slice = <...>;//slice with drills
pivot.setReport(r);
Hello, Mantas!
Thank you for your response.
Currently, there are some known issues with the grouping
option. If possible, we suggest removing this option from the reports. Please let us know if it would work for you.
Looking forward to hearing from you.
Regards,
Solomiia
This question is now closed