jquery - Javascript function is not working in Google Chrome -
i have integrated geo map google visualization api pentaho. , works fine. when try implement click action in geo map, works on double click firefox , doesn't react chrome.
code reference:
function (values){ var series=[]; var column=[]; for(var i=0; < values.metadata.length; i++){ column[i]=values.metadata[i].colname; } series[0]=column; if (values.resultset.length > 0 ) { $.each(values.resultset, function(key, value) { var aux=value[0]+''; var find=' ['+(key+1)+']'; value[0]=value[0].replace(find,''); series[key+1]=value; }); } var data = google.visualization.arraytodatatable(series); var options = {width: 470,height: 370,colors: [0xffe96e, 0xfada1a, 0xff6600, 0xd4002a],region: 'in', datamode: 'regions'}; var geomap = new google.visualization.geomap(document.getelementbyid("kpi6299dtl")); function selecthandler() { var selecteditem = geomap.getselection()[0]; if (selecteditem) { var cntry = data.getvalue(selecteditem.row, 0); shownextlevelkpi(6299, cntry, 'y'); } geomap.setselection(selection); } google.visualization.events.addlistener(geomap , 'select', selecthandler); geomap.draw(data, options); }
i use 'select' event trigger map when click. dint errors in console google chrome.
thanks
Comments
Post a Comment