University of Colorado Colorado Springs banner
Login to LibApps.

Print Templates 101: Customization Example

Customization Example

We've put together examples of the entire customization process for both iReport (Millennium) and Jaspersoft Studio (Sierra). In these example you'll see how to...

  • Set the system to use print templates for hold pickup notice output
  • Export the default hold pickup notice template out of the system
  • Edit the template
  • Import the template into the system
  • Test template output

 
Important Things to Know About Printing Hold Pickup Notices with Print Templates

  • Notices can be sent by email, or printed
  • It may be beneficial to develop separate templates for email and print

The tools used for this example include:

  • Windows 7 Enterprise SP1 x64
  • Millennium 2011 R1.3
  • Jasper iReport 4.0.2

Remember that print templates have to be Enabled and the user has the appropriate Permissions to begin the  process of customizing a default template.

 

Exporting the Template

1) Start by logging into Millennium.  Then choose the Settings option from under the Admin menu.

 

2) Select the Print Templates tab, and select the Output Type (template type) you wish to use from the drop-down menu.

 

3) Check the box for Use Print Templates. Next, click on the default template (default templates start with the underscore), then click on Export.

 

4) A Choose a directory (folder) window will appear. Browse to find the desired directory where you want to save the default template. Then click on the Choose a directory button.

***Hint: Make a folder within the Millennium directory called "Print Templates".  Then make subdirectories that have names pertaining to the type of templates.  For example: "C:\Millennium\Print Templates\HoldPickup"***

 

Things to keep in mind...

  • Format of the files is jrxml (Jasper Report XML)
  • If you have files in the directory you are exporting to, you can't see them in the Choose a directory window
  • If you have a file with the same name as the one you are exporting, it will be overwritten without warning!
  • Do not enter a file name.  The system will automatically name these exports
  • Graphic files used in templates are stored separately, and are exported automatically

Repeat the above process if you want to export other templates, and then select OK  to close the Settings window.

 

The next step is to open the default template with iReport and begin to customize it.

Back to Top

 

Preparing to Edit

This process will help protect the integrity of the exported file as well as help you in tracking changes that are made to the document.

1) Navigate to the directory where the default template was exported during the export Print Template process and open file With Jasper iReport (.jrxml).

***NOTE:  2 files came with this export.  A graphics file that is used in the default template is automatically downloaded ***

 

Here is how the template will look when opened in iReport:

 

2) Go to File, then select Save As

 

3) Give the file a new name using a predetermined incremental naming convention you've established. For example: Here, we've used the naming convention of HPNv0x0.jrxml, which works out to... Hold Pickup Notice version 0.0.

 

***NOTE: As changes are made to the template it should be saved in incremental versions of HPNv1, HPNv2, etc. This way, if something goes wrong in one of the versions you can easily go back to a previous version that worked before the change was made.***

Back to Top

 

Customizing the Template

The changes which will be made to this template Hold Pickup Notice include:

  • Deleting fields.
  • Resizing & moving fields
  • Adding a Static Text field
  • Changing fonts, resizing text, and adding emphasis and color to the text

 

Deleting Fields

To make the notices as uncluttered as possible these unnecessary fields will be removed:

  • Image-This is a generic which serves no real purpose
  • Library Address Information-UCCS only has one library on campus, so this information is not necessary
  • Patron Address Information-As we only provide email notices (no print ones are sent), this information is unnecessary
  • Item Number and Barcode field-This information is used for identification by us, not our patrons. The item title and call number are much more relevant to the patrons information needs.
  • Pickup Location-As there is only one library on campus, this information is not needed.

 

Fields can be delete one of 3 ways...

1) Click on the field, right click the mouse, then selecting Delete.

 

2) Click on the field, then hit the Delete Key on the keyboard.

 

3) Select the item you wish to delete from the Report Inspector, clicking on the field, then right click the mouse and select Delete, or hit the Delete Key on the keyboard.

 

After deleting the fields mentioned above the template now looks like this...

 

Resizing & Moving Fields

1) To resize the grey box click on the filed, then right click on one the field Handle Bars and drag the mouse in the appropriate direction.

 

Here is how the field looks resized...

 

2) To move the Hold Pickup Notice static text field to the center of the grey box right-click on the field, then drag it to the center of the box.

***Other methods for moving fields can be found on the Resizing & Moving fields page of this LibGuide.***

 

To move the PICKUP BY box so that it is located directly under the CALL # fields...

1) Click on the PICKUP BY static text field; it becomes highlighted in yellow, and that fields properties appear in the Properties Panel. Change the number from 104 to 85, which moves the field into the desired position. Repeat these steps for the PICKUP BY text field.

 

Here is what the template looks like after all of the fields have been moved...

 

Adding a Static Text Field

To add a field letting patrons know that their library item has arrived...


1) In the Palette, left click on the Static Text button then drag the field into the desired position on the template.

 

2) Click on the new field, which opens its Properties Panel. Click on the Custom Text Editor button and enter the desired text, then click on OK.

 

3) If the field is too small for all of the text to be visible you will  need to resize the field.

 

 

 

 

Getting Fancy

To modify some of the text in order to draw the patrons eye to the most important information...

1) Click on the field you wish to modify to open its Properties Panel. Under the text properties, select the modification you wish to apply.

***Note: If the changes made enlarge the text you will need to resize your field.***

 

To modify the font type and size...

1) Click on the field you wish to modify to open its Properties Panel. Under the text properties, select the font you wish to use, and the font size.


***Note: If the changes made enlarge your text you will need to resize your field.***

 ***Tip: To make the same font style and size changes to each field you can repeat the steps above, or use the Copy Format and Paste Format method.***

 

To add color to text...
1) Click on the field you want to modify. In the Properties panel, under Text Properties, locate the Forecolor option and select the color you would like to apply to the field. When you click on a color it will be instantly applied to the template field, allow you to preview the color in the template. When you have selected the color you want to use click on OK.

 

After making all of the changes mentioned above the template now looks like this...

  Back to Top

Importing the Template

1) Start by logging into Millennium.  Once logged on, select the Settings option from the Admin menu.

 

2) Select the Print Templates tab, and select the Output Type (template type) you wish to import the template to from the drop-down menu.

 

 

3) Ensure that the box for Use Print Templates is checked, then click on Import.

 

 

4) A New Print Template Attributes window will appear. Fill in the Template family name and the Description

***TIP: it is beneficial to use an incremental naming scheme with the version of the template which you are importing (e.g. Hold_Pickup_v1).***

Once you have named the file click on Browse.

 

 

5) Navigate to directory where the modified template was saved after modifying it. Select the template (.jrxml), and then choose Open.

 

 

6) The template will be imported into the New Print Template Attributes window. Click on OK.

 

 

7) The customized template is now imported into Millennium, and should be listed within the Preferred Templates pane.  You can now highlight the new template, and choose the Preview button to see a quick representation.

 

 

 ***Hint: At this point it is a good idea to test the template. Ways to test the template may differ depending on the type of template.  Our Hold Pickup notices are emailed. For this kind of testing, we run the job for "Hold Pickup Only" notices type with the current template. Once the job is cleared, a book is placed on hold. Then we immediately run the job again. This time we will select the new template.  Hopefully, our test hold is the only one to send. This is a cumbersome method, but we haven't found a good way to test emailed templates. After the test is done and the template is confirmed to be working correctly, we continue with modifying the custom template.***

 

8) Use the arrows to move your template over to the Preferred Templates Field.

 

 

9) Click on Save Settings, then on OK.

 

Back to Top

The tools used for this example include:

  • Windows 7 Enterprise SP1 x64
  • Sierra v. 1.1.3_4
  • Jaspersoft Studio 6.0.0

Remember that print templates have to be Enabled and the user has the appropriate Permissions to begin the  process of customizing a default template.

 

Exporting the Template

The first step in creating a custom template involves exporting the default template from your system. Remember that print templates have to be enabled and the user has the appropriate permissions to begin the process of customizing a default template.

In the example found below you'll see screen shots from Millennium. The steps involved in exporting default templates in Sierra are exactly the same.

1) Start by logging into Millennium. Then choose the Settings option from under the Admin menu.

 

2) Select the Print Templates tab, and select the Output Type (template type) you wish to use from the drop-down menu.

 

3) Check the box for Use Print Templates. Next, click on the default template (default templates start with the underscore), then click on Export.

 

4) A Choose a directory (folder) window will appear. Browse to find the desired directory where you want to save the default template. Then click on the Choose a directory button.

***HINT: Make a folder within the Millennium directory called "Print Templates". Then make subdirectories that have names pertaining to the type of templates. For example: "C:\Millennium\Print Templates\HoldPickup"***

Things to keep in mind...

  • Format of the files is jrxml (Jasper Report XML)
  • If you have files in the directory you are exporting to, you can't see them in the Choose a directory window
  • If you have a file with the same name as the one you are exporting, it will be overwritten without warning!
  • Do not enter a file name.  The system will automatically name these exports
  • Graphic files used in templates are stored separately, and are exported automatically

Repeat the above process if you want to export other templates, and then select OK  to close the Settings window.

The next step is to open the default template with iReport and begin to customize it.

Back to Top

 

Preparing to Edit

This process will help protect the integrity of the exported file as well as help you in tracking changes that are made to the document.

1) Navigate to the directory where the default template was exported during the export Print Template process and open file With Jasper iReport (.jrxml).

***NOTE:  2 files came with this export.  A graphics file that is used in the default template is automatically downloaded ***

 

Here is how the template will look when opened in Jaspersoft Studio:

 

2) Go to File, then select Save As

 

3) Give the file a new name using a predetermined incremental naming convention you've established. For example: Here, we've used the naming convention of HPNv0x0.jrxml, which works out to... Hold Pickup Notice version 0.0.

 

***NOTE: As changes are made to the template it should be saved in incremental versions of HPNv1, HPNv2, etc. This way, if something goes wrong in one of the versions you can easily go back to a previous version that worked before the change was made.***

Back to Top

 

Customizing the Template

The changes which will be made to this template Hold Pickup Notice include:

  • Deleting fields.
  • Resizing & moving fields
  • Adding a Static Text field
  • Changing fonts, resizing text, and adding emphasis and color to the text

 

Deleting Fields

To make the notices as uncluttered as possible these unnecessary fields will be removed:

  • Image-This is a generic which serves no real purpose
  • Library Address Information-UCCS only has one library on campus, so this information is not necessary
  • Patron Address Information-As we only provide email notices (no print ones are sent), this information is unnecessary
  • Item Number and Barcode field-This information is used for identification by us, not our patrons. The item title and call number are much more relevant to the patrons information needs.
  • Pickup Location-As there is only one library on campus, this information is not needed.

Fields can be delete one of 3 ways..

1) Click on the field, right click the mouse, then selecting Delete.

 

2) Click on the field, then hit the Delete Key on the keyboard.

***TIP: by holding down the Shift key you can select more than one field at a time***

 

3) Select the item you wish to delete from the Report Inspector, clicking on the field, then right click the mouse and select Delete, or hit the Delete Key on the keyboard.

 

After deleting the fields mentioned above the template now looks like this...

 

Resizing & Moving Fields

1) To resize the grey box click on the filed, then right click on one the field Handle Bars and drag the mouse in the appropriate direction.

 

Here is how the field looks resized...

 

2) To move the Hold Pickup Notice static text field to the center of the grey box right-click on the field, then drag it to the center of the box.

***Other methods for moving fields can be found on the Resizing & Moving fields page of this LibGuide.***

 

To move the PICKUP BY box so that it is located directly under the CALL # fields...

1) Click on the PICKUP BY static text field and that fields properties appear in the Properties Panel. Click on the Appearance button, and under the Location menu Change the Y number from 134 to 84, which moves the field into the desired position. Repeat these steps for the PICKUP BY text field.

 

Here is what the template looks like after all of the fields have been moved...

 

Adding a Static Text Field

To add a field letting patrons know that their library item has arrived...


1) In the Palette, left click on the Static Text button then drag the field into the desired position on the template.

 

2) Click on the new field and navigate to the Properties Panel. Click on the Field button, and in the Text box enter your text.

 

Getting Fancy

To modify some of the text in order to draw the patrons eye to the most important information...

1) Click on the field you want to modify and navigate to the Properties Panel. Click on the Field button, and in the Font menu click on the emphasis type you want to add.

***Note: If the changes made enlarge the text you will need to resize your field.***

 

To modify the font type and size...

1) Click on the field you want to modify and navigate to the Properties Panel. Click on the Field button, and in the Font menu select the font type and size you wish to use.


***Note: If the changes made enlarge your text you will need to resize your field.***

 ***Tip: To make the same font style and size changes to each field you can repeat the steps above, or use the Copy Format and Paste Format method.***

***Note: If the changes made enlarge the text you will need to resize your field.***

 

To add color to text...
1) Click on the field you want to modify. In the Properties panel click on the Appearance button, and under the Color menu click on Forecolor. Select the color you would like to apply to the field. When you click on a color it will be instantly applied to the template field, allowing you to preview the color in the template. When you have selected the color you want to use click on OK.

 

After making all of the changes mentioned above the template now looks like this...

  Back to Top

Importing the Template

After you are done customizing your template you need to import it back into your system. In the example found below you'll see screen shots from Sierra. The steps involved in importing default templates in Millennium are exactly the same.

1) Start by logging into Sierra. The select Settings from the Admin menu.

 

2) Select the Print Templates tab, and select the Output Type (template type) you wish to import from the drop-down menu.

 

3) Ensure that the box for Use Print Templates is checked, then click on Import.

 

4) A New Print Template Attributes window will appear. Fill in the Template family name and the Description.

***TIP: it is beneficial to use an incremental naming scheme with the version of the template which you are importing (e.g. Hold_Pickup_v1).***

Once you have named your files click on Browse.

 

 

5) Navigate to the directory where the template was saved. Select the template (.jrxml), and then choose Open.

 

6) The template will be imported into the Templates files field of the New Print Template Attributes window. Click on OK.

 

7) The customized template is now imported into your ILS and should be listed within the Other Templates pane.  You can now highlight the new template and choose the Preview button to see a quick representation.

 

Your ILS will now open a Viewing window to preview the template.

 

 

***Hint:  At this point it is a good idea to test the template.  Ways to test the template may differ depending on the type of template. Our Hold Pickup notices are emailed. For this kind of testing, we run the job for "Hold Pickup Only" notices type with the current template. Once the job is cleared, a book is placed on hold. Then we immediately run the job again. This time we will select the new template.  Hopefully, our test hold is the only one to send. This is a cumbersome method, but we haven't found a good way to test emailed templates. After the test is done and the template is confirmed to be working correctly, we continue with modifying the custom template.***

 

8) Use the arrows to move your template over to the Preferred Templates Field.

 

 

9) Click on Save Settings, then on OK.

 

Back to Top