Print Templates
Transcript of Print Templates
Worth the aggravation?
Richard V. JacksonHuntington Library, Art Collections, and Botanical GardensSan Marino, California
Print Templates
Print Templates – SCIUG 2012 – Loyola Marymount University 2
What are print templates? Millennium feature since Release 2007 Enable much greater flexibility in
customizing printed output and notices Available for these output types (and
others):Monographic Spine LabelsBills and Fine Notices Courtesy Notices Hold NoticesHold Cancellation Notices Hold Pickup Notices Hold SlipsTransit SlipsOverdue NoticesPaging Slips and Lists
Recall Notices Statements of ChargesStatements of Checked-out ItemsDue Slips (Express Lane)Ecommerce Receipts (Express Lane)Purchase OrdersAttendance Lists (Program Registration)Serial ClaimsSerials Routing Slips
Print Templates – SCIUG 2012 – Loyola Marymount University 3
Basic Courtesy Notice Oakland Public Library 125 14th Street Oakland, CA 94612 (510) 238-3134 02-16-10
This is an automatically generated reminder. Please do not respond via email. To view your current account status go to http://catalog.oaklandlibrary.org/patroninfo
AUTHOR: Kurlansky, Mark. TITLE: A continent of islands : searching for the Caribbean destiny CALL NO: 972.9 KURLANSKY BARCODE: 32141015280120 Main Library Storage - Ask at Desk DUE: 02-19-10 DATE CHECKED OUT: 01-29-10 02:34PM
JANE SMITH 100 Main St. APT 101 EMERYVILLE, CA 94608 4:594
Print Templates – SCIUG 2012 – Loyola Marymount University 4
Example Courtesy Notice using print templates (from SFPL)
Print Templates – SCIUG 2012 – Loyola Marymount University 5
A print template is simply …
… a file — the filename has a .jrxml extension (Jasper report XML)
Can be viewed/edited in any text editor Normally use iReport — a free 3rd-party
program from Jaspersoft — to edit .jrxml files
Download the program from CSDirect– Millennium 2007-2009: iReport 1.3.3– Millennium 2011: iReport 4.0.2
Print Templates – SCIUG 2012 – Loyola Marymount University 6
Print Templates – SCIUG 2012 – Loyola Marymount University 7
Advantages of using print templates More control (page size, font, color,
layout) Incorporate images and graphical
elements Scannable barcodes Hyperlinks (in email notices) Better handling of diacritics Save output to a PDF file Multiple templates for different
formats/needs
Print Templates – SCIUG 2012 – Loyola Marymount University 8
Advantages of using print templates More fields to choose from
The standard Hold Pickup Notice uses these fields:
Date of notice Library return address Patron name and address Notice text Item info (author, title, barcode,
location) Pickup by Pickup at Notice text number
Print Templates – SCIUG 2012 – Loyola Marymount University 9
Advantages of using print templatesWith print templates, the Hold Pickup Notice data library includes 58 fields:
Library_Address_Line1_C Library_Address_Line2_C Library_Address_Line3_C Library_Address_Line4_C Message_C Print_Sequence_CText_Number_C Total_Patron_Fines_C Item_AgencyItem_AuthorItem_BarcodeItem_Bib_Record_IdItem_Call_NumberItem_Checked_Out_DateItem_Checked_Out_LocationItem_Code1 Item_Code2 Item_Due_Date Item_Edition
Item_IDItem_In_LocationItem_Last_CheckinItem_Location1Item_Material_TypeItem_Message Item_NoteItem_OPAC_MessageItem_Pickup_By_Date Item_Pickup_Location1Item_Pickup_Location_Braddr1Item_Pickup_Location_Braddr2 Item_Pickup_Location_Braddr3Item_Publish_DateItem_PublisherItem_Record_IdItem_TitleItem_Total_Checkout Item_Type
Item_VolumeMessage_Patron1Patron_Address_Line11Patron_Address_Line21Patron_Address_Line31Patron_Address_Line41Patron_Agency1Patron_Barcode1Patron_Checked_Out_Number1Patron_Code11Patron_Code21Patron_Code31Patron_Code41Patron_Home_Library1Patron_Message1Patron_Name1Patron_Phone_Number1Patron_Phone2_Number1Patron_Record_ID1Patron_Type1
Print Templates – SCIUG 2012 – Loyola Marymount University 10
Advantages of print templates Data manipulation and conditional
printingUsing Java string methods, you can:– Print “Call of the wild” as “CALL OF THE
WILD”– Print only the last 4 digits of a barcode– Use field values to determine what to
See the handout for more information.
If Location="gcrf ", print "REF"Else if Location="hmrf ", print "MSS REF"Else if Location="hcons", print "CONSERV."Else if Location="botr ", print "BOT RARE"Else if Location="href ", print "INVALID!" [etc.] This is not the actual
code!
Print Templates – SCIUG 2012 – Loyola Marymount University 11
Advantages of print templates Print templates may be adapted to suit
other purposes or fit non-standard workflowsFor example, using templates for spine labels:TR
647W395 2010c.2
TEL626558
Waterhouse
Gun running in the Red Sea
3 0006 3004 0214 7
Print Templates – SCIUG 2012 – Loyola Marymount University 12
Disadvantages
Steep learning curve Can be difficult to
learn iReport So many ways things
can go wrong – can be difficult to troubleshootproblems
Many places to seek help
Print Templates – SCIUG 2012 – Loyola Marymount University 13
My own adventures with spine labels We needed to replace our aging printers
Print Templates – SCIUG 2012 – Loyola Marymount University 14
Adventures with spine labels
Print Templates – SCIUG 2012 – Loyola Marymount University 15
Adventures with spine labels
Print Templates – SCIUG 2012 – Loyola Marymount University 16
Adventures with spine labels We needed more
readable labels … … and a better
process for maintaining them
Print Templates – SCIUG 2012 – Loyola Marymount University 17
Adventures with spine labels Liked the Zebra printer
– Small– Relative inexpensive
Print Templates – SCIUG 2012 – Loyola Marymount University 18
Adventures with spine labels
First template, based on Kathy Setter’s IUG presentation and samples from the CSDirect wiki, resulted in:
Print Templates – SCIUG 2012 – Loyola Marymount University 19
Adventures with spine labels
Finally, something printed:
Print Templates – SCIUG 2012 – Loyola Marymount University 20
Did you find it an incredibly finicky, difficult process? Is my experience the norm? In trying to make what seem to be small adjustments in the labels, it will often cease to print at all ...
Cindy Harper“Print templates - specifically with Zebra printer”(IUG List posting, 9/1/10)
Print Templates – SCIUG 2012 – Loyola Marymount University 21
It took three of us in tech services going over the documentation, taking the class (spine labels) and a lot of practice AFTER the class to get labels to print (and ones we could live with).
Alison Pruntel“Re: Print templates - specifically with Zebra printer” (IUG List posting, 9/2/10)
I've been browsing the list archives, but I'm seeing more problems than solutions.
Tyra Ealy“Spine Label Printing”(IUG List posting, 12/23/10)
Print Templates – SCIUG 2012 – Loyola Marymount University 22
Spine labels: Portrait vs. Landscape
Print Templates – SCIUG 2012 – Loyola Marymount University 23
Spine labels: Portrait vs. Landscape Initial solution: Define the page size as
square (1.5 x 1.5 ") in the print template, setting the correct size in the printer settings
Contrary to what I read, but it worked! …
until …
Page size in printer settings
Page size in print template
Print Templates – SCIUG 2012 – Loyola Marymount University 24
Spine labels: “Skinny label” problem
Narrow call numbers doubled up on the label
An appeal to the IUG List brought a solution from Bob Thomas (posting on 8/4/2010)
Print Templates – SCIUG 2012 – Loyola Marymount University 25
iReport (version 1.3.3) changed the orientation to “Landscape” when page size width > height
Needed to edit the .jrxml file directly (using Notepad), changing the orientation to “Portrait”
Spine labels: “Skinny label” problem
Orientation="Portrait"
Print Templates – SCIUG 2012 – Loyola Marymount University 26
Spine labels: “Skinny label” problem This enabled me to match the page size
in the print template to the printer settings
Page size in printer settings
Page size in print template
Print Templates – SCIUG 2012 – Loyola Marymount University 27
Finally — the result:
Print Templates – SCIUG 2012 – Loyola Marymount University 28
Refinement #1: Automating pre-stamps
Certain special locations require a location “stamp” above the call number
These had been generated using a locally-defined “LABEL LOC” field in the Item record
Problem: The location code and LABEL LOC are logically dependent but functionally independent — errors and inconsistencies can easily occur
MSS REFCD1879.5C64 G37
folioTR647W395 2010c.2
Print Templates – SCIUG 2012 – Loyola Marymount University 29
Refinement #1: Automating pre-stamps
Print Templates – SCIUG 2012 – Loyola Marymount University 30
Refinement #1: Automating pre-stamps With conditional printing in the print
template, I could print pre-stamps from the location code
$F{itemFix79}.equals("hmrf ") ? "MSS REF" + "\n"
Print Templates – SCIUG 2012 – Loyola Marymount University 31
Refinement #2: Varying the font size A couple longer pre-stamps didn’t fit
Again, the IUG List came through (posting from Gerri Moeller, 9/22/2010)
Print Templates – SCIUG 2012 – Loyola Marymount University 32
Refinement #2: Varying the font size
"<style fontName='Arial Narrow' size='10'>" + "AHMANSON" + "\n" + "Reading Rm." + "</style>" + "\n"
Print Templates – SCIUG 2012 – Loyola Marymount University 33
Volume: ser.3 v.29-30
Volume: n.s. v.11-12
Refinement #3: Volume field line breaks Problem: The print template wraps a
long field as far to the right as possible Goal: Make it possible to manually set
line breaks in a long Volume field
VM1S32 n.s. v.11-12
VM1S32 ser.3 v.29-30
Print Templates – SCIUG 2012 – Loyola Marymount University 34
Refinement #3: Volume field line breaks Solution: Add a string method that
convert 2 spaces in a Volume field to a carriage return
Volume: n.s.^^v.11-12
VM1S32 n.s. v.11-12
Volume: ser.3^^v.29-30
VM1S32 ser.3 v.29-30
$F{itemv}.replaceAll(" ","\n")
Print Templates – SCIUG 2012 – Loyola Marymount University 35
Spine labels: What was gained Sharper, more readable spine labels
Print Templates – SCIUG 2012 – Loyola Marymount University 36
Spine labels: What was gained Sharper, more readable spine labels Greater convenience in printing labels Elimination of pre-stamp errors Easier label printing so Reader Services
staff can print replacement labels Possibility of multiple templates for
different formats/different needs
Print Templates – SCIUG 2012 – Loyola Marymount University 37
Spine labels: What was lost Ability to preview (and edit) spine labels
(not as much of a problem as you might think)
Ability to use the old label queue or print labels directly from an Item review file– The label queues used with print
templates are specific to one login/one session
– Useful chiefly for printing sheets of labels, or printing multiple formats with separate queues
Print Templates – SCIUG 2012 – Loyola Marymount University 38
Getting started
1. Enable print templates in the character-based systemA > ADDITIONAL system functions A > ALTER system parameters S > SYSTEM codes O > Set system OPTIONS D > Database maintenance
41 > Enable Print Templates........YES
Print Templates – SCIUG 2012 – Loyola Marymount University 39
Getting started
2. Check authorizations
The Print Templates manager should have all 4 authorizationsPrint Template users need no special authori-zations, but may benefit from 282 & 283
282 Preview Print Templates283 Update Print Templates Tab284 Import/Export Print Templates285 Delete Print Templates
Print Templates – SCIUG 2012 – Loyola Marymount University 40
Getting started3. Download and install iReport from
CSDirect
Print Templates – SCIUG 2012 – Loyola Marymount University 41
Getting started4. In Millennium, go to Admin > Settings
> Print Templates tab– Must be enabled per login, per output
type
Print Templates – SCIUG 2012 – Loyola Marymount University 42
Getting started
5. Edit the template– Export one of the default templates– Open and edit in iReport– “Save as” with a new name
(that doesn’t start with “_”)– Import back in Millennium
Print Templates – SCIUG 2012 – Loyola Marymount University 43
Getting started6. To use (and test) the new template,
move it left to the Preferred Templates column
Print Templates – SCIUG 2012 – Loyola Marymount University 44
Getting started
7. Select the Print Templates printer
Print Templates – SCIUG 2012 – Loyola Marymount University 45
Circulation notices Print templates for circ notices are
stored in print template families. Each family can hold:– Separate templates for print and email– Separate templates for different
languages
46
Courtesy notice
Hyperlinks
Dynamic data
“Regis.#” (Unique ID) field not available in print template. This is extracted from the barcode: 20006009999998 using the .substring method.
Print Templates – SCIUG 2012 – Loyola Marymount University 47
Holdslip
If we wanted to print “Jac/R” instead of “Jackson, Richard V.,” we can use Java string methodsA string method has this structure:
[field name].[method name]([parameters])
Print Templates – SCIUG 2012 – Loyola Marymount University 48
String methods: an example
To change “Jackson, Richard V.” to “Jac/R”:
$F{v_p_name}.substring( 0 , 3 )
+ "/"
+ $F{v_p_name}.substring($F{v_p_name}.indexOf(",") + 2,
$F{v_p_name}.indexOf(",") + 3 )
The .substring method extracts first 3 characters of Name
Concatenate the literal string “/”
Use the .indexOf string method to find the start and end points of the first letter of the first name
Print Templates – SCIUG 2012 – Loyola Marymount University 49
Using iReport
Version 1.3.3
Print Templates – SCIUG 2012 – Loyola Marymount University 50
Using iReport
Version 4.0.2
Print Templates – SCIUG 2012 – Loyola Marymount University 51
Editing the Text Field Expression
Expression editor window
Available fields String methods
Print Templates – SCIUG 2012 – Loyola Marymount University 52
Measurements in iReport Measurements are in PostScript points
— which iReport calls “pixels” (px) For printed output: 72 px = 1 inch
– 8.5 x 11 inch sheet = 612 x 792 px– 1 x 1.5 inch label = 72 x 108 px– Font sizes: 12 = 12 pt (approx. 5
lines/inch)10 = 10 pt (approx. 6
lines/inch) For email output: px matches screen
pixels– What looks good in print may look small
in email– Increase font sizes 30-40% for email
templates (14-16 px instead of 10-12 px)
Print Templates – SCIUG 2012 – Loyola Marymount University 53
Finding Help Print templates main page on CSDirect
(http://csdirect.iii.com/documentation/print_templates.php)
Print Templates – SCIUG 2012 – Loyola Marymount University 54
Finding Help PrintTemplates Web – a wiki on CSDirect
(http://csdirect.iii.com/lswiki/PrintTemplates/WebHome)
Print Templates – SCIUG 2012 – Loyola Marymount University 55
Finding help
Innovative Guide and Reference
#107521 — Printing with Print Templates
#107687 — Creating Customized Print Templates
#107515 — Print Template Data Libraries
Print Templates – SCIUG 2012 – Loyola Marymount University 56
Finding help InnoU online courses
(http://csdirect.iii.com/innou/catalog.php)
Print Templates – SCIUG 2012 – Loyola Marymount University 57
Finding help
IUG Conference presentations(http://www.innovativeusers.org/iug-past-
conferences)
IUG List– Search previous postings– Can be difficult to answer questions on
the list– Unfortunately, you can’t attach a print
template– Provide as much description as you can
Print Templates – SCIUG 2012 – Loyola Marymount University 58
Finding help Reference page on Java string methods
(http://docs.oracle.com/javase/6/docs/api/java/lang/String.html)
Print Templates – SCIUG 2012 – Loyola Marymount University 59
Finding help
Access the iReport Designer page (http://community.jaspersoft.com/project/ireport-designer)
– From iReport: Help > iReport– Start Menu > Jaspersoft > iReport-4.0.2 >
iReport site
Print Templates – SCIUG 2012 – Loyola Marymount University 60
Conclusion Print templates can be difficult and
time-consuming to learn Once mastered, there can be many
benefits If status quo still meets your needs, stay
with it Print Wizard is still an option (not with
print templates) Over the long term, maintaining print
templates – and the expertise they require – could be challenging
61
Thank you!
Richard V. JacksonHead of Copy Cataloging / Database Manager
Huntington Library, Art Collections, and Botanical Gardens
San Marino, [email protected]
http://www.huntington.org/
Print Templates – SCIUG 2012 – Loyola Marymount University