<% @page_title="FusionCharts - Database + JavaScript (dataURL method) Example" %> <% @page_heading="FusionCharts RoR Samples" %> <% @page_subheading="Inter-connected charts - Click on any pie slice to see detailed chart below." %> <% @intro="The charts in this page have been dynamically generated using data contained in a database." %> <% # The xml is obtained as a string from builder template. str_xml = render :file=>"fusioncharts/db_js_dataurl/factories_quantity", :locals=>{:factories=>@factories} #Create the chart - Pie 3D Chart with data from str_xml render_chart('/FusionCharts/Pie3D.swf','',str_xml,'FactorySum', 500, 250, false, false) do-%> <% end -%>
<% #Column 2D Chart with changed "No data to display" message #We initialize the chart with #The last parameter to render_chart (registerWithJS) is set to true render_chart('/FusionCharts/Column2D.swf?ChartNoDataText=Please select a factory from pie chart above to view detailed data.','','','FactoryDetailed',600, 250, false, true) do-%> <% end -%>