Check-in API: Improve handling of unknown ticket codes

This commit is contained in:
Raphael Michel
2021-07-23 10:49:33 +02:00
parent 78f4f35ca3
commit 4655d8237f
5 changed files with 123 additions and 7 deletions

View File

@@ -567,7 +567,7 @@ def _save_answers(op, answers, given_answers):
def perform_checkin(op: OrderPosition, clist: CheckinList, given_answers: dict, force=False,
ignore_unpaid=False, nonce=None, datetime=None, questions_supported=True,
user=None, auth=None, canceled_supported=False, type=Checkin.TYPE_ENTRY,
raw_barcode=None):
raw_barcode=None, from_revoked_secret=False):
"""
Create a checkin for this particular order position and check-in list. Fails with CheckInError if the check in is
not valid at this time.
@@ -669,7 +669,7 @@ def perform_checkin(op: OrderPosition, clist: CheckinList, given_answers: dict,
device=device,
gate=device.gate if device else None,
nonce=nonce,
forced=force and not entry_allowed,
forced=force and (not entry_allowed or from_revoked_secret),
raw_barcode=raw_barcode,
)
op.order.log_action('pretix.event.checkin', data={