Tuesday, 15 April 2008

New reports and charts model for Openbravo POS

To create new reports or to modify existing ones has been a painful task for Openbravo POS developers. Although the engine used is JasperReports and there are great tools to create new reports like iReport. To include a new report in Openbravo POS you needed to create a new java file to define the title, SQL sentence, parameters, and all the report parameters, to modify the menus, to compile the application and pray...

The next release of Openbravo POS, the version 2.10, includes a new model to develop reports and charts, and as a proof of concept all the reports bundled with Openbravo POS has been ported to the new model. With the new model you do not need neither to touch any single line of source code nor to compile the application. With this new model you will decrease the time and money you need to implement Openbravo POS and to adapt it to your business needs and legal requirements.

New reports and charts can be included just adding plain text files to the Openbravo POS folder /reports. A report consist in three files: The configuration file, the report file and the translations file. The configuration file is the most important one, there you define the title, the SQL sentence to get the report data, parameters, fields, what is the report file and what is the translations file. The report file is the JasperReports file and you can edit this file with iReport. And the translations file is used to define literals that need to be translated.

The bundled Openbravo POS reports are great to have a look if you want to include your own reports in the application, there you will find examples of all the possibilities to create new reports for Openbravo POS.


camelia said...

Hi, I'm an italian java programmer and i'd use Openbravo and iReports. I made some changes on the RptC_Invoice.jasper, I override the existing file, but opening Openbravo, the changes aren't executed.What can i do? Thank you, Camelia Boban.

Adrián Romero said...

Hello. I think that you are talking about an Openbravo ERP report, not an Openbravo POS report. It will be better to write your question on the support forums because I do not now the answer. https://sourceforge.net/forum/forum.php?forum_id=549511


Adrián Romero

licences professionnelles alternance said...

Hi Adrian,

I find a issue when changing the file productlabels.jrxml (in folder reports from opt/...)

Using ireport 1.5 It does nothing when restarting the POS.

More fun, it works also with standard labels when the file is DELETED and the POS restarted !

I work with last OPENBRAVOPOS 2.3

PS: I had to paste the original heading code on productlabels.jrxml when I was using the previous 2.2 POS version, and ireport 1.3

Anonymous said...

hi adrian, i have openbravo pos installed and running and i have downloaded the sales by customer report from openforge, however if you have used it, this report gives you a good sales by customer and filter by date report, however i would like this to give you a subtotal by each products, could you help me with that?

vinay said...

I am new to openbravo POS ,

I have downloaded the following report file http://forge.openbravo.com/plugins/esp_frs/file.php?id=275&group_id=304&relid=308

and have extracted and added to com\openbravo\reports , but i am not sure the reports are not visible any were in my application , can any one help me to resolve it ?

Thank You