I have a pop-up chart in a tooltip template working for some column charts. The definition passes the dataitem to the template function, which then creates a pie chart in the tooltip.
This is working well for charts which dynamically create the series using a field in the dataitem.
However, I now have a stacked column chart using two fixed series, from two different value fields in the dataitem. To create the pop-up chart, I need to identify which series is being hovered over, but I can't work out how to pass this to the function, as the dataitem field names just seem to get parsed in a 'magical' way.
The chart definition is:-
The template definition is:-
The Mth and Year fields are in the dataitem, and get passed through to the function, but I also need the series name.
The template is defined in the script block as:-
And then the function createChildChart4 gets the data and builds the chart (or would do, if it had the series name). How do I pass the series name through to the function?