User Tools

Site Tools


Plugin installed incorrectly. Rename plugin directory 'swiftmail.backup' to 'swiftmail'.
This translation is older than the original page and might be outdated. See what has changed.
en:software:tim:smartform:pdf_button

Table of Contents

PDF Buttons

It is possible to implement a button in th smartform, which can convert WOrdtemplates into PDFs via a click on the button. For that the following code has to be put into the smartform and has to be adjusted.

<button type="button" onbuttonclick="generateFileFromTemplate([{handler:'WordTemplateHandler',template:'super/templates/${NOW}.docx',documentPrefix:'Test_Prefix',pdf:true,attach:false,open:true}])">PDF Button</button>

The attribute “onbuttonclick” defines what functions the handler should execute.

  • handler: Here the WordTemplateHandler is sepcified.
  • template: Here the path to the WordTemplateHandler is specified.
  • documentPrefix: Here the prefix, which should be put before the document, can be defined.
  • pdf : If true is put here, the WordTemplate will be put out in the form of a PDF. (true or false)
  • attach :Here it can be specified, whether the PDF should be attached to the processinstance or not (true or false)
  • open :Here it can be specified, whether the PDf should be opened in the brwoser or not.
en/software/tim/smartform/pdf_button.txt · Last modified: 2021/07/01 09:52 (external edit)