How can I make chart holding render until the datamanger get the new response

Hi Team,

Can I ask you a question? I have a chart and I want it to re-render when I toggle a switch. The thing is , the url of the DataManager will change once I toggle the switch, but the chart will re-render before the new data being feed back from the back-end. What can I do to achieve this feature?

Really appreciate your help



6 Replies

DG Durga Gopalakrishnan Syncfusion Team March 14, 2020 06:21 PM UTC

Hi Feifan, 
 
We are validating your reported scenario. We will update the status within two business days(17th March, 2020). We appreciate your patience until then. 
 
Regards, 
Durga G 



BP Baby Palanidurai Syncfusion Team March 18, 2020 01:38 PM UTC

Hi Feifan,  
  
Greetings from Syncfusion.  
  
  
We are able to reproduce the reported issue from our end. So, we have created a feedback for this, and we will resolve this issue and include in our first weekly release after our volume 1 main release, which is expected to be roll out at First week of April 2020.   
  
  
The provided feedback link is private, and you need to login to view this feedback. If you have any more specification/precise replication procedure or a scenario to be tested, you can add it as a comment in the portal  
  
  
Regards,  
Baby.  



DG Durga Gopalakrishnan Syncfusion Team April 15, 2020 03:18 PM UTC

Hi Feifan, 

We regret for inconvenience. Due to some technical difficulties, we are unable to provide the fix for reported issue. We will include the fix in our upcoming volume 1 sp1 release which is expected to be out at the mid of May 2020. We appreciate your patience until then 

Regards, 
Durga G 



DG Durga Gopalakrishnan Syncfusion Team May 14, 2020 02:45 PM UTC

Hi Feifan, 
 
We will include the fix for reported issue in our upcoming volume 2 main release which is expected to be rolled out at end of June, 2020. We appreciate your patience until then. 

Regards, 
Durga G 



DG Durga Gopalakrishnan Syncfusion Team July 20, 2020 01:02 PM UTC

Hi Feifan, 

We regret for inconvenience. Since the reported issue is related to core team, we have forwarded this to concern team. We will include the fix in our upcoming volume 2 SP 1 release which is expected to be rolled out at end of August, 2020. We appreciate your patience until then. 

Regards, 
Durga G  



DG Durga Gopalakrishnan Syncfusion Team July 23, 2020 12:50 PM UTC

Hi Feifan, 
 
The DataManager properties cannot be modified or changed after initializing, hence datamanager URL property cannot be changed on a toggle switch. Instead we suggest you to change the DataManager instance itself on toggle button switch. Kindly refer the below code example   
  
<SfSwitch @bind-Checked="isChecked" TChecked="bool" ValueChange="changed"></SfSwitch>    
<SfChart>  
    @if (isChecked)  
    {  
        <SfDataManager Url="https://ej2services.syncfusion.com/production/web-services/api/Orders" Adaptor="Adaptors.WebApiAdaptor"></SfDataManager>  
    }  
    else  
    {  
        <SfDataManager Url="https://mvc.syncfusion.com/Services/Northwnd.svc/Tasks"></SfDataManager>  
    }  
    <ChartPrimaryXAxis Title="Orders" ValueType="Syncfusion.Blazor.Charts.ValueType.Category"  
                       RangePadding="ChartRangePadding.Additional"></ChartPrimaryXAxis>  
    <ChartSeriesCollection>  
        <ChartSeries XName=@YName=@Type="ChartSeriesType.Column"></ChartSeries>  
    </ChartSeriesCollection>  
</SfChart>  
   
@code{  
    public string x { getset; } = "OrderID" 
    public string y { getset; } = "Freight" 
   
    private bool isChecked = true 
   
    private void changed(Syncfusion.Blazor.Buttons.ChangeEventArgs<bool> args)  
    {  
        if (!args.Checked)  
        {  
            this.x "Assignee" 
            this.y = "Estimate" 
        }  
        else  
        {  
            this.x = "OrderID";  
            this.y = "Freight";  
        }  
        this.StateHasChanged();  
    }  
}  
  
Kindly download the sample from below   
  
  
Please get back to us if you have further queries.   
 
Regards, 
Durga G 


Loader.
Up arrow icon