Uncaught TypeError: Невозможно прочитать свойство 'FN' неопределенной ошибки при добавлении любого фильтра - PullRequest
0 голосов
/ 02 марта 2019

Я работаю на asp.net MVC.И я использую диаграмму Zing, она отлично работает, когда я не добавляю никакой фильтр местоположения, но когда я добавляю какой-либо фильтр местоположения, показывается и zingchart, но последняя таблица не открыта и выдает ошибку:

UncaughtTypeError: Невозможно прочитать свойство 'FN' неопределенного в HTMLAreaElement.p.SM (eval at (zingchart.min.js: 8),: 1: 490052) в HTMLDocument.e (eval at (zingchart.min.js: 8),: 1: 87308)

Мой сценарий:

<script>
$(document).ready(function () {

    GenerateChart(FileLocationFinancial.value);

});
var month = "";

function GenerateChart(FileLocation) {

    $('#chartDiv3').html(" ");
    url = "../Report/FinancialMonthly?LocationName=" + FileLocation;
    $.ajax(
        {
            url: url,
            type: "GET",
            async: true,
            success: function (data, textStatus, jqXHR) {
                $('#chartDiv3').html('');
                setTimeout(function () {
                    zingchart.render({
                        id: "chartDiv3",
                        height: 800,
                        width: "100%",
                        data: data
                    });
                }, 1000);
            },
            error: function (jqXHR, textStatus, errorThrown) {
                alert("Failed to get data. Please contact support team.")
                //if fails
            }
        });

    zingchart.node_click = function (p) {
        debugger;
        console.log("Plotindex "+p.plotindex);
        console.log("nodeindex "+p.nodeindex);
        console.log("id " + p.id);

        if (p.graphid === "chartDiv3-graph-months")
        { 

            url = "../Report/FinancialDailyList?month=" + month + "&day=" + p.scaletext + "&FileLocation=" + FileLocation;
            $.ajax(
                {
                    url: url,
                    type: "GET",
                    async: true,
                    success: function (data, textStatus, jqXHR) {
                        debugger;
                        setTimeout(function () { $("#dailyList").html(data); }, 1000);
                        // $("#dailyList").html(data);
                    },
                    error: function (jqXHR, textStatus, errorThrown) {
                        alert("Failed to get data. Please contact support team.")
                    }
                });
        }
        else {
            setTimeout(function () {
                month = p.scaletext;
                $("#dailyList").html("");
            }, 1000);
        }
    }
}

$("#FileLocationFinancial").change(function () {
    // console.log(FileLocationFinancial.value);
    var data = FileLocationFinancial.value;
    $("#dailyList").html(" ");
//    $('#chartDiv3').html(" ");

    GenerateChart(data);

});

...