-
Notifications
You must be signed in to change notification settings - Fork 141
Open
Description
What Version?
3.1.14
Issue
Uncaught ReferenceError: selectHandler is not defined
Controller Code (chart creation code)
\Lava::GeoChart('Province Orders', $provinceOrderDttb, [
'displayMode' => 'auto',
'enableRegionInteractivity' => true,
'keepAspectRatio' => true,
'region' => 'US',
'magnifyingGlass' => ['enable' => true, 'zoomFactor' => 7.5], //MagnifyingGlass Options
'markerOpacity' => 1.0,
'resolution' => 'provinces',
'sizeAxis' => null,
'events' => ['select' => 'selectHandler']
]);
View Code
// I defined it in head tag
<script>
[home.txt](https://github.com/kevinkhill/lavacharts/files/8923487/home.txt)
lava.js(function() {
function selectHandler(event, chart) {
console.log('Hi');
}
})
</script>
// Here is render charts which are below script
<?= \Lava::render('GeoChart', 'Province Orders', 'province-order-chart') ?>
<?= \Lava::render('PieChart', 'District Orders', 'district-order-chart') ?>
Hope you support it!
Metadata
Metadata
Assignees
Labels
No labels