Pie chart problem after upgrading to 18.2.48

Hi

After updating to 18.2.48, I encountered a new problem with the same code I had just before the updating.
I deleted package.lock.json and @syncfusion folder before doing the update.

The problem: When I call
this.$refs.theChart.ej2Instances.refresh();
The chart disappears. If I remove ...refresh(); the chart is shown but when I change the datasource content, obviously it is not
updating the chart's visual.
Again, the same code exactly was working with 18.2.46 (I skipped 18.2.47)

                        for (var item in response.data.result) {
                            this.theSeries.push({
                                x1: item,
                                y1: response.data.result[item],
                            });
                        }
                        this.addedSeriestrue;
                   this.$refs.theChart.ej2Instances.refresh();

                <ejs-accumulationchart
                    ref="theChart"
                    style="height:100%"
                    v-show="addedSeries"
                    :tooltip="tooltip"
                    id="chart"
                    background="transparent"
                    :legendSettings="theLegend"
                    :tooltipRender="tooltipRender"
                >
                    <e-accumulation-series-collection>
                        <e-accumulation-series :dataSource="theSeries" type="Pie" xName="x1" yName="y1" />
                    </e-accumulation-series-collection>
                </ejs-accumulationchart>


3 Replies 1 reply marked as answer

SM Srihari Muthukaruppan Syncfusion Team August 10, 2020 08:11 AM UTC

Hi Amos, 

 
We have analyzed your query. From that, we would like to let you know that the refresh event in the chart is working fine in the latest version 18.2.48Unfortunately, we are unable to reproduce the reported scenario. We have also attached the sample used for testing for your reference. Please find the below screenshot, and sample.  
  
 

 
Code Snippet: 
// add your additional code here 
<ejs-chart ref="chart" style="display:block;" :loaded="onChartLoad" :primaryXAxis='primaryXAxis' :enableCanvas='enableCanvas' :theme='theme' >
            <e-series-collection>
                <e-series :dataSource='seriesData' :marker='marker' :xName='xName' :yName='yName' :animation='animation' type='Line'> </e-series>
            </e-series-collection>
        </ejs-chart>
 
<ejs-button cssClass="e-info" @click.native="onChange" style="text-transform:none !important">Load 100K Points</ejs-button>
  // add your additional code here 
 
export default Vue.extend({
  data: function() {
    return {
        theme: theme,
        seriesData: [],
        enableCanvas: true,
        primaryXAxis: {
            majorGridLines: { color: 'transparent' }
        },
        animation: { enable: false },
        xName: 'x',
        yName: 'y',
        marker: {
            visible: false
        }
    };
  },
  provide: {
    chart: [LineSeries, Legend]
  },
  methods: {
    onChange: function (e) {
        let series1= [];
        let point1;
        let value = 0;
        let i;
        for (i = 0; i < 100000; i++) {
            value += (Math.random() * 10 - 5);
            point1 = { x: i, y: value };
            series1.push(point1);
        }
        this.dt1 = new Date().getTime();
        this.$refs.chart.ej2Instances.series[0].dataSource = series1;
        this.$refs.chart.ej2Instances.refresh();
    },
 },
 
   

 
Screenshot: 
 
  

 
If you still face this issue. Kindly revert us with the following information which will be more helpful for further analysis and provide you the solution sooner.   
   
  • Try to reproduce the reported scenario in the above sample
  
  • Share the data source used in the project.
  
  • Share the details if you have done any other customization in your sample.
  
Regards, 
Srihari M 


Marked as answer

AM Amos August 10, 2020 10:24 AM UTC

OK, with how you implemented it, it works but notice that with 18.2.46 it worked with a "cleaner" code.
Meaning I defined :dataSource='seriesData' and then used seriesData itself to "play" with the data.
Now I need to define a new datasource (series1) every time and use it as the datasource.

So bottom line, it works but something was changed from version .46
Thanks



BP Baby Palanidurai Syncfusion Team August 11, 2020 12:09 PM UTC

Hi Amos, 

Thanks for your update. 
If you are still facing any problem, kindly revert us with your sample with detailed description which will be helpful in furthermore analysis and provide you the solution sooner. 

Regards, 
Baby.  


Loader.
Up arrow icon