Custom XSL-FO Printing Template

This article is part of the systems administration guide. You will require administration access to view the pages mentioned in this article.

Custom XSL-FO templates can be uploaded into CareRight for overriding the inbuilt default XSL-FO  templates. 

Note: Customisation of XSL-FO printing Templates (Letter, Theatre Lists, Operation Report, Pathology/Radiology Results) requires at least proficient level knowledge in the XSL-FO programming.
  1. Click Administration.
  2. Select Correspondence from the menu.
  3. Select Printing Templates.
  4. Select XSL-FO.
  5. From the Default templates, Download the template that you wish to customize (by clicking Download, this downloads the XSL-FO code for you to copy).
  6. Select the New button to create a custom XSL-FO template.
  7. Back in CareRight, on the XSL-FO Printing Templates screen, click the New button.
  8. Fill in the fields based on the table below.
  9. When done, select Create Custom template.

Field

Description

XSL-FO  Template

Copy the XSL-FO code from your download and paste it into this box.

Default Template

Select the relevant default template if this replaces a GLOBAL template 

Override 

Apply the overrides as required, Please refer to Printing Template Overrides

Published (check box)

TRUE (checked/ ticked) means it will be active for use  in CareRight

Published At

read-only field indicates date and time created

Created At

read-only field indicates date and time published

Notes

Any internal notes/comments


To Modify the XSL-FO code to Add Images.

  1. Go to Administration.
  2. Select Correspondence from the menu.
  3. Select Printing Templates.
  4. Select XSL-FO.
  5. Under Custom Templates section, select Show button on the relevant Default Letter Template.
    1. The Template document screen will display.
  6. Select Edit button at the top of the screen. 
    1. The XSL-FO template code will display. 
  7. Find the following Snippet of code:
<xsl:template name="layout-header">
<fo:block text-align="center" width="190mm">
<fo:external-graphic src="system_images/default"/>
</fo:block>
</xsl:template>

        8. Add/change  the code name of  the image you set when you uploaded it. i.e default, header, drsmith.

        9. Select Update Custom template button.