Javascript 如何获取Jquery库中的特定属性?

Javascript 如何获取Jquery库中的特定属性?,javascript,jquery,ajax,Javascript,Jquery,Ajax,伙计们,我在Jquery自定义库中编写了以下代码,用于在ASP.NETMVC应用程序中绘制图表。现在我想使用ajax调用更改其中的一个特定值。请看一下我的代码: 从Jquery自定义库: $('#performance-cart').highcharts({ chart: { type: 'area', backgroundColor: '#f5f7f7', style: { fontFamily: 'Roboto, Sans-serif', color

伙计们,我在Jquery自定义库中编写了以下代码,用于在ASP.NETMVC应用程序中绘制图表。现在我想使用ajax调用更改其中的一个特定值。请看一下我的代码:

从Jquery自定义库:

 $('#performance-cart').highcharts({
        chart: {
            type: 'area', backgroundColor: '#f5f7f7', style: { fontFamily: 'Roboto, Sans-serif', color: '#aeafb1' },
            animation: {
                duration: 1500,
                easing: 'easeOutBounce'
            }
        },
        xAxis: {
            type: 'datetime',
            labels: { style: { color: '#aeafb1' } }
        },
        yAxis: {
            min: 0, max: 50, tickInterval: 10, gridLineColor: '#ebeded', gridLineWidth: 1,
            title: { text: '' }, lineWidth: 0, labels: { align: 'right', style: { color: '#aeafb1' } }
        },
        title: { text: '' },
        tooltip: {
            useHTML: true, headerFormat: '<h3 style="color:#ffffff;font-weight:300;padding: 3px 12px;">{point.y:,.1f}</br>',
            backgroundColor: '#515757', pointFormat: 'Issues</h3>'//$('#performanceColumnChart').data('tooltip')
        },
        legend: {
            itemStyle: { color: '#838589' }, symbolWidth: 12, symbolHeight: 5, itemWidth: 80, symbolRadius: 0,
            itemMarginBottom: 10, backgroundColor: '#f5f7f7', verticalAlign: 'top', borderWidth: 0, x: -498, y: 10
        },
        plotOptions: {
            area: {
                fillOpacity: 0.2, cursor: 'pointer', marker: {
                    symbol: 'circle', fillColor: '#FFFFFF', lineWidth: 2, lineColor: null,
                    allowPointSelect: true
                }
            },
            line: {
                fillOpacity: 0.2, cursor: 'pointer', marker: {
                    symbol: 'circle', fillColor: '#FFFFFF', lineWidth: 2, lineColor: null,
                    allowPointSelect: true
                }
            },
            column: {
                fillOpacity: 0.2, cursor: 'pointer', marker: {
                    symbol: 'circle', fillColor: '#FFFFFF', lineWidth: 2, lineColor: null,
                    allowPointSelect: true
                }
            },
            series: {
                pointStart: myIssueResolvedStartDate,
                pointInterval: 24 * 3600 * 1000 // one day
            }
        },
        series: [{
            name: 'Issues', color: '#ff3806',
            data: myIssueData,
            marker: { states: { hover: { fillColor: '#ff3806', lineColor: '#ffffff', lineWidth: 2 } } }
        }, {
            name: 'Resolved', color: '#1da9dd',
            data: myResolvedData,
            marker: { states: { hover: { fillColor: '#1da9dd', lineColor: '#ffffff', lineWidth: 2 } } }
        }]
    });
现在我想通过ajax调用替换jquery库的
pointStart
元素中的日期值,但我不知道如何访问该属性


我尝试使用
chart.plotOptions.series.setpointStart(ResolvedStartDate,true)但它说plotOptions未定义。如何获得
pointStart
以从
ResolvedStartDate
获取日期值?

您可以尝试使用单个系列的新选项更新系列-请参阅您可以尝试使用单个系列的新选项更新系列-请参阅我只需要这个简单的单行代码

chart.options.plotOptions.series.pointStart = newDate

其中newDate是UTC格式的newDate的变量。

我只需要这个简单的单行代码

chart.options.plotOptions.series.pointStart = newDate

其中,newDate是UTC格式的新日期的变量。

谢谢,但我仍然不知道如何更新我的
startPoint
,我正在该论坛上到处寻找。尝试将其包括在您的代码(如果需要,添加第二个系列)图表中。系列[0]。更新({pointStart:ResolvedStartDate});您必须将ResolvedStartDate定义为pointStart接受的数字(如果尚未定义数字)。您可以使用Date.UTC()进行转换,谢谢,但我仍然不知道如何更新我的
startPoint
,我正在该论坛上到处寻找。请尝试将此包含在您的代码(如果需要,请添加第二个系列)图表中。系列[0]。更新({pointStart:ResolvedStartDate});您必须将ResolvedStartDate定义为pointStart接受的数字(如果尚未定义数字)。您可以使用Date.UTC()转换,