I wanted to use fusioncharts free on my views so far after making changes to IT version I am able to use the attached one but since still in progress and only singlecharts working.. please try on your system and let me know things go wrong.. thank you...

CommentFileSizeAuthor
views_fusioncharts.zip13.2 KBmroscar

Comments

mroscar’s picture

working on grouping

 function views_fusioncharts_views_pre_execute(&$view) {
 watchdog('info','tried to use views_pre_execute');
 $options = $view->style_plugin->options;
 
 		if (isset($options['basic']['fields']['usegroup']) && intval($options['basic']['fields']['usegroup']) > 0) {
		switch($view->name) {
		// This is View Name
		case $view->name:
			switch($view->current_display) {
			// If it's the block on the author page
			case $view->current_display: 
			// Set the extra argument 
			$view->build_info['query_args'][2] = $view->build_info['query_args'][1];
			// Rewrite the query 

			$view->build_info['query'] = "SELECT DATE(field_date_value) AS node_data_field_date_field_date_value, SUM(field_newproff_value) AS node_data_field_date_field_newproff_value FROM content_type_tip GROUP BY node_data_field_date_field_date_value ORDER BY node_data_field_date_field_date_value DESC";
		

			break;
			} // end switch display
			
		break;
 
	   } // end switch viewname
	   
	   } // usegroup
 
} // end pre_execute