This question has been flagged
2 Replies
5659 Views

I am on 6.0.3 and made modifications on General ledger and General ledger landscape report with module report designer + OpenOffice. I would like to come back to the original reports for in data base I've done the modification, how shall I do ? Thank you

Avatar
Discard
Best Answer

As you have discovered, you can make changes to the RML on the filesystem and it will affect all databases.

You also know you can make changes via OpenOffice, but the RML is stored in the database and only affects that database, AND you can no longer edit the RML on the filesystem since OpenERP will always use what is has in the database and never look at the RML files.

If you want to switch back to RML editing after you have edited in OpenOffice (and don't want to lose what you did in OpenOffice), you need to re-open the report in OpenOffice and save it as an SXW file. Then you need to convert it into RML (addons/base_report_designer/openerp_sxw2rm/openerp_sxw2rml.py <file.sxw> <file.rml>). Then delete the binary RML field in the database and copy the RML file back to the server. Now the changes you made in OpenOffice are in the RML file that the server will use and you can edit it again and see the changes on all databases.

The binary RML is stored in the report_rml_content_data column of the ir_act_report_xml table.

You can edit either the RML or via OpenOffice or any combination, you just have to remember where things get changed and reset accordingly.

Remember, once you delete the RML from the database, the RML on disk will be used. Once you edit a report in OpenOffice, the RML in the database will be used.

Avatar
Discard
Author

Very clear and detailed answer. Thank you for your time.

Best Answer

replace the modified files by the original.

account/report/your_rapport.rml

Avatar
Discard
Author

I don't think it is a matter of file because my reports are working fine for my other dbases. I "send to server" on OpenOffice so my modifications are on the dbase and haven't changed the files ?

So you can delete these reports in Settings/Actions/Reports . then restart your server with -u account

Author

Are you sure ? I don't want to delete them but to come back to the orginal ones.

yes ,I have already met this problem.and you can also try it with a test database before you apply in your base.

Author

So, in Administration / Customization / Low level objects / Actions / Reports I delete the 2 reports that I have modified. Then I restart my openerp server and my 2 reports will be back in the original format.

Author

Sorry, but what does "restart your server with -u account" means excatly ?

restart server : ~./openerp-server -u account . -u account (update module account).

This will replace your reports with the original ones, the ones that don't have any changes made in OpenOffice. If you want to save your changes, see my answer.

Author

Thank you for your help