diff --git a/lib/google_visualr/base_chart.rb b/lib/google_visualr/base_chart.rb index f88d64b..a4df522 100644 --- a/lib/google_visualr/base_chart.rb +++ b/lib/google_visualr/base_chart.rb @@ -16,6 +16,10 @@ def chart_name class_name end + def chart_function_name(element_id) + "draw_#{element_id.gsub('-', '_')}" + end + def options @options end @@ -32,20 +36,22 @@ def add_listener(event, callback) # # Parameters: # *div_id [Required] The ID of the DIV element that the Google Chart should be rendered in. + def to_js(element_id) js = "\n" js end - end end