Ignore:
Timestamp:
15 Feb 2013, 06:54:39 (12 years ago)
Author:
Henrik Bettermann
Message:

Define another (named) PDFCreator for Okene/Ibadan? certificates and render logos on pdf slips depending on study_mode.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.fceokene/trunk/src/waeup/fceokene/browser/pdf.py

    r8639 r9950  
    2121
    2222import os
     23import grok
    2324from waeup.kofa.browser.pdf import PDFCreator
    2425
    25 class CustomPDFCreator(PDFCreator):
    26     """A utility to help with generating PDF docs.
    27     """
     26class DefaultPDFCreator(PDFCreator):
    2827
    29     #header_logo_path = os.path.join(
    30     #    os.path.dirname(__file__), 'static', 'pdf_logo.jpg')
    31     #watermark_path = os.path.join(
    32     #    os.path.dirname(__file__), 'static', 'pdf_watermark.jpg')
     28    header_logo_path = os.path.join(
     29        os.path.dirname(__file__), 'static', 'pdf_logo.jpg')
    3330
    34     #watermark_pos = [-25, 100]
    35     #logo_pos = [507, 720, 40]
     31    logo_pos = [510, 750, 60]
     32
     33class IbadanPDFCreator(PDFCreator):
     34
     35    grok.name('ibadan_pdfcreator')
     36
     37    header_logo_path = os.path.join(
     38        os.path.dirname(__file__), 'static', 'pdf_logo_2.jpg')
     39
     40    logo_pos = [480, 740, 90]
     41
Note: See TracChangeset for help on using the changeset viewer.