You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello fxcosta and thank you so much for the amazing work.
actually this library is working perfectly when i return the $chartjs object from controller to view directly and render it there, but i am now doing it through ajax call, i have the chartjs object ready there in controller and return the object from the controller function to the ajax call success function, but how do i render in the success function of ajax call? your help would be really appreciated.
thank you
The text was updated successfully, but these errors were encountered:
Hello fxcosta and thank you so much for the amazing work.
actually this library is working perfectly when i return the $chartjs object from controller to view directly and render it there, but i am now doing it through ajax call, i have the chartjs object ready there in controller and return the object from the controller function to the ajax call success function, but how do i render in the success function of ajax call? your help would be really appreciated.
thank you
hi.do you find a solution for your problem?i have same problem
I found a solution.
I try to implement some functions like this. After calling the ajax, we will add the data from ajax to update our Chart with this function
function addData(chart, data, datasetIndex) {
chart.data.datasets[datasetIndex].data = data;
chart.update();
}
function addLabel(chart, label) {
chart.data.labels = label;
chart.update();
}
This is an example addData(chart, newData, 0); or addLabel(chart, newLabel);.
Hello fxcosta and thank you so much for the amazing work.
actually this library is working perfectly when i return the $chartjs object from controller to view directly and render it there, but i am now doing it through ajax call, i have the chartjs object ready there in controller and return the object from the controller function to the ajax call success function, but how do i render in the success function of ajax call? your help would be really appreciated.
thank you
The text was updated successfully, but these errors were encountered: