forked from CGM_Public/pretix_original
* Upgrade Django to 3.0 and other dependencies to recent versions * Fix otp version contsraint * Remove six dependency * Resolve some warnings * Fix failing tests * Update django-countries * Resolve all RemovedInDjango31Warnings in test suite * Run isort * Fix import * Update PostgreSQL version on travis
33 lines
933 B
Python
33 lines
933 B
Python
from django.apps import AppConfig
|
|
from django.utils.functional import cached_property
|
|
from django.utils.translation import gettext_lazy as _
|
|
|
|
from pretix import __version__ as version
|
|
|
|
|
|
class TicketOutputPdfApp(AppConfig):
|
|
name = 'pretix.plugins.ticketoutputpdf'
|
|
verbose_name = _("PDF ticket output")
|
|
|
|
class PretixPluginMeta:
|
|
name = _("PDF ticket output")
|
|
author = _("the pretix team")
|
|
version = version
|
|
category = 'FORMAT'
|
|
description = _("This plugin allows you to print out tickets as PDF files")
|
|
|
|
def ready(self):
|
|
from . import signals # NOQA
|
|
|
|
@cached_property
|
|
def compatibility_errors(self):
|
|
errs = []
|
|
try:
|
|
import reportlab # NOQA
|
|
except ImportError:
|
|
errs.append("Python package 'reportlab' is not installed.")
|
|
return errs
|
|
|
|
|
|
default_app_config = 'pretix.plugins.ticketoutputpdf.TicketOutputPdfApp'
|