Hello,
The ability to sort columns in the pivot table exists for measure columns, but how about dimension columns?
Furthermore, is it possible to customize the dimension column header to display a button which uses a drop-down menu?
I'll attach a file for example.
As a separate, but simpler question: how do I add tooltip for pivot table cell data? I was only able to find it for column header cells:
Tooltip for Pivot column width (found it for header)
https://www.flexmonster.com/question/tooltips-on-header-of-the-kpis/
Hello, Josh!
Thank you for reaching out to us and providing us with the attachments.
Please find the detailed answers to your questions below:
1. The ability to sort columns in the pivot table exists for measure columns, but how about dimension columns?
Members in Flexmonster can be sorted from the UI and via the report.
To sort members from the UI:
A-Z
or Z-A
.
2. Is it possible to customize the dimension column header to display a button which uses a drop-down menu?
We kindly suggest using the context menu combined with the setSort()
API call to achieve the desired behavior.
Here is a short guide on how to implement it:
customizeContextMenu()
API call, which will iterate over all cells.data
parameter of the customizeFunction
.setSort
as follows:{
label: "sort in Ascending order",
handler: function() {
flexmonster.setSort(data.hierarchy.uniqueName, "asc");
}
}
We have prepared a JSFiddle example: https://jsfiddle.net/flexmonster/f5m348vc/. Right-click any hierarchy name(Color or Country) to see the result.
For more details about customizing the context menu, please visit our docs: https://www.flexmonster.com/doc/customizing-context-menu/.
We kindly provide the article about the setSort
API call as well: https://www.flexmonster.com/api/setsort/.
3. How do I add a tooltip for pivot table cell data?
Kindly note that tooltips can be added only to the headers. We suggest considering a context menu approach as a workaround.
Hope you will find this answer helpful.
Regards,
Solomiia
Hello, Josh!
Hope you are doing well.
Our team is wondering if you had some time to look through our recommendations. Could you please let us know if our answer was helpful?
Looking forward to hearing from you.
Regards,
Solomiia
Yes, #1 and #2 works. I was able to customize the context menu i.e. right-click options to include sort for the dimension headers. #3 did not match the UX design so we passed on it.
Hello, Josh!
Thank you for your feedback.
We are glad to hear that our suggested approaches work for you.
Feel free to contact us if any other questions arise.
Best regards,
Solomiia