Class: PieChartGenerator
- Inherits:
-
BaseGenerator
- Object
- BaseGenerator
- PieChartGenerator
- Defined in:
- lib/chart_generators/pie_chart_generator.rb
Instance Method Summary collapse
-
#generate(element, csv_url) ⇒ Object
generate horizontal bar chart element - div id or class for chart csv_url - file with [ X , Y ] data table.
Methods inherited from BaseGenerator
#add_assets, #css_code, #js_code
Instance Method Details
#generate(element, csv_url) ⇒ Object
generate horizontal bar chart
element - div id or class for chart
csv_url - file with [ X , Y ] data table
6 7 8 9 |
# File 'lib/chart_generators/pie_chart_generator.rb', line 6 def generate( element, csv_url ) add_assets( "#{element[1..-1]}"+'.js', js_code( element, csv_url ) ) add_assets( "#{element[1..-1]}"+'.scss', css_code( element ) ) end |