1 Server-Managed Print Templates for Angular
2 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
4 Adds support for generating print content via server-side web service.
5 Server print templates are implemented as Template Toolkit and content
6 is compiled and generated on the server, based on runtime data provided
9 Feature includes a new Angular admin interface for testing and editing
10 server-managed print templates. The UI is accessed under Admin =>
11 Server Administration => Print Templates, though the menu entry may be
12 moved to Admin => Local Administration, once Local Admin is migrated
15 Two sample templates are included to demonstrate the format and
16 functionality. The `Holds For Bib Record` template may be tested by
17 navigating to the record holds tab in the Angular staff catalog
18 (/eg2/en-US/staff/catalog/record/<record-id>/holds) and chose the
19 `Print Holds` grid action.
24 Apply Apache configuration changes to eg_vhost.conf and eg_startup.
26 * Add to eg_vhost.conf
28 ---------------------------------------------------------------------------
29 <Location /print_template>
30 SetHandler perl-script
31 PerlHandler OpenILS::WWW::PrintTemplate
36 ---------------------------------------------------------------------------
41 ---------------------------------------------------------------------------
42 # Pass second argument of '1' to enable process-level template caching.
43 use OpenILS::WWW::PrintTemplate ('/openils/conf/opensrf_core.xml', 0);
44 ---------------------------------------------------------------------------
49 A new Perl module `HTML::Defang` is required for cleansing generated HTML
50 of executable code for security purposes. The dependency is added to
51 the Makefile.install process for new builds. Existing Evergreen instances
52 will need the dependency manually installed.
54 Installing on (for example) Ubuntu:
57 ---------------------------------------------------------------------------
58 sudo apt-get install libhtml-defang-perl
59 ---------------------------------------------------------------------------