I wanted to display real HTML reports created in IReport as a dashlet. As i never use HTML reports in other places than this i decided to do a quick hack that may break other things with HTML reports.
As far as i can see there are no problems till now, pdf reports are not affected.
What has to be done:
1. unpack the attached zip file to sugar\modules\ZuckerReports\Dashlets
2. Add the following line in sugar\modules\ZuckerReportTemplate\ReportTemplate. php
It is around line 250.
Original:
Changed:Code:fclose($f); $classpath = $this->get_classpath(); $result = $this->execute_java("-classpath ".$classpath." at.go_mobile.zuckerreports.JasperBatchMain ".$cmdfile); if ($zuckerreports_config["debug"] != "yes") $this->rec_delete($tempdir); return $result; } function execute_java($args) {
3. Quick RepairCode:fclose($f); $classpath = $this->get_classpath(); $result = $this->execute_java("-classpath ".$classpath." at.go_mobile.zuckerreports.JasperBatchMain ".$cmdfile); if ($zuckerreports_config["debug"] != "yes") $this->rec_delete($tempdir); if($format == 'HTML') $this->report_result = file_get_contents($archive_dir."/".$this->report_result_name); return $result; } function execute_java($args) {
4. Create a HTML runnable report from any jasperreport template
5. Add HTML Dashlet to your dashboard.
6. Choose your runnable report in the dashlet


LinkBack URL
About LinkBacks



Reply With Quote
Bookmarks