Creating letters using reports

We are trying to use cuba reporting for creating letters. We simply created docx report templates for each letter type. This seems to work fine. Now I have two questions:

1. Meta Template

The basic structures of most letters are the same (header, footer). There are only a few structures that have each many templates. We could include the header and footer in each template. But when the basic structure changes (e.g. new CEO) we would have to change all templates.
Is there a strategy to define such a “meta template” that defines the structure of a report and separate it from the “content template”?

2. Postprocessing

After the letter (report) has been created, we store it as FileDescriptor. Our users would like to edit the letter after is has been created (e.g. correct spelling, add sentence). They could simply download -> edit in Word -> upload the letter. But this is quite complicated for the user.
I could think about two alternatives:

  • Using a web-based word editor (like onlyoffice)
  • Using html as report format an use the rich text for postprocessing. After that the html could be converted to docx.

Do you have any ideas / experiences how to improve the postprocessing of letters?

Thanks for sharing your ideas.


Hello Joerg,

  1. Reporting doesn’t support a “meta template” that defines the structure of a report, and we have no plans for implementing it. As a workaround, you can define header/footer as HTML content that is generated in Groovy datasets. HTML content can be inserted in a report using field value formats.

  2. You can create a report in HTML format and use for example CKEditor Vaadin addon for online editing. Another solution would be a MS Office plugin. We have some experience creating a plugin that helps editing a file in desktop Word: the user downloads and edits file in Word, then clicks a custom button on the Word toolbar and the plugin uploads the file back to the CUBA application.