feat: derive event lifecycle status from dates and flags
Replace persisted event statuses with publication and cancellation flags, and compute public lifecycle labels from event timing and registration capacity. Keep filters, registration checks, and profile responses aligned with the derived status.
This commit is contained in:
@@ -243,8 +243,8 @@ def test_late_success_after_user_or_event_cancellation_is_refunded(
|
||||
registration.cancellation_reason = reason
|
||||
registration.save(update_fields=["cancellation_reason"])
|
||||
if cancel_event:
|
||||
payment.event.status = payment.event.StatusChoices.CANCELLED
|
||||
payment.event.save(update_fields=["status"])
|
||||
payment.event.is_cancelled = True
|
||||
payment.event.save(update_fields=["is_cancelled"])
|
||||
mocker.patch("apps.payments.tasks.refund_payment.apply_async")
|
||||
paid_at = (registration.checkout_expires_at - timedelta(seconds=1)).isoformat()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user