from django.db import models

REPLAY_EXECUTION_SCHEMA_VERSION = 1


class ReplayExecutionStatus(models.TextChoices):
    CREATED = "CREATED", "Created"
    CALENDAR_PENDING = "CALENDAR_PENDING", "Calendar pending"
    READY = "READY", "Ready"
    IN_PROGRESS = "IN_PROGRESS", "In progress"
    AWAITING_RESULT = "AWAITING_RESULT", "Awaiting certified result"
    CONSOLIDATED = "CONSOLIDATED", "Consolidated"
    SUPERSEDED = "SUPERSEDED", "Superseded"
    CANCELLED = "CANCELLED", "Cancelled"


class ReplayConsolidationOutcome(models.TextChoices):
    CONFIRMED = "CONFIRMED", "Confirmed"
    AWARDED_HOME = "AWARDED_HOME", "Awarded home"
    AWARDED_AWAY = "AWARDED_AWAY", "Awarded away"
    VOID = "VOID", "Void"


class ReplayEventType(models.TextChoices):
    EXECUTION_CREATED = "EXECUTION_CREATED", "Execution created"
    CALENDAR_DRAFTED = "CALENDAR_DRAFTED", "Calendar drafted"
    ORDER_FULFILLED = "ORDER_FULFILLED", "Replay order fulfilled"
    RESULT_FINAL = "RESULT_FINAL", "Replay result final"
    CONSOLIDATED = "CONSOLIDATED", "Replay result consolidated"
    ANCESTOR_CONSOLIDATED = "ANCESTOR_CONSOLIDATED", "Ancestor replay consolidated"
