[Archivesspace_Users_Group] customizing PDF output for PUI

Majewski, Steven Dennis (sdm7g) sdm7g at virginia.edu
Fri Mar 16 10:58:26 EDT 2018


You are correct: The PDF generation from the staff and the public interfaces are different and use two completely different toolchains. 

Staff:
Resource -> EAD -> xsl -> fop -> PDF

Public:
Resource -> HTML + CSS -> iText -> PDF 


For public code look at:

https://github.com/archivesspace/archivesspace/blob/master/public/app/controllers/pdf_controller.rb <https://github.com/archivesspace/archivesspace/blob/master/public/app/controllers/pdf_controller.rb>

https://github.com/archivesspace/archivesspace/blob/master/public/app/models/finding_aid_pdf.rb <https://github.com/archivesspace/archivesspace/blob/master/public/app/models/finding_aid_pdf.rb>

It is using the rails view templates, but calling the partials manually to leave out the usual HTML headers, footers, menus and page decoration that is not wanted in the print version and to explicitly include the child content inline rather than as links. 

The iText renderer which generates the PDF from HTML+CSS is a Java library in common/lib/itext-2.1.7.js2.jar . 
You can google for API details, but you probably don’t need to get that deep in the weeds. 

If you are successful in customizing output, please report back, as we don’t yet have any documentation on customization process for PDF output from the public size. 


— Steve.



> On Mar 16, 2018, at 9:52 AM, Benn Joseph <benn.joseph at northwestern.edu> wrote:
> 
> Hi all,
> We’re on v2.3.0 and are interested in doing some customizations (adding branding, changing font sizes, reordering content) on the PDF output in our ArchivesSpace public interface. However, we can’t seem to find where to make those changes. Can anyone point me to a directory or config file or something along those lines where we can get started? I remember also hearing at one point about there being a plugin that adds the Biographical Note from an Agent record to the PDF output. We’re very interested in this plugin, but I also wonder if we need to be thinking about this too while we consider these customizations.
>  
> We did discover how to make edits to the PDF output in the staff interface, but these seem to be two separate processes. Or maybe they’re not and I’m missing something obvious!
>  
> Thanks,
> --Benn
>  
> Benn Joseph
> Head of Archival Processing
> Northwestern University Libraries
> Northwestern University
> www.library.northwestern.edu <x-msg://3/www.library.northwestern.edu>
> benn.joseph at northwestern.edu <mailto:benn.joseph at northwestern.edu%0d>
> 847.467.6581
>  
> _______________________________________________
> Archivesspace_Users_Group mailing list
> Archivesspace_Users_Group at lyralists.lyrasis.org <mailto:Archivesspace_Users_Group at lyralists.lyrasis.org>
> http://lyralists.lyrasis.org/mailman/listinfo/archivesspace_users_group <http://lyralists.lyrasis.org/mailman/listinfo/archivesspace_users_group>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lyralists.lyrasis.org/pipermail/archivesspace_users_group/attachments/20180316/5d0ba471/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 6091 bytes
Desc: not available
URL: <http://lyralists.lyrasis.org/pipermail/archivesspace_users_group/attachments/20180316/5d0ba471/attachment.bin>


More information about the Archivesspace_Users_Group mailing list