Version 30 (modified by 15 years ago) ( diff ) | ,
---|
Table of Contents
Blueprint for Reporting/Charting
We need to be able to generate Pretty & Informative Reports from the database.
e.g. for BluePrintImpact
These can be implemented as an S3XRC Custom method
Charts
For quick visualisations in the browser, we have included jqPlot.
We have included the Healthscapes SaVaGe library to easily output SVG graphs:
- http://eden.sahanafoundation.org/browser/modules/hs/graph
- We should have a recommended tested SVG plugin for Internet Explorer < 9
T2 includes a basic barchart function:
def barchart(data,width=400,height=15,scale=None, label_width=50,values_width=50): if not scale: scale=max([m for n,c,m in data]) if not scale: return None return TABLE(_class='barchart', *[TR(TD(n,_width=label_width,_style="text-align: right"), TABLE(TR(TD(_width=int(m*width/scale),_height=height, _style='background-color:'+c))),TD(m,_width=values_width), _style="vertical-alignment: middle") for n,c,m in data])
- Matplotlib can generate visualisations
- Cairo can generate nice charts from the back-end
Map
We want to be able to provide reports suitable for displaying inside popups on Map Polygons:
For more formal reports (which can also be retrieved via webservices using the PDF representation of the REST Controller), we currently use ReportLab via Geraldo. This also supports Graphics (via PIL)
Other options:
- http://www.reynoldsftw.com/2009/02/6-jquery-chart-plugins-reviewed/
- Recommends Flot: "From an interaction perspective, Flot by far will get you as close as possible to Flash graphing as you can get with jQuery."
- Pisa uses ReportLab to generate PDF from HTML
- jsPDF uses pure JavaScript to create PDFs
- Use S3XRC & hence XSLT to generate XML-FO which can be converted to PDF
Spreadsheets
Excel files are currently written using xlwt. Other options:
- PyExcelerator
- Docs on Python Excel libraries: http://www.python-excel.org/
- Thread recommending xlwt: http://groups.google.com/group/web2py/browse_thread/thread/375307e92df40ca8
- Pod to create Open Document Format
Flash
Could be something to use Flash? (although best-avoided, if possible, to minimise client support)
- PyAMF: http://pyamf.org
- Web2Py integration: http://mdp.cti.depaul.edu/AlterEgo/default/show/22
- BirdEye: http://code.google.com/p/birdeye/
- FusionCharts Free: http://www.fusioncharts.com/Free/
- Open Flash Chart: http://teethgrinder.co.uk/open-flash-chart-2/
- from Python: http://code.google.com/p/open-flash-chart-python/
Relevant Links
Phase2 version: