Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Port pdf_watermark field on IPublication #184

Merged
merged 1 commit into from
Jul 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ Changelog
1.0.1 (unreleased)
------------------

- Nothing changed yet.
- Support changing PDF watermark image on publication.
`#2385 <https://github.com/syslabcom/scrum/issues/2385>`_
[reinhardt]


1.0.0 (2024-06-12)
Expand Down
14 changes: 14 additions & 0 deletions src/recensio/plone/content/publication.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,25 @@
from plone.dexterity.content import Container
from plone.namedfile.field import NamedBlobImage
from plone.supermodel import model
from recensio.plone import _
from zope.interface import implementer


class IPublication(model.Schema):
"""Marker interface and Dexterity Python Schema for Publication."""

pdf_watermark = NamedBlobImage(
title=_("label_publication_pdf_watermark", default="PDF watermark"),
description=_(
"description_publication_pdf_watermark",
default=(
"Upload a publication logo for the PDF coversheet. Transparent PNG "
"format images are recommended."
),
),
required=False,
)


@implementer(IPublication)
class Publication(Container):
Expand Down
Loading