score:2

Accepted answer
success: function (items) {

    var obj = jsonParse(items.d);

    $.each(obj, function (itemNo, item) {
        series = new Array();
        if (itemNo == 0) {
            series.data = item.data;
            series.name = item.name;
            series.type = item.type;
        } else if (itemNo == 1) {
            series.type = item.type;
            series.data = item.data;
            series.name = item.name;
            series.center = item.center;
            series.size = item.size;
            series.showInLegend = item.showInLegend;
        }
        options.series.push(series);
    });

    chart = new Highcharts.Chart(options);
    console.log(options);

},

This loop never adds a second series, you are only getting the last one in the loop because it is over writing the one before.

My changes may solve the problem, I am not near a computer at the moment to check.


Related Articles