Posted by Steven Jones on January 28, 2009 at 12:03pm
Jump to:
| Project: | FusionCharts |
| Version: | 6.x-1.x-dev |
| Component: | Fusioncharts for Views |
| Category: | support request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Issue Summary
Hello,
I'm trying to set up fusioncharts with views in Drupal 6. I have a few questions. I get that the module isn't finished, but would be willing to get it a little more finished to accomplish what I want.
When I select fusioncharts as the view's display style I'm presented with a baffling number of options, what do they all mean?!
Comments
#1
The fusioncharts-views.tpl files needs the line:
<?php$fodder = array();
?>
adding near the top, otherwise you get quite a few foreach errors when the file tries to foreach over it.
#2
Hi John,
I've got as far as creating the interface for selecting the data for a view. Because each graph has so many settings, I am attempting to do a multi-step form within the Views UI. I haven't been successful in getting it working yet.
I haven't focused too much on the chart drawing part at all, so I'm not even sure if the module will currently draw charts at all.
Basically my plan is to run the fusioncharts views in two modes:
1 chart/field (a chart is drawn for each field added to the view). The aggregation method will set how to collect the data together (eg. count of distinct values). You will be able to optionally group a field by another field (eg field=taxonomy term, group by=content type)
The other method will be to take the sum of each field in the view and diaplay this as a bar. in this case a single chart will be returned.
#3
I've not had much success in doing this integration so I'm marking this as postponed for now. I think the charts module integrates with Views - I will probably end up joining forces with the developers of that module.
#4
Views integration is now in FusionCharts. It has a dependency on Views 3 (currently in alpha).
#5
Hey Aaron,
Just tested it, and I could select fusionchart as views style and select the fields and chart type but nothing is shown on preview or on the actual page display.
Any tips? Should I report this as a separate issue?
#6
It seems there was another fusioncharts views integration project for the IT Dashboard project for the White House, here is the source
http://it-dashboard.svn.sourceforge.net/viewvc/it-dashboard/trunk/webapp...
#7
Try the latest -dev version.
NB: You will need to use view 3 and set one field as a "group" field
#8
@aaron1234nz - In the past, I did some very specialized code whereby a view pulls back all the data required, then I achieve grouping and aggregation by some code using a hook: hook_views_post_render e.g.
MYFunction_views_post_render(&$view, &$output){
if($view->name == 'myview')
{
$output = myaggregation1($view, $fieldagg1, $fieldaggr2, $sortkey, ....
$chartlib = 'fusionmultistack', .....); //contains other varibales needed by fusioncharts
}
This then results in the chart being displayed and aggregated the way I want, and then calling the relevant fusioncharts functions. myaggregation() does all the grouping in php....
What I would really like is the ability for the user to interactively pick which fields to plot and aggregate, as opposed to showing some fixed charts - which was the requirement in this case.
With your fusioncharts views integration work, assuming myview pulls back various fields for plotting, how can we make it possible for the user to interactively pick which fields to plot, type of chart, etc., as opposed to predefining it in the views creation?
I am happy to discuss offline to see how to progress this.
#9
I, too, would like Fusion Charts to be integrated with Views. I have Fusion Charts installed and I've implemented Views 3.0 rc3 and have set up a group field. However, Fusion Charts does not appear as a Styles option.
Do you have any other recommendations of how to trigger the integration?
Thank you in advance,
#10
If someone uses this, how/where would they add it to their site? I downloaded the full tarball and have examined the directory structure. Is it a module like any other Drupal module? Should it be imported into Views? Should it be added to Libraries?
Thank you in advance,