amcharts / dataloader

Apache License 2.0
25 stars 25 forks source link

Loading the chart via Ajax, causes DataLoader to run multiple times. #16

Closed cxevan7 closed 7 years ago

cxevan7 commented 8 years ago

So I have a page that loads the page the chart displays on via Ajax, it works fine, the dataLoader does it's job, but I notice if I load another page after that with another dataLoader, it now adds another ajax call, so if I look at 5 different charts, by the time I look at the 5th chart it has 5 unique ajax requests being made by the dataLoader, is there something that can be done to fix this?

martynasma commented 7 years ago

Hey,

Sorry, this one slipped through the cracks. GitHub is not being monitored by our support staff.

Would you rather load all of the data for all of the charts on the web page at once?

In that case, you might want to load the data using standalone functions from Data Loader, store it in some variable, then use it when creating a new chart instance.

Here's some more info on how to do so:

https://github.com/amcharts/dataloader#using-data-loaders-standalone-functions

cxevan7 commented 7 years ago

I just wrote my own Ajax Loader to avoid using the dataLoader.

Cory Evans System Administrator Tel: +1(801)874-9500 Fax: +1(801)766-8441 Email: sysadmin@motherslounge.com mailto:sysadmin@motherslounge.com Web: www.motherslounge.com http://www.motherslounge.com http://www.motherslounge.com/ Mothers Lounge, LLC

363 W Industrial Dr. Pleasant Grove, UT 84062

Disclaimer

This e-mail message may contain confidential and privileged information and is intended only for the use of the recipient(s) named above. If you are not an intended recipient, you may not review, copy or distribute this message. If you have received this communication in error, please notify us immediately by email and delete the original message.

On 12/15/2016 1:55 AM, Martynas Majeris wrote:

Hey,

Sorry, this one slipped through the cracks. GitHub is not being monitored by our support staff.

Would you rather load all of the data for all of the charts on the web page at once?

In that case, you might want to load the data using standalone functions from Data Loader, store it in some variable, then use it when creating a new chart instance.

Here's some more info on how to do so:

https://github.com/amcharts/dataloader#using-data-loaders-standalone-functions

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/amcharts/dataloader/issues/16#issuecomment-267272743, or mute the thread https://github.com/notifications/unsubscribe-auth/AKspeglFZqIckrO4W_9QvGhcal5pL11Eks5rIQCZgaJpZM4J53nd.


This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus

martynasma commented 7 years ago

Gotcha. Thanks.