Jasper Report in OpenERP



JasperReports is an open source Java reporting tool that can write to a variety of targets, such as: screen, a printer, into PDF, HTMl, Microsoft Excel RTF, ODT, Comma separated values  XML files.


Working With the OpenERP Jasper Reports:

    For working with OpenERP jasper Reports you need to download  jasper i-report and  OpenERP jasper reports module.

    you can Download jasper i-report latest version from Jasper official site and download  OpenERP jasper reports module and install it in OperERP 6.1. and install it
  
Jasper i-report:- http://community.jaspersoft.com/project/jasperreports-library

OpenERP  Jasper reports module: https://code.launchpad.net/~jasper-reports-commiters/openobject-jasper-reports/jasper-reports-6.1
      
After successfully installing jasper report module in OpenERP 6.1 there is menu in Client, To navigate menu of jasper-reports.

Setting -> Customization -> Jasper Reports

there is Two new menu in Jasper Reports:

1] Create Data Template:- From this menu we can create XMLTempalate file Which used as Data source.
2] Jasper Reports :- We can load report in OpenERP related object.

To create XML template file Open wizard and click on Create data template button, it create template file which use as connection with ireport.



In screen shot we see the wizard in model field select require model which you want create report, in Depth filed select depth 1, 2, it useful to access the other object relation field like one2many and many2one field. Then click on create button so here  xml template will be created and save it to proper path.

After Creating Template file open i-report and make connection using template file. Create new data source.

Working With the I-report :




Select template file which created from OpenERP client then press save, if you want test connection click on test it show successfully test connection.
 


After Creating data source, click on new and open jasper report template  chose one from list, as show in below figure.



Then save this .jrxml file in OpenERP jasper_report modules custom_reports directory. After that select field from data source and add filed.




After adding field in data source drag and drop all filed form report inspector tab in to Designer page. As show in figure.






After drag and drop filed we need show report in client so close i-report and go on Openerp client.

Go on Jasper report menu Setting > Customization > Jasper reports

it show the list view of jasper report created by you.




Click on create button, form view is there and fill required field name of report that you want so on particular object then select model, give service name and then select output of type of your like pdf, xls, .. etc.


In Jasper report files Field click on create button, form view open in this view select .jrxml file created form the i-report tick on Default and save and close it.




After following the step sale order jasper report is created when you click on save button


Finally report is created on sale order on object to view this report click on sales menu click on sales order in side bare sale order is there.



Hope that was helpful.


If I just made your day a little better then thank me with a coffee or maybe a pizza

Thanks,

Mayur Maheshwari









31 comments:

  1. Thanks Sir, Its very helpful

    ReplyDelete
    Replies
    1. Mayur Maheshwari - Techno-Functional Consultant Odoo (Openerp): Jasper Report In Openerp >>>>> Download Now

      >>>>> Download Full

      Mayur Maheshwari - Techno-Functional Consultant Odoo (Openerp): Jasper Report In Openerp >>>>> Download LINK

      >>>>> Download Now

      Mayur Maheshwari - Techno-Functional Consultant Odoo (Openerp): Jasper Report In Openerp >>>>> Download Full

      >>>>> Download LINK Ra

      Delete
  2. How about this :

    Attribute 'uuid' is not allowed to appear in element 'jasperReport'."

    ReplyDelete
    Replies
    1. May be you get your answer here :

      http://stackoverflow.com/questions/11467874/cvc-complex-type-3-2-2-attribute-uuid-is-not-allowed-to-appear-in-element-jas

      Delete
  3. helpfull, it is done for me ! thanks

    ReplyDelete
  4. Thank you for the toturial. Can you explain the Service Name Field? I'm always getting an error with whatever I fill-in with,
    "report","hr","hr_contract", what I am doing wrong?

    ReplyDelete
  5. Hi,

    i'm in OE v7 and jaspert module is not yet so I must use rml report but graphics is not implemented in this report!

    Thanks

    ReplyDelete
  6. I m having problems in creating openerp report through jasper.

    ReplyDelete
  7. Hi mister Mayur Maheshwari ,
    I use jasper_report with openerp-6.0.4 but I have a problem to create a report for orders. when create my report only the first ligne of the sale.order.lines is taken. so I want to know how can I do to create a order report with all lines of orders.

    ReplyDelete
    Replies
    1. hi Jean Jonatha Arra,
      I have the same problem but I can not find a solution, please Have you find solution for this problem ?

      Delete
    2. Quick question to Belhadj: are you using XML or SQL as a datasource?

      Delete
  8. As you mentioned above , " Then click on create button so here xml template will be created and save it to proper path."

    I would like to know the path where this xml is stored.?

    ReplyDelete
    Replies
    1. It will store on your local system and may be by default in home folder

      Delete
    2. Thanks for the quick response. Infact I stored file with name as " template.xml" .Since I'm not sure about the path, I started seaching with file name. But Couldn't find my file. Please help

      Delete
    3. Also is there any way to save template.xml to specified folder ? I believe SAVE AS will do. But it is not...
      That is because dialog box which opens after clicking save as button doesn't have the option to save.

      Delete
    4. Did you get a chance to see my comment? Thank you

      Delete
  9. Instead of XML datasource, i am using SQL query.. When i print report,it shows empty pages. Please help if you have any clue

    Thanks

    ReplyDelete
  10. Hello Mayur, is it possible to configure the action that calls the report so that the file the system generates it's downloaded with a custom name?

    ReplyDelete
  11. Hi there, awesome site. I thought the topics you posted on were very interesting. I tried to add your RSS to my feed reader and it a few. take a look at it, hopefully I can add you and follow.

    SME ERP

    ReplyDelete
  12. I receive a report mistake when i click on to the report

    Failed to invoke method execute in class com.nantic.jasperreports.JasperServer: FATAL: password authentication failed for user "bala"


    my config file:

    [options]
    ; This is the password that allows database operations:
    ; admin_passwd = admin
    db_host = False
    db_port = False
    db_user = balaji
    db_password = odoo
    addons_path = /home/bala/odoo8.0/addons
    xmlrpc_port = 7077

    ReplyDelete
  13. I receive a report mistake when i click on to the report

    Failed to invoke method execute in class com.nantic.jasperreports.JasperServer: FATAL: password authentication failed for user "bala"


    my config file:

    [options]
    ; This is the password that allows database operations:
    ; admin_passwd = admin
    db_host = False
    db_port = False
    db_user = bala
    db_password = odoo
    addons_path = /home/bala/odoo8.0/addons
    xmlrpc_port = 7077

    ReplyDelete
  14. hi, where is locate jrxml file directory ? i need to edit a file is already inside the database in openerp
    Best regards

    ReplyDelete
  15. Ksolves Odoo custom report app comes to your great use as it enables you to display your data in the flat data structure, which means that there is no need for multiple clicks to get to your desired results. ReportMate plays a big role in up surging your business productivity & saving the precious time of your developers.

    ReplyDelete
  16. Mayur Maheshwari - Techno-Functional Consultant Odoo (Openerp): Jasper Report In Openerp >>>>> Download Now

    >>>>> Download Full

    Mayur Maheshwari - Techno-Functional Consultant Odoo (Openerp): Jasper Report In Openerp >>>>> Download LINK

    >>>>> Download Now

    Mayur Maheshwari - Techno-Functional Consultant Odoo (Openerp): Jasper Report In Openerp >>>>> Download Full

    >>>>> Download LINK pr

    ReplyDelete
  17. This comment has been removed by the author.

    ReplyDelete
  18. Hi, I need how to generate jasper report in Odoo 14.

    ReplyDelete