This issue is related to the following issue: 2772211
When rendering multiple charts onto a page, including a GeoMap, JS errors appear and no GeoMaps are rendered. If the other charts are removed from the JavaScript, the GeoMaps will render, however whenever a LineChart or BarChart is on the same page, errors like the following appear:
VM11267:2 Uncaught ReferenceError: gvjs_BM is not defined
This seems to have a very simple fix by changing:
if (typeof google !== 'undefined') {
google.load('visualization', '1', { callback: renderCharts });
}
to this:
if (typeof google !== 'undefined') {
google.load('visualization', '1', { callback: renderCharts, packages: ['corechart'] });
}
In the charts_google.js file, I have provided a patch for this issue.
Comments
Comment #2
splendidles commentedComment #3
firewaller commentedThis works great, fixes the error for me.
Comment #4
TylerMarshall commentedPatch applies cleanly to fresh install, vote to move to RTBC.
Comment #5
rob c commentedThis patch seems to address the problem described at #2772211: Customer Map not showing - JS error (together with a patch from that issue to fix other js errors).
Updating to RTBC to get some attention to this issue.
I did already test with latest charts from the repo and while at 050670f the line chart from commerce_reports sales breaks terribly, so we first might want to make sure commerce_reports sales works with the latest version of charts (and where it breaks, downgrading to 2.0-rc1 made it work again in my case).
Comment #7
andileco commentedComment #8
andileco commented