Я использую Highsoft.Web.Mvc.Charts
. У меня есть круговая диаграмма, и она развернута вниз. Я хочу открыть столбчатую диаграмму после нажатия на любую точку развернутой круговой диаграммы.Мой код:
<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://code.highcharts.com/modules/exporting.js"></script>
<script src="https://code.highcharts.com/modules/drilldown.js"></script>
@using Highsoft.Web.Mvc.Charts
@{
Highcharts chart2 = new Highcharts
{
Title = new Title
{
Text = "Total Pages Accessed by Teams"
},
Subtitle = new Subtitle
{
Text = "RiO."
},
XAxis = new List<XAxis>
{
new XAxis
{
Type = XAxisType.Category
}
},
YAxis = new List<YAxis>
{
new YAxis
{
Title = new YAxisTitle
{
Text = "Total percent market share"
}
}
},
Legend = new Legend
{
Enabled = false
},
Tooltip = new Tooltip
{
HeaderFormat = "<span style='font-size:11px'>{series.name}</span><br>",
PointFormat = "<span style=\"color:{point.color}\">{point.name}</span>: <b>{point.y}</b> Pages<br/>"
},
PlotOptions = new PlotOptions
{
Series = new PlotOptionsSeries
{
DataLabels = new PlotOptionsSeriesDataLabels
{
Enabled = true,
Format = "{point.name}: {point.y}"
},
Cursor = PlotOptionsSeriesCursor.Pointer,
Point = new PlotOptionsSeriesPoint
{
Events = new PlotOptionsSeriesPointEvents
{
}
}
}
},
Series = new List<Series>
{
new PieSeries
{
Name = "Teams data",
Data = @ViewData["pieData"] as List<PieSeriesData>
}
},
Drilldown = new Drilldown
{
Series = @ViewData["Series"] as List<Series>
}
};
}
@Html.Highsoft().GetHighcharts(chart2, "chart2")
Заранее благодарен за любую помощь.