creativetimofficial / argon-dashboard

Argon - Dashboard for Bootstrap 5 by Creative Tim
https://www.creative-tim.com/product/argon-dashboard
MIT License
664 stars 1.23k forks source link

how to update chart value #36

Open KBiswas98 opened 4 years ago

KBiswas98 commented 4 years ago
rarestoma commented 4 years ago

Hi @KBiswas98,

Thank you for working with our products.

Can you please give me more details about what do you want to change?

Thank you, Rares

KBiswas98 commented 4 years ago

I want to update the value of the line chart, but i can't find the way to update the value..

rarestoma commented 4 years ago

Hi @KBiswas98,

You have to change the values in the argon-dashboard.js code. For example, for the "#chart-sales" visible in the index page, the values are: data: [0, 200, 10, 30, 15, 40, 20, 60, 60].

You have to update these values with the ones you need.

I hope it helps.

All the best, Rares

dtellogaete commented 4 years ago

I have the same question, I cannot change the values of data

katesaikishore commented 4 years ago

It's in argon.js file line number 922 and 848. Where for BootStrap Argon Dashboard.

Cheng-CM commented 4 years ago

I am using the laravel version, is there a good way (or good practices) to import data from blade front-end PHP's data to chart?

katesaikishore commented 4 years ago

No, @Cheng-CM I am trying to do the same.

Cheng-CM commented 4 years ago

@katesaikishore I found a solution from https://www.itsolutionstuff.com/post/how-to-add-charts-in-laravel-5-using-chart-js-example.html using window.onload in blade.php files. It does not use the code in argon.js though, i just make a new chart instead. Still looking for a better way to do this.

katesaikishore commented 4 years ago

Cool, It's awesome. Thanks.